diff options
-rw-r--r-- | src/CMakeLists.txt | 11 | ||||
-rw-r--r-- | src/Qt/CMakeLists.txt | 3 |
2 files changed, 11 insertions, 3 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index cfbbc14..637e697 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -1,9 +1,18 @@ find_package(PythonLibs REQUIRED) include_directories(${PYTHON_INCLUDE_DIRS}) +link_directories(${PYTHON_LIBRARIES}) add_definitions(-std=c99) -add_library(c-portage dataconnect.c dict.c flag.c interpreter.c packageproperties.c portagesettings.c stringlist.c tester.c) + +set(c-portage_SRCS dataconnect.c dict.c flag.c interpreter.c packageproperties.c stringlist.c) +set(c-portage_HDRS dataconnect.h dict.h flag.h internal.h interpreter.h packageproperties.h stringlist.h) + +add_library(c-portage SHARED ${c-portage_SRCS}) +add_executable(tester tester.c) +target_link_libraries(tester c-portage ${PYTHON_LIBRARY}) + install(TARGETS c-portage DESTINATION lib) +install(FILES ${c-portage_HDRS} DESTINATION include/c-portage) option(CppPortage "Enable c++ wrapper for c-portage (uses Qt4)") diff --git a/src/Qt/CMakeLists.txt b/src/Qt/CMakeLists.txt index 1b639ec..2a19c3e 100644 --- a/src/Qt/CMakeLists.txt +++ b/src/Qt/CMakeLists.txt @@ -9,5 +9,4 @@ QT4_WRAP_CPP(cpp-portage_MOC_SRCS ${cpp-portage_HDRS}) add_library(cpp-portage qportagesettings.cpp ${cpp-portage_MOC_SRCS}) install(TARGETS cpp-portage DESTINATION lib) -install(DIRECTORY . DESTINATION include/cpp-portage - FILES_MATCHING PATTERN "*.h")
\ No newline at end of file +install(FILES ${cpp-portage_HDRS} DESTINATION include/cpp-portage)
\ No newline at end of file |