blob: fd22455ae7c080279cee3a3b6deb206537fdf487 [file] [log] [blame]
Pierre Ossmana7769f22011-03-03 09:44:49 +00001if(USE_INCLUDED_ZLIB)
2 add_subdirectory(zlib)
3
4 set(ZLIB_INCLUDE_DIRS ${CMAKE_SOURCE_DIR}/common/zlib)
5 set(ZLIB_LIBRARIES zlib)
6endif()
7
DRC2ff39b82011-07-28 08:38:59 +00008if(USE_INCLUDED_FLTK)
9 add_subdirectory(fltk)
10endif()
11
DRC180c0162010-10-27 07:20:27 +000012add_subdirectory(os)
DRC180c0162010-10-27 07:20:27 +000013add_subdirectory(rdr)
14add_subdirectory(network)
15add_subdirectory(Xregion)
16add_subdirectory(rfb)
DRCce82f4b2011-08-23 20:35:06 +000017
18# For any convenience libraries that are linked into libvnc.so, we need to
19# explicitly build their corresponding sources using PIC. WIN32 is excluded
20# because PIC code does not exist on that platform and MinGW complains if -fPIC
21# is passed (additionally, libvnc is not used on Windows.)
22
23if(CMAKE_COMPILER_IS_GNUCXX AND (CMAKE_SIZEOF_VOID_P MATCHES 8) AND NOT WIN32)
24 set_target_properties(os rdr network Xregion rfb
25 PROPERTIES COMPILE_FLAGS -fPIC)
26 if(USE_INCLUDED_ZLIB)
27 set_target_properties(zlib PROPERTIES COMPILE_FLAGS -fPIC)
28 endif()
29endif()