2010-01-21 15:12:50 +00:00
|
|
|
# bin2cpp tool
|
|
|
|
|
|
|
|
# executable name
|
|
|
|
set(bin2cppName bin2cpp)
|
|
|
|
|
|
|
|
# Debug - Build
|
|
|
|
if(CMAKE_BUILD_TYPE STREQUAL Debug)
|
|
|
|
# add defines
|
2010-01-22 04:36:49 +00:00
|
|
|
add_definitions(-O2 -s -Wall -fexceptions)
|
2010-01-21 15:12:50 +00:00
|
|
|
endif(CMAKE_BUILD_TYPE STREQUAL Debug)
|
|
|
|
|
|
|
|
# Devel - Build
|
|
|
|
if(CMAKE_BUILD_TYPE STREQUAL Devel)
|
|
|
|
# add defines
|
2010-01-22 04:36:49 +00:00
|
|
|
add_definitions(-O2 -s -Wall -fexceptions)
|
2010-01-21 15:12:50 +00:00
|
|
|
endif(CMAKE_BUILD_TYPE STREQUAL Devel)
|
|
|
|
|
|
|
|
# Release - Build
|
|
|
|
if(CMAKE_BUILD_TYPE STREQUAL Release)
|
|
|
|
# add defines
|
2010-01-22 04:36:49 +00:00
|
|
|
add_definitions(-O2 -s -Wall -fexceptions)
|
2010-01-21 15:12:50 +00:00
|
|
|
endif(CMAKE_BUILD_TYPE STREQUAL Release)
|
|
|
|
|
2010-01-22 04:36:49 +00:00
|
|
|
# variable with all sources of this executable
|
|
|
|
set(bin2cppSources
|
|
|
|
bin2cpp.cpp)
|
|
|
|
|
|
|
|
set(bin2cppHeaders
|
|
|
|
)
|
|
|
|
|
|
|
|
# add executable
|
|
|
|
add_executable(${bin2cppName} ${bin2cppSources} ${bin2cppHeaders})
|
|
|
|
|
2010-01-21 15:12:50 +00:00
|
|
|
# set output directory
|
2011-07-14 09:02:37 +00:00
|
|
|
# set_target_properties(${bin2cppName} PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${PROJECT_SOURCE_DIR}/tools/bin)
|
2010-01-21 15:12:50 +00:00
|
|
|
|