Xe-Release/XeRelease_Gtkmm3/CMakeLists.txt

34 lines
1015 B
CMake
Raw Normal View History

2021-06-21 16:16:27 +08:00
set(CMAKE_CXX_STANDARD 17)
cmake_minimum_required(VERSION 3.0.0)
2021-06-21 16:18:17 +08:00
project(XeRelease VERSION 12.0.0)
2021-06-21 16:16:27 +08:00
include(CTest)
enable_testing()
set(CPACK_PROJECT_NAME ${PROJECT_NAME})
set(CPACK_PROJECT_VERSION ${PROJECT_VERSION})
include(CPack)
include_directories(..)
find_package (PkgConfig REQUIRED)
pkg_check_modules (GTKMM3 REQUIRED gtkmm-3.0)
include_directories (${GTKMM3_INCLUDE_DIRS})
link_directories (${GTKMM3_LIBRARY_DIRS})
2021-06-29 21:37:01 +08:00
if(WIN32)
SET(CMAKE_RC_COMPILER x86_64-w64-mingw32-windres)
set(app_WINRC icon.rc)
set_property(SOURCE icon.rc APPEND PROPERTY
OBJECT_DEPENDS ${PROJECT_SOURCE_DIR}/icon.ico
)
add_executable(XeRelease ${app_WINRC} src/main.cc src/MyWin.cc src/MyDialog.cc
src/xerelease.cc src/xeapi.cc src/resources.cpp)
else()
add_executable(XeRelease src/main.cc src/MyWin.cc src/MyDialog.cc
src/xerelease.cc src/xeapi.cc src/resources.cpp)
endif(WIN32)
2021-06-21 16:16:27 +08:00
2021-06-29 21:37:01 +08:00
SET (CMAKE_EXTRA_CXX_FLAGS ${GTKMM3_CFLAGS_OTHER})
2021-06-21 16:16:27 +08:00
target_link_libraries (${PROJECT_NAME} ${GTKMM3_LIBRARIES})