Add link time optimization of available
[oonf.git] / src / CMake.link
1 # the order of static libraries is important
2 # earlier libraries can use the functions of later, not the
3 # other way around
4
5 # link plugin loader
6 TARGET_LINK_LIBRARIES(${OONF_EXE} static_pluginloader)
7
8 # link static plugins
9 FOREACH(plugin ${OONF_STATIC_PLUGINS})
10     TARGET_LINK_LIBRARIES(${OONF_EXE} static_${plugin})
11 ENDFOREACH(plugin)
12
13 TARGET_LINK_LIBRARIES(${OONF_EXE} static_config)
14 TARGET_LINK_LIBRARIES(${OONF_EXE} static_common)
15
16 # link builddata
17 TARGET_LINK_LIBRARIES(${OONF_EXE} static_builddata)
18
19 # link dlopen() library
20 TARGET_LINK_LIBRARIES(${OONF_EXE} ${CMAKE_DL_LIBS})
21
22 # link extra win32 libs
23 IF(WIN32)
24     SET_TARGET_PROPERTIES(${OONF_EXE} PROPERTIES ENABLE_EXPORTS true)
25     TARGET_LINK_LIBRARIES(${OONF_EXE} ws2_32 iphlpapi)
26 ENDIF(WIN32)