Skip to content
white238 edited this page Jul 26, 2012 · 1 revision

Smart defines are reserved defines that behave differently depending on the build system you are using in a given target. This allows MixDown to have built-in support for utilizing CMake's and Autotool's command line options. By using the smart defines in your Override Groups, MixDown will automatically use the correct command line option as long as you have the corresponding define in your build command.

For example, the define that holds all of Autotool's ability to set compilers is _AutoToolsCompilers. If you imported your project with --import, the smart define will automatically be there in your command. Also if you do not use override groups, the _AutoToolsCompilers define will simply disappear when the command is expanded.

List of all the Smart Defines MixDown supports and what they expand to in Autotools and CMake.

C

MixDown Autotools CMake
ccompiler CC CMAKE_C_COMPILER
cflags CFLAGS CMAKE_C_FLAGS
cdefines DEFS

C Preprocessor

MixDown Autotools CMake
cpreprocessor CPP
cppflags CPPFLAGS

C++

MixDown Autotools CMake
cxxcompiler CXX CMAKE_CXX_COMPILER
cxxflags CXXFLAGS CMAKE_CXX_FLAGS

Fortran

MixDown Autotools CMake
fcompiler FC CMAKE_Fortran_COMPILER
fflags FCFLAGS CMAKE_Fortran_FLAGS
flibs FCLIBS

Fortran 77

MixDown Autotools CMake
f77compiler F77 CMAKE_Fortran_COMPILER
f77flags FFLAGS CMAKE_Fortran_FLAGS
f77libs FLIBS

Objective-C

MixDown Autotools CMake
objccompiler OBJC CMAKE_CXX_COMPILER
objcflags OBJCFLAGS CMAKE_OBJC_FLAGS

Objective-C Preprocessor

MixDown Autotools CMake
objcpreprocessor OBJCPP

Objective-C++

MixDown Autotools CMake
objcxxcompiler OBJCXX
objcxxflags OBJCXXFLAGS

Objective-C++ Preprocessor

MixDown Autotools CMake
OBJCXXPreProcessor OBJCXXCPP

Linker

Due to CMake having three different linker flags to Autotools one, if you do not specify any of CMake's three linker flags but do specify the combined linker flags, MixDown will set all three to the combined flag.

MixDown Autotools CMake
linkerflags LDFLAGS
linkerflagsexe CMAKE_EXE_LINKER_FLAGS
linkerflagsshared CMAKE_MODULE_LINKER_FLAGS
linkerflagsmodule CMAKE_SHARED_LINKER_FLAGS