LLVM API Documentation

ForceLinkageMacros.h

Go to the documentation of this file.
00001 //===--- ForceLinkageMacros.h - The LLVM Compiler Driver --------*- C++ -*-===//
00002 //
00003 //                     The LLVM Compiler Infrastructure
00004 //
00005 // This file is distributed under the University of Illinois Open
00006 // Source License. See LICENSE.TXT for details.
00007 //
00008 //===----------------------------------------------------------------------===//
00009 //
00010 //  Preprocessor magic that forces references to static libraries - common
00011 //  macros used by both driver and plugins.
00012 //
00013 //===----------------------------------------------------------------------===//
00014 
00015 #ifndef LLVM_INCLUDE_COMPILER_DRIVER_FORCE_LINKAGE_MACROS_H
00016 #define LLVM_INCLUDE_COMPILER_DRIVER_FORCE_LINKAGE_MACROS_H
00017 
00018 #define LLVMC_FORCE_LINKAGE_PREFIX(PluginName) ForceLinkage ## PluginName
00019 
00020 #define LLVMC_FORCE_LINKAGE_FUN(PluginName) \
00021   LLVMC_FORCE_LINKAGE_PREFIX(PluginName)
00022 
00023 #define LLVMC_FORCE_LINKAGE_DECL(PluginName) \
00024   void LLVMC_FORCE_LINKAGE_FUN(PluginName) ()
00025 
00026 #define LLVMC_FORCE_LINKAGE_CALL(PluginName) \
00027   LLVMC_FORCE_LINKAGE_FUN(PluginName) ()
00028 
00029 #endif // LLVM_INCLUDE_COMPILER_DRIVER_FORCE_LINKAGE_MACROS_H