summaryrefslogtreecommitdiffstats
path: root/src/CMakeLists.txt
blob: 5101e76882c22068466661a51b1fa1686ccc912d (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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
include_directories(${CMAKE_CURRENT_SOURCE_DIR} ${CMPI_INCLUDE_DIR} ${GLIB_INCLUDE_DIRS})

add_library(openlmicommon SHARED
            openlmi.c
)

target_link_libraries(openlmicommon ${GLIB_LIBRARIES})

set(OPENLMICOMMON_VERSION_MAJOR 0)
set(OPENLMICOMMON_VERSION_MINOR 0)
set(OPENLMICOMMON_VERSION_PATCH 1)
set(OPENLMICOMMON_VERSION "${OPENLMICOMMON_VERSION_MAJOR}.${OPENLMICOMMON_VERSION_MINOR}.${OPENLMICOMMON_VERSION_PATCH}")

set_target_properties(openlmicommon PROPERTIES VERSION ${OPENLMICOMMON_VERSION})
set_target_properties(openlmicommon PROPERTIES SOVERSION ${OPENLMICOMMON_VERSION_MAJOR})

install(TARGETS openlmicommon DESTINATION lib${LIB_SUFFIX})
install(FILES openlmi.h DESTINATION include/openlmi)
configure_file(openlmi.pc.in openlmi.pc @ONLY)
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/openlmi.pc DESTINATION lib${LIB_SUFFIX}/pkgconfig)
install(FILES openlmi.conf DESTINATION ${SYSCONF_INSTALL_DIR}/openlmi)

if (WITH-FAN)
    add_subdirectory(fan)
endif (WITH-FAN)

if (WITH-POWER)
    add_subdirectory(power)
endif (WITH-POWER)

if (WITH-SERVICE)
    add_subdirectory(service-dbus)
endif (WITH-SERVICE)

if (WITH-ACCOUNT)
    add_subdirectory(account)
endif (WITH-ACCOUNT)

if (WITH-HARDWARE)
    add_subdirectory(hardware)
endif (WITH-HARDWARE)

if (WITH-LOGICALFILE)
    add_subdirectory(logicalfile)
endif (WITH-LOGICALFILE)

if (WITH-REALMD)
    add_subdirectory(realmd)
endif (WITH-REALMD)

if (WITH-INDMANAGER)
    add_subdirectory(indmanager)
endif (WITH-INDMANAGER)

if (WITH-SOFTWARE)
    add_subdirectory(software)
endif (WITH-SOFTWARE)

if (WITH-JOURNALD)
    add_subdirectory(journald)
endif (WITH-JOURNALD)