From 579bb87f55df8a82bc699e9ac0a8952f963065ac Mon Sep 17 00:00:00 2001 From: Magnus Lundborg Date: Tue, 29 Oct 2013 10:17:44 +0100 Subject: Added install support. diff --git a/CMakeLists.txt b/CMakeLists.txt index f9f910c..30325be 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -33,6 +33,8 @@ check_include_file(inttypes.h HAVE_INTTYPES_H) add_subdirectory(src) +install(FILES include/tng_io.h DESTINATION include/) + file(COPY example_files DESTINATION .) #-- Add an Option to toggle the generation of the API documentation @@ -53,3 +55,4 @@ if(TNG_BUILD_DOCUMENTATION) # IF you do NOT want the documentation to be generated EVERY time you build the project # then leave out the 'ALL' keyword from the above command. endif() + diff --git a/src/compression/CMakeLists.txt b/src/compression/CMakeLists.txt index 91155e0..171d2b3 100644 --- a/src/compression/CMakeLists.txt +++ b/src/compression/CMakeLists.txt @@ -2,3 +2,9 @@ add_library(tng_compress bwlzh.c bwt.c coder.c dict.c fixpoint.c huffman.c huffm if(UNIX) target_link_libraries(tng_compress m) endif() + +set_property(TARGET tng_compress PROPERTY LIBRARY_OUTPUT_DIRECTORY ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}) + +install(TARGETS tng_compress + LIBRARY DESTINATION lib + ARCHIVE DESTINATION lib) diff --git a/src/lib/CMakeLists.txt b/src/lib/CMakeLists.txt index b1378ec..ade6ea8 100644 --- a/src/lib/CMakeLists.txt +++ b/src/lib/CMakeLists.txt @@ -4,6 +4,11 @@ else() add_library(tng_io tng_io.c md5.c) endif() +set_property(TARGET tng_io PROPERTY LIBRARY_OUTPUT_DIRECTORY ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}) + +install(TARGETS tng_io + LIBRARY DESTINATION lib + ARCHIVE DESTINATION lib) if(HAVE_INTTYPES_H) set_property(TARGET tng_io APPEND PROPERTY COMPILE_DEFINITIONS USE_STD_INTTYPES_H) -- cgit v0.10.1