Changeset View
Changeset View
Standalone View
Standalone View
source/blender/datatoc/CMakeLists.txt
| Show All 31 Lines | |||||
| # ----------------------------------------------------------------------------- | # ----------------------------------------------------------------------------- | ||||
| # Build datatoc_icon executable | # Build datatoc_icon executable | ||||
| if(NOT WITH_HEADLESS) | if(NOT WITH_HEADLESS) | ||||
| set(SRC | set(SRC | ||||
| datatoc_icon.c | datatoc_icon.c | ||||
| ) | ) | ||||
| setup_platform_linker_flags() | |||||
| if(WIN32) | if(WIN32) | ||||
| include_directories( | include_directories( | ||||
| ../blenlib | ../blenlib | ||||
| ../../../intern/utfconv | ../../../intern/utfconv | ||||
| ) | ) | ||||
| # for winstuff_dir.c | # for winstuff_dir.c | ||||
| add_definitions(-DUSE_STANDALONE) | add_definitions(-DUSE_STANDALONE) | ||||
| list(APPEND SRC | list(APPEND SRC | ||||
| ../blenlib/intern/winstuff_dir.c | ../blenlib/intern/winstuff_dir.c | ||||
| ../../../intern/utfconv/utfconv.c | ../../../intern/utfconv/utfconv.c | ||||
| ) | ) | ||||
| set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${PLATFORM_LINKFLAGS}") | |||||
| set(CMAKE_EXE_LINKER_FLAGS_DEBUG "${CMAKE_EXE_LINKER_FLAGS_DEBUG} ${PLATFORM_LINKFLAGS_DEBUG}") | |||||
| endif() | endif() | ||||
| include_directories(${PNG_INCLUDE_DIRS}) | include_directories(${PNG_INCLUDE_DIRS}) | ||||
| link_directories(${PNG_LIBPATH} ${ZLIB_LIBPATH}) | link_directories(${PNG_LIBPATH} ${ZLIB_LIBPATH}) | ||||
| add_executable(datatoc_icon ${SRC}) | add_executable(datatoc_icon ${SRC}) | ||||
| target_link_libraries(datatoc_icon ${PNG_LIBRARIES} ${ZLIB_LIBRARIES}) | target_link_libraries(datatoc_icon ${PNG_LIBRARIES} ${ZLIB_LIBRARIES}) | ||||
| # PNG library uses pow() and floow(), so seems -lm is required for proper | # PNG library uses pow() and floow(), so seems -lm is required for proper | ||||
| # workign binary. | # workign binary. | ||||
| if(UNIX AND NOT APPLE) | if(UNIX AND NOT APPLE) | ||||
| target_link_libraries(datatoc_icon m) | target_link_libraries(datatoc_icon m) | ||||
| endif() | endif() | ||||
| endif() | endif() | ||||