summaryrefslogtreecommitdiff
path: root/ldmicro/CMakeLists.txt
blob: c5dd29e2d61df64a74688362a88a9cb0d8d3e195 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
cmake_minimum_required (VERSION 2.6)

project (LDMicro)

IF (NOT UNIX)
    add_definitions (__WINDOWS_SYSTEM__)
    set (PKG_CONFIG_PATH "C:/path/to/gtk/lib/pkgconfig")
    set (PATH "C:/path/to/gtk/bin;%PATH%")
ENDIF (NOT UNIX)

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)

# 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)

include_directories("${CMAKE_CURRENT_SOURCE_DIR}/includes")

## Dummy compile to test linuxUI
## to compile LDmicro uncomment the below line
# add_executable (LDMicro ldmicro.cpp miscutil.cpp draw_outputdev.cpp)
add_executable (linuxUI linuxUI.cpp)

install (TARGETS LDMicro DESTINATION bin)