mirror of
https://github.com/zint/zint
synced 2024-11-16 20:57:25 +13:00
cfd43478eb
The dependency is implied by the target_link_library line. Manual dependencies are a workaround to force re-execution of external tools with intransparent side effects
26 lines
641 B
CMake
26 lines
641 B
CMake
# (c) 2008 by BogDan Vatra < bogdan@licentia.eu >
|
|
|
|
project(zint_frontend)
|
|
|
|
include(CheckFunctionExists)
|
|
|
|
check_function_exists(getopt HAVE_GETOPT)
|
|
|
|
set(zint_frontend_SRCS main.c)
|
|
|
|
if(NOT HAVE_GETOPT)
|
|
set(zint_frontend_SRCS ${zint_frontend_SRCS} getopt.c getopt1.c)
|
|
endif(NOT HAVE_GETOPT)
|
|
|
|
include_directories(BEFORE "${CMAKE_SOURCE_DIR}/backend")
|
|
|
|
add_executable(zint_frontend ${zint_frontend_SRCS})
|
|
|
|
set_target_properties(zint_frontend PROPERTIES OUTPUT_NAME "zint")
|
|
|
|
link_directories( "${CMAKE_BINARY_DIR}/backend" )
|
|
|
|
target_link_libraries(zint_frontend zint)
|
|
|
|
install(TARGETS zint_frontend DESTINATION "${BIN_INSTALL_DIR}" RUNTIME)
|