/alps/pcitool

To get this branch, use:
bzr branch http://darksoft.org/webbzr/alps/pcitool

« back to all changes in this revision

Viewing changes to pcitool/CMakeLists.txt

  • Committer: Suren A. Chilingaryan
  • Date: 2015-04-24 03:35:48 UTC
  • Revision ID: csa@suren.me-20150424033548-7xhacqq2s8s1t2fp
More structural changes to get ready for stand-alone event engines

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
include_directories(
2
2
    ${CMAKE_SOURCE_DIR}
3
 
)
4
 
 
5
 
set(HEADERS ${HEADERS} sysinfo.h formaters.h)
6
 
 
7
 
add_library(pcitool STATIC sysinfo.c formaters.c)
8
 
 
 
3
    ${CMAKE_SOURCE_DIR}/pcilib
 
4
    ${FASTWRITER_INCLUDE_DIRS}
 
5
)
 
6
 
 
7
link_directories(
 
8
    ${FASTWRITER_LIBRARY_DIRS}
 
9
    ${CMAKE_SOURCE_DIR}/pcilib
 
10
)
 
11
 
 
12
if (NOT DISABLE_PCITOOL)
 
13
    add_executable(pci cli.c sysinfo.c formaters.c)
 
14
    set(HEADERS ${HEADERS} sysinfo.h formaters.h)
 
15
    add_dependencies(pci pcitool)
 
16
    target_link_libraries(pci pcilib ${FASTWRITER_LIBRARIES})
 
17
    set_target_properties(pci PROPERTIES
 
18
        LINK_FLAGS ${CMAKE_THREAD_LIBS_INIT}
 
19
    )
 
20
 
 
21
#set_target_properties(pci PROPERTIES
 
22
#    LINK_FLAGS "-Wl,pcitool/libpcitool.a"
 
23
#)
 
24
 
 
25
    if(NOT DEFINED BIN_INSTALL_DIR)
 
26
        set(BIN_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/bin")
 
27
    endif(NOT DEFINED BIN_INSTALL_DIR)
 
28
 
 
29
    install(TARGETS pci
 
30
        DESTINATION ${BIN_INSTALL_DIR}
 
31
    )
 
32
endif (NOT DISABLE_PCITOOL)