diff options
author | DongHun Kwak <dh0128.kwak@samsung.com> | 2019-09-10 15:38:54 +0900 |
---|---|---|
committer | DongHun Kwak <dh0128.kwak@samsung.com> | 2019-09-10 15:38:54 +0900 |
commit | 18ebbaf4f619e79231f5ad18a2ab8c135d22ef56 (patch) | |
tree | c486aa0883b10e1633d04530150251f19a56db9a /src/CMakeLists.txt | |
parent | f078975d65d0cace665590f3cf60025e6f2c7a0a (diff) | |
download | libsolv-18ebbaf4f619e79231f5ad18a2ab8c135d22ef56.tar.gz libsolv-18ebbaf4f619e79231f5ad18a2ab8c135d22ef56.tar.bz2 libsolv-18ebbaf4f619e79231f5ad18a2ab8c135d22ef56.zip |
Imported Upstream version 0.7.5upstream/0.7.5
Diffstat (limited to 'src/CMakeLists.txt')
-rw-r--r-- | src/CMakeLists.txt | 18 |
1 files changed, 13 insertions, 5 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index be487a7..f91c9c0 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -31,10 +31,18 @@ SET (libsolv_HEADERS IF (ENABLE_CONDA) SET (libsolv_SRCS ${libsolv_SRCS} conda.c) + SET (libsolv_HEADERS ${libsolv_HEADERS} conda.h) ENDIF (ENABLE_CONDA) +IF (NOT MSVC) + SET (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC") +ENDIF (NOT MSVC) + +IF (WIN32) + INCLUDE (${PROJECT_SOURCE_DIR}/win32/CMakeLists.txt) + LIST (APPEND libsolv_SRCS ${WIN32_COMPAT_SOURCES}) +ENDIF (WIN32) -SET (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC") IF (HAVE_LINKER_VERSION_SCRIPT) SET (CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} ${LINK_FLAGS} -Wl,--version-script=${CMAKE_SOURCE_DIR}/src/libsolv.ver") ENDIF (HAVE_LINKER_VERSION_SCRIPT) @@ -47,14 +55,14 @@ ENDIF (DISABLE_SHARED) SET_TARGET_PROPERTIES(libsolv PROPERTIES OUTPUT_NAME "solv") SET_TARGET_PROPERTIES(libsolv PROPERTIES SOVERSION ${LIBSOLV_SOVERSION}) -SET_TARGET_PROPERTIES(libsolv PROPERTIES INSTALL_NAME_DIR ${LIB_INSTALL_DIR}) +SET_TARGET_PROPERTIES(libsolv PROPERTIES INSTALL_NAME_DIR ${CMAKE_INSTALL_LIBDIR}) -INSTALL (FILES ${libsolv_HEADERS} DESTINATION "${INCLUDE_INSTALL_DIR}/solv") -INSTALL (TARGETS libsolv LIBRARY DESTINATION ${LIB_INSTALL_DIR} ARCHIVE DESTINATION ${LIB_INSTALL_DIR} RUNTIME DESTINATION bin) +INSTALL (FILES ${libsolv_HEADERS} DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/solv") +INSTALL (TARGETS libsolv LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}) IF (ENABLE_STATIC AND NOT DISABLE_SHARED) ADD_LIBRARY (libsolv_static STATIC ${libsolv_SRCS}) SET_TARGET_PROPERTIES(libsolv_static PROPERTIES OUTPUT_NAME "solv") SET_TARGET_PROPERTIES(libsolv_static PROPERTIES SOVERSION ${LIBSOLV_SOVERSION}) -INSTALL (TARGETS libsolv_static LIBRARY DESTINATION ${LIB_INSTALL_DIR} ARCHIVE DESTINATION ${LIB_INSTALL_DIR}) +INSTALL (TARGETS libsolv_static LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}) ENDIF (ENABLE_STATIC AND NOT DISABLE_SHARED) |