From c3a8517879106e88236786da76e2f1e292a7d0e1 Mon Sep 17 00:00:00 2001 From: DRC Date: Tue, 5 Jul 2011 18:55:55 +0000 Subject: [PATCH] The previous fix for eliminating the console window in vncviewer.exe was not portable (it only worked in MinGW, which isn't what most people use.) Use the CMake "WIN32" target property instead. git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@4576 3789f03b-4d11-0410-bbf8-ca57d06f2519 --- CMakeLists.txt | 3 --- vncviewer/CMakeLists.txt | 6 +++++- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index cda85ca1..159de720 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -309,9 +309,6 @@ add_subdirectory(common) if(WIN32) add_subdirectory(win) - if(CMAKE_C_COMPILER_ID STREQUAL GNU) - set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,-subsystem,windows") - endif(CMAKE_C_COMPILER_ID STREQUAL GNU) else() # No interest in building x related parts on Apple if(NOT APPLE) diff --git a/vncviewer/CMakeLists.txt b/vncviewer/CMakeLists.txt index ec899633..8be757ee 100644 --- a/vncviewer/CMakeLists.txt +++ b/vncviewer/CMakeLists.txt @@ -29,7 +29,11 @@ else() set(VNCVIEWER_SOURCES ${VNCVIEWER_SOURCES} X11PixelBuffer.cxx) endif() -add_executable(vncviewer ${VNCVIEWER_SOURCES}) +if(WIN32) + add_executable(vncviewer WIN32 ${VNCVIEWER_SOURCES}) +else() + add_executable(vncviewer ${VNCVIEWER_SOURCES}) +endif() target_link_libraries(vncviewer rfb network rdr os Xregion ${FLTK_LIBRARIES} ${GETTEXT_LIBRARIES}) -- 2.39.5