diff options
Diffstat (limited to 'linden/indra/libgpg-error/CMakeLists.txt')
-rw-r--r-- | linden/indra/libgpg-error/CMakeLists.txt | 45 |
1 files changed, 12 insertions, 33 deletions
diff --git a/linden/indra/libgpg-error/CMakeLists.txt b/linden/indra/libgpg-error/CMakeLists.txt index b3db72e..a0e6202 100644 --- a/linden/indra/libgpg-error/CMakeLists.txt +++ b/linden/indra/libgpg-error/CMakeLists.txt | |||
@@ -1,13 +1,13 @@ | |||
1 | # -*- cmake -*- | 1 | # -*- cmake -*- |
2 | 2 | ||
3 | project(libgpg-error) | ||
4 | |||
5 | include(00-Common) | 3 | include(00-Common) |
6 | include(libgpg-error) | 4 | include(libgpg-error) |
7 | include(Linking) | 5 | include(Linking) |
8 | 6 | ||
9 | if (WINDOWS) | 7 | if (WINDOWS) |
10 | 8 | ||
9 | project(gpg-error) | ||
10 | |||
11 | include_directories( | 11 | include_directories( |
12 | ../gpg.vs/inc.vs | 12 | ../gpg.vs/inc.vs |
13 | ../gpg.vs/libgpg-error-1.1.vs/custom | 13 | ../gpg.vs/libgpg-error-1.1.vs/custom |
@@ -25,7 +25,7 @@ set(libgpg-error_SOURCE_FILES | |||
25 | libgpg-error-1.0/src/strsource.c | 25 | libgpg-error-1.0/src/strsource.c |
26 | ) | 26 | ) |
27 | 27 | ||
28 | set(libgpg-error_HEADER_FILES | 28 | set(gpg-error_HEADER_FILES |
29 | CMakeLists.txt | 29 | CMakeLists.txt |
30 | 30 | ||
31 | libgpg-error-1.0/src/err-codes.h | 31 | libgpg-error-1.0/src/err-codes.h |
@@ -34,49 +34,28 @@ set(libgpg-error_HEADER_FILES | |||
34 | libgpg-error-1.0/src/gpg-error.h | 34 | libgpg-error-1.0/src/gpg-error.h |
35 | ) | 35 | ) |
36 | 36 | ||
37 | set_source_files_properties(${libgpg-error_HEADER_FILES} | 37 | set_source_files_properties(${gpg-error_HEADER_FILES} |
38 | PROPERTIES HEADER_FILE_ONLY TRUE) | 38 | PROPERTIES HEADER_FILE_ONLY TRUE) |
39 | 39 | ||
40 | list(APPEND libgpg-error_SOURCE_FILES ${libgpg-error_HEADER_FILES}) | 40 | list(APPEND gpg-error_SOURCE_FILES ${gpg-error_HEADER_FILES}) |
41 | 41 | ||
42 | add_library (libgpg-error ${libgpg-error_SOURCE_FILES}) | 42 | add_library (gpg-error ${gpg-error_SOURCE_FILES}) |
43 | target_link_libraries( | ||
44 | gpg-error | ||
45 | ) | ||
43 | 46 | ||
44 | else (WINDOWS) | 47 | else (WINDOWS) |
45 | 48 | ||
46 | include(ExternalProject) | 49 | include(ExternalProject) |
47 | 50 | ||
48 | include_directories( | ||
49 | libgpg-error-1.0/src | ||
50 | libgpg-error-1.0 | ||
51 | ) | ||
52 | |||
53 | # Gotta fake a DOWNLOAD_COMMAND to work around a bug in cmake before 2.8.3. | 51 | # Gotta fake a DOWNLOAD_COMMAND to work around a bug in cmake before 2.8.3. |
54 | externalproject_add(EP_libgpg-error | 52 | externalproject_add(gpg-error |
55 | DOWNLOAD_COMMAND "" | 53 | DOWNLOAD_COMMAND "" |
56 | PREFIX ${CMAKE_CURRENT_SOURCE_DIR}/../libgpg-error/libgpg-error-1.0 | 54 | PREFIX ${CMAKE_BINARY_DIR}/libgpg-error |
57 | SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/../libgpg-error/libgpg-error-1.0 | 55 | SOURCE_DIR ${CMAKE_SOURCE_DIR}/libgpg-error/libgpg-error-1.0 |
58 | CONFIGURE_COMMAND <SOURCE_DIR>/configure -prefix=<INSTALL_DIR> | 56 | CONFIGURE_COMMAND <SOURCE_DIR>/configure -prefix=<INSTALL_DIR> |
59 | BUILD_COMMAND ${MAKE} | ||
60 | BUILD_IN_SOURCE 1 | ||
61 | INSTALL_COMMAND make install | 57 | INSTALL_COMMAND make install |
62 | ) | 58 | ) |
63 | 59 | ||
64 | link_directories(${LIBGPG-ERROR_LIBRARIES}) | ||
65 | include_directories(${LIBGPG-ERROR_INCLUDE_DIRS}) | ||
66 | |||
67 | add_library(libgpg-error STATIC IMPORTED) | ||
68 | |||
69 | # Happy this is not needed, but leaving it around for reference. | ||
70 | #set_target_properties(libgpg-error PROPERTIES | ||
71 | # IMPORTED_LOCATION ${CMAKE_CURRENT_SOURCE_DIR}/../libgpg-error/libgpg-error-1.0/lib/libgpg-error.a | ||
72 | # ) | ||
73 | |||
74 | # This wont work until 2.8.4 sigh | ||
75 | #add_dependencies(libgpg-error EP_libgpg-error) | ||
76 | |||
77 | endif (WINDOWS) | 60 | endif (WINDOWS) |
78 | 61 | ||
79 | target_link_libraries( | ||
80 | libgpg-error | ||
81 | ) | ||
82 | |||