diff --git a/CMakeLists.txt b/CMakeLists.txt index 482fcce4f6ca2b6369eb58a50e75c9afa48814bd..37247e29e26082dc59fe7a0baa4ee9f3658cc1af 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -7,6 +7,10 @@ CMAKE_MINIMUM_REQUIRED(VERSION 2.6) PROJECT(xtpcpp CXX) +set(CMAKE_COLOR_MAKEFILE ON) +set(CMAKE_VERBOSE_MAKEFILE ON) + + if (MXE) #x86_64-w64-mingw32.shared-cmake -DCMAKE_BUILD_TYPE=Release -DMXE=1 .. MESSAGE("MXE (M cross environment) https://mxe.cc/") diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 7c93adfb9916f3d677d668c76fc02f2152bb7e6a..4046ffc230972330baa6b57435547a6d65a40f02 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -285,7 +285,13 @@ target_compile_definitions(xtpcpp PUBLIC ${QT_DEFINITIONS}) #INCLUDE_DIRECTORIES "${QT_INCLUDE_DIR} ${QT_QTCORE_INCLUDE_DIR}" ) if (MINGW) - TARGET_LINK_LIBRARIES(xtpcpp + target_compile_options( + xtpcpp PRIVATE -mwindows + ) + set_target_properties(xtpcpp PROPERTIES LINK_FLAGS "-Wl,--subsystem,windows ${CMAKE_EXE_LINKER_FLAGS}") + + + target_link_libraries(xtpcpp OdsStream::Core Pappso::Core Pappso::Widget @@ -307,7 +313,7 @@ if (MINGW) Qt5::Sql ) else (MINGW) - TARGET_LINK_LIBRARIES(xtpcpp + target_link_libraries(xtpcpp OdsStream::Core Pappso::Core Pappso::Widget @@ -323,7 +329,10 @@ else (MINGW) ) endif (MINGW) -INSTALL(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/xtpcpp DESTINATION bin) + + + +install(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/xtpcpp DESTINATION bin) #configure_file (${CMAKE_SOURCE_DIR}/templates/share/applications/pt-peptideviewer.desktop.cmake ${CMAKE_BINARY_DIR}/templates/share/applications/pt-peptideviewer.desktop)