gravatar
ladanyi@tmit.bme.hu
ladanyi@tmit.bme.hu
Generate and install LEMONConfig.cmake
0 2 1
default
3 files changed with 39 insertions and 3 deletions:
↑ Collapse diff ↑
Ignore white space 6 line context
1
SET(LEMON_INCLUDE_DIR "@CMAKE_INSTALL_PREFIX@/include" CACHE PATH "LEMON include directory")
2
SET(LEMON_INCLUDE_DIRS "${LEMON_INCLUDE_DIR}")
3

	
4
IF(UNIX)
5
  SET(LEMON_LIB_NAME "libemon.a")
6
ELSEIF(WIN32)
7
  SET(LEMON_LIB_NAME "lemon.lib")
8
ENDIF(UNIX)
9

	
10
SET(LEMON_LIBRARY "@CMAKE_INSTALL_PREFIX@/lib/${LEMON_LIB_NAME}" CACHE FILEPATH "LEMON library")
11
SET(LEMON_LIBRARIES "${LEMON_LIBRARY}")
12

	
13
MARK_AS_ADVANCED(LEMON_LIBRARY LEMON_INCLUDE_DIR)
Show white space 6 line context
... ...
@@ -32,2 +32,19 @@
32 32

	
33
CONFIGURE_FILE(
34
  ${PROJECT_SOURCE_DIR}/cmake/LEMONConfig.cmake.in
35
  ${PROJECT_BINARY_DIR}/cmake/LEMONConfig.cmake
36
  @ONLY
37
)
38
IF(UNIX)
39
  INSTALL(
40
    FILES ${PROJECT_BINARY_DIR}/cmake/LEMONConfig.cmake
41
    DESTINATION share/lemon/cmake
42
  )
43
ELSEIF(WIN32)
44
  INSTALL(
45
    FILES ${PROJECT_BINARY_DIR}/cmake/LEMONConfig.cmake
46
    DESTINATION cmake
47
  )
48
ENDIF(UNIX)
49

	
33 50
IF(${CMAKE_SOURCE_DIR} STREQUAL ${PROJECT_SOURCE_DIR})
Ignore white space 6 line context
... ...
@@ -46,2 +46,5 @@
46 46
ADD_LIBRARY(lemon ${LEMON_SOURCES})
47
IF(UNIX)
48
  SET_TARGET_PROPERTIES(lemon PROPERTIES OUTPUT_NAME emon)
49
ENDIF(UNIX)
47 50

	
... ...
@@ -50,3 +53,4 @@
50 53
  ARCHIVE DESTINATION lib
51
  COMPONENT library)
54
  COMPONENT library
55
)
52 56

	
... ...
@@ -56,3 +60,4 @@
56 60
  COMPONENT headers
57
  FILES_MATCHING PATTERN "*.h")
61
  FILES_MATCHING PATTERN "*.h"
62
)
58 63

	
... ...
@@ -61,2 +66,3 @@
61 66
  DESTINATION include/lemon
62
  COMPONENT headers)
67
  COMPONENT headers
68
)
0 comments (0 inline)