summaryrefslogtreecommitdiff
path: root/ldmicro/CMakeLists.txt
diff options
context:
space:
mode:
authorNatsuDrag92018-05-30 11:11:41 +0530
committerNatsuDrag92018-05-30 11:11:41 +0530
commitfdc0cc1d6db8a4297610071ab8d124b5586792c9 (patch)
treecbf5dac50252afae81a2bf36e9dcf843cfcbb693 /ldmicro/CMakeLists.txt
parent3065f70943cb927bfe0a81c94c5d8acc151cb6be (diff)
parent05a927c0c42a1d2a24f344023aeaadf3a9a3f29b (diff)
downloadLDMicroGtk-fdc0cc1d6db8a4297610071ab8d124b5586792c9.tar.gz
LDMicroGtk-fdc0cc1d6db8a4297610071ab8d124b5586792c9.tar.bz2
LDMicroGtk-fdc0cc1d6db8a4297610071ab8d124b5586792c9.zip
Merge branch 'Rr42-GUI_port' into GUI_port
Diffstat (limited to 'ldmicro/CMakeLists.txt')
-rw-r--r--ldmicro/CMakeLists.txt82
1 files changed, 43 insertions, 39 deletions
diff --git a/ldmicro/CMakeLists.txt b/ldmicro/CMakeLists.txt
index e0b96a9..5486fec 100644
--- a/ldmicro/CMakeLists.txt
+++ b/ldmicro/CMakeLists.txt
@@ -7,9 +7,13 @@ IF(WIN32)
add_definitions(-D__WIN32__)
ENDIF(WIN32)
+IF (MSVC)
+ MESSAGE( FATAL_ERROR "Cannot build for MacOS, exiting" )
+ add_definitions(-D__MSVC__)
+ENDIF (MSVC)
+
IF(UNIX)
add_definitions(-D__UNIX__)
- include_directories("${CMAKE_CURRENT_SOURCE_DIR}/../common/linux")
MESSAGE( STATUS "Performing system check.." )
MESSAGE( STATUS "Identifing bitness of the platform.." )
@@ -21,45 +25,45 @@ IF(UNIX)
MESSAGE( STATUS "Bitness of the platform: " 36)
endif()
MESSAGE( STATUS "Performing system check - done" )
-ENDIF(UNIX)
-
-IF (MSVC)
- MESSAGE( FATAL_ERROR "Cannot build for MacOS, exiting" )
- add_definitions(-D__MSVC__)
-ENDIF (MSVC)
-MESSAGE ( STATUS "Searching for GTK+3.0..." )
-find_package (PkgConfig REQUIRED)
-pkg_check_modules (GTK3 REQUIRED gtk+-3.0)
+ MESSAGE ( STATUS "Searching for GTK+3.0..." )
+ find_package (PkgConfig REQUIRED)
+ pkg_check_modules (GTK3 REQUIRED gtk+-3.0)
-# Version control
-set (LDMicro_VERSION_MAJOR 1)
-set (LDMicro_VERSION_MINOR 0)
+ # Version control
+ set (LDMicro_VERSION_MAJOR 1)
+ set (LDMicro_VERSION_MINOR 0)
-# configure a header file to pass some of the CMake settings
-# to the source code
-include_directories("${CMAKE_CURRENT_SOURCE_DIR}/includes")
-set(PROJECT_INCLUDE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/includes")
-CONFIGURE_FILE (
- "${PROJECT_INCLUDE_DIR}/ldmicroVC.h.in"
- "${PROJECT_INCLUDE_DIR}/ldmicroVC.h"
-)
-MESSAGE ( STATUS " PROJECT_INCLUDE_DIR: " ${PROJECT_INCLUDE_DIR} )
+ # configure a header file to pass some of the CMake settings
+ # to the source code
+ include_directories("${CMAKE_CURRENT_SOURCE_DIR}/lib/linuxUI")
+ include_directories("${CMAKE_CURRENT_SOURCE_DIR}/lib/freezeLD")
+ include_directories("${CMAKE_CURRENT_SOURCE_DIR}/includes")
+ set(PROJECT_INCLUDE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/includes")
+ CONFIGURE_FILE (
+ "${PROJECT_INCLUDE_DIR}/ldmicroVC.h.in"
+ "${PROJECT_INCLUDE_DIR}/ldmicroVC.h"
+ )
+ MESSAGE ( STATUS " PROJECT_INCLUDE_DIR: " ${PROJECT_INCLUDE_DIR} )
-
-# Add GTK3 include files if GTK3 is found
-IF ( GTK3_FOUND )
- include_directories (${GTK3_INCLUDE_DIRS})
- link_directories (${GTK3_LIBRARY_DIRS})
- add_definitions (${GTK3_CFLAGS_OTHER})
- link_libraries (${GTK3_LIBRARIES})
- MESSAGE ( STATUS " GTK3_INCLUDE_DIR: " ${GTK3_INCLUDE_DIRS} )
- MESSAGE ( STATUS " GTK3_LIBRARIES: " ${GTK3_LIBRARIES} )
-ENDIF ( GTK3_FOUND)
-
-## Dummy compile and install to test linuxUI
-## to compile LDmicro uncomment the below 2 lines
-#add_executable (LDMicro ldmicro.cpp)# miscutil.cpp draw_outputdev.cpp)
-# install (TARGETS LDMicro DESTINATION bin)
-add_executable (linuxUI linuxUI.cpp testMain.cpp)
-install (TARGETS linuxUI DESTINATION bin)
+ # Add GTK3 include files if GTK3 is found
+ IF ( GTK3_FOUND )
+ include_directories (${GTK3_INCLUDE_DIRS})
+ link_directories (${GTK3_LIBRARY_DIRS})
+ add_definitions (${GTK3_CFLAGS_OTHER})
+ link_libraries (${GTK3_LIBRARIES})
+ MESSAGE ( STATUS " GTK3_INCLUDE_DIR: " ${GTK3_INCLUDE_DIRS} )
+ MESSAGE ( STATUS " GTK3_LIBRARIES: " ${GTK3_LIBRARIES} )
+ ENDIF ( GTK3_FOUND )
+ add_subdirectory("${CMAKE_CURRENT_SOURCE_DIR}/lib/linuxUI")
+ add_subdirectory("${CMAKE_CURRENT_SOURCE_DIR}/lib/freezeLD")
+
+ ## Dummy compile and install to test linuxUI
+ ## to compile LDmicro uncomment the below 2 line2
+ #add_executable (LDMicro ldmicro.cpp)# miscutil.cpp draw_outputdev.cpp)
+ # install (TARGETS LDMicro DESTINATION bin)
+ add_executable (testMain testMain.cpp)
+ target_link_libraries (testMain LinuxUI)
+ target_link_libraries (testMain FreezeLD)
+ install (TARGETS testMain DESTINATION bin)
+ENDIF(UNIX)