From af282b9276d83cfd9a0705e27eb840d6dc8ba058 Mon Sep 17 00:00:00 2001 From: Martchus Date: Mon, 3 Jul 2017 22:47:23 +0200 Subject: Update to 189.9827cda --- .SRCINFO | 10 ++- ...y-target-pistache-to-avoid-conflict-with-.patch | 82 ---------------------- 0001-Export-targets.patch | 62 ++++++++++++++++ 0002-Export-targets.patch | 76 -------------------- PKGBUILD | 15 ++-- 5 files changed, 74 insertions(+), 171 deletions(-) delete mode 100644 0001-Call-library-target-pistache-to-avoid-conflict-with-.patch create mode 100644 0001-Export-targets.patch delete mode 100644 0002-Export-targets.patch diff --git a/.SRCINFO b/.SRCINFO index 8689171..c39df74 100644 --- a/.SRCINFO +++ b/.SRCINFO @@ -1,8 +1,8 @@ # Generated by mksrcinfo v8 -# Thu Mar 23 20:48:04 UTC 2017 +# Mon Jul 3 20:47:22 UTC 2017 pkgbase = pistache-git pkgdesc = Modern and elegant HTTP and REST framework for C++ - pkgver = 176.8604968 + pkgver = 189.9827cda pkgrel = 1 url = https://github.com/oktal/pistache arch = i686 @@ -13,11 +13,9 @@ pkgbase = pistache-git provides = pistache conflicts = pistache source = pistache::git://github.com/oktal/pistache.git - source = 0001-Call-library-target-pistache-to-avoid-conflict-with-.patch - source = 0002-Export-targets.patch + source = 0001-Export-targets.patch sha256sums = SKIP - sha256sums = 28383926baaa5f8b57f3513d21cafe8997dc779cff8170676904c39e20e7a71e - sha256sums = 4e2a5cc2bd0c1c85d9bbff03325af03fb1742aefed7dbada231e76b4ad2d20e7 + sha256sums = 68140dc3747b36e3287913cdb4e4ae1a2cc85d69e28560dee3937f6143e0cc5f pkgname = pistache-git diff --git a/0001-Call-library-target-pistache-to-avoid-conflict-with-.patch b/0001-Call-library-target-pistache-to-avoid-conflict-with-.patch deleted file mode 100644 index 1d930d6..0000000 --- a/0001-Call-library-target-pistache-to-avoid-conflict-with-.patch +++ /dev/null @@ -1,82 +0,0 @@ -From b9aac8b2d284179f2c4339e72311d61b20cc3614 Mon Sep 17 00:00:00 2001 -From: Martchus -Date: Thu, 23 Mar 2017 20:42:27 +0100 -Subject: [PATCH 1/2] Call library target pistache to avoid conflict with - libnet - ---- - examples/CMakeLists.txt | 12 ++++++------ - src/CMakeLists.txt | 12 ++++++------ - tests/CMakeLists.txt | 2 +- - 3 files changed, 13 insertions(+), 13 deletions(-) - -diff --git a/examples/CMakeLists.txt b/examples/CMakeLists.txt -index 253772d..079841b 100644 ---- a/examples/CMakeLists.txt -+++ b/examples/CMakeLists.txt -@@ -1,21 +1,21 @@ - add_executable(http_server http_server.cc) --target_link_libraries(http_server net_static) -+target_link_libraries(http_server pistache) - - add_executable(hello_server hello_server.cc) --target_link_libraries(hello_server net_static) -+target_link_libraries(hello_server pistache) - - add_executable(http_client http_client.cc) --target_link_libraries(http_client net_static) -+target_link_libraries(http_client pistache) - - add_executable(custom_header custom_header.cc) --target_link_libraries(custom_header net_static) -+target_link_libraries(custom_header pistache) - - add_executable(rest_server rest_server.cc) --target_link_libraries(rest_server net_static) -+target_link_libraries(rest_server pistache) - - find_package(RapidJSON) - if (RapidJSON_FOUND) - include_directories(${RapidJSON_INCLUDE_DIRS}) - add_executable(rest_description rest_description.cc) --target_link_libraries(rest_description net_static) -+target_link_libraries(rest_description pistache) - endif() -diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt -index 8fcecf1..60902dd 100644 ---- a/src/CMakeLists.txt -+++ b/src/CMakeLists.txt -@@ -8,11 +8,11 @@ set(SOURCE_FILES - ${CLIENT_SOURCE_FILES} - ) - --add_library(net_static ${SOURCE_FILES}) --target_link_libraries(net_static pthread) --install(TARGETS net_static DESTINATION lib) -+add_library(pistache_static ${SOURCE_FILES}) -+target_link_libraries(pistache_static pthread) -+install(TARGETS pistache_static DESTINATION lib) - --add_library(net SHARED ${SOURCE_FILES}) --target_link_libraries(net pthread) --install(TARGETS net DESTINATION lib) -+add_library(pistache SHARED ${SOURCE_FILES}) -+target_link_libraries(pistache pthread) -+install(TARGETS pistache DESTINATION lib) - -diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt -index 155a411..bcf48ab 100644 ---- a/tests/CMakeLists.txt -+++ b/tests/CMakeLists.txt -@@ -3,7 +3,7 @@ function(pistache_test test_name) - set(TEST_SOURCE ${test_name}.cc) - - add_executable(${TEST_EXECUTABLE} ${TEST_SOURCE}) -- target_link_libraries(${TEST_EXECUTABLE} gtest gtest_main net_static) -+ target_link_libraries(${TEST_EXECUTABLE} gtest gtest_main pistache) - add_test(${test_name} ${TEST_EXECUTABLE}) - endfunction() - --- -2.12.1 - diff --git a/0001-Export-targets.patch b/0001-Export-targets.patch new file mode 100644 index 0000000..2b769c0 --- /dev/null +++ b/0001-Export-targets.patch @@ -0,0 +1,62 @@ +From ef1474e0c587bb528532932c1db7e244755e5d49 Mon Sep 17 00:00:00 2001 +From: Martchus +Date: Thu, 23 Mar 2017 20:50:21 +0100 +Subject: [PATCH] Export targets + +--- + CMakeLists.txt | 2 +- + src/CMakeLists.txt | 20 ++++++++++++++++++++ + src/PistacheConfig.cmake.in | 3 +++ + 3 files changed, 24 insertions(+), 1 deletion(-) + create mode 100644 src/PistacheConfig.cmake.in + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index de5716d..25e3d7c 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -1,4 +1,4 @@ +-cmake_minimum_required (VERSION 2.8.7) ++cmake_minimum_required (VERSION 3.0.2) + project (pistache) + include(CheckCXXCompilerFlag) + +diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt +index 639ed0d..06cdb78 100644 +--- a/src/CMakeLists.txt ++++ b/src/CMakeLists.txt +@@ -40,3 +40,23 @@ install( + DIRECTORY "${PROJECT_SOURCE_DIR}/include/pistache" + DESTINATION ${include_install_dir} + FILES_MATCHING PATTERN "*.*h") ++install(TARGETS pistache ++ EXPORT PistacheTargets ++ DESTINATION lib) ++install(EXPORT PistacheTargets ++ DESTINATION "lib/cmake/pistache" ++ EXPORT_LINK_INTERFACE_LIBRARIES ++ COMPONENT cmake-config ++) ++ ++include(CMakePackageConfigHelpers) ++configure_package_config_file( ++ "PistacheConfig.cmake.in" ++ "${CMAKE_CURRENT_BINARY_DIR}/PistacheConfig.cmake" ++ INSTALL_DESTINATION "lib/cmake/pistache" ++) ++install( ++ FILES "${CMAKE_CURRENT_BINARY_DIR}/PistacheConfig.cmake" ++ DESTINATION "lib/cmake/pistache" ++ COMPONENT cmake-config ++) +diff --git a/src/PistacheConfig.cmake.in b/src/PistacheConfig.cmake.in +new file mode 100644 +index 0000000..e8e92f0 +--- /dev/null ++++ b/src/PistacheConfig.cmake.in +@@ -0,0 +1,3 @@ ++@PACKAGE_INIT@ ++ ++include("${CMAKE_CURRENT_LIST_DIR}/PistacheTargets.cmake") +-- +2.13.2 + diff --git a/0002-Export-targets.patch b/0002-Export-targets.patch deleted file mode 100644 index e390688..0000000 --- a/0002-Export-targets.patch +++ /dev/null @@ -1,76 +0,0 @@ -From 431986f951f5f5b3028e9262eed0e56d0f861dee Mon Sep 17 00:00:00 2001 -From: Martchus -Date: Thu, 23 Mar 2017 20:50:21 +0100 -Subject: [PATCH 2/2] Export targets - ---- - CMakeLists.txt | 2 +- - src/CMakeLists.txt | 29 +++++++++++++++++++++++++++-- - src/PistacheConfig.cmake.in | 4 ++++ - 3 files changed, 32 insertions(+), 3 deletions(-) - create mode 100644 src/PistacheConfig.cmake.in - -diff --git a/CMakeLists.txt b/CMakeLists.txt -index e2c9916..0197e24 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -1,4 +1,4 @@ --cmake_minimum_required (VERSION 2.8.7) -+cmake_minimum_required (VERSION 3.0.2) - project (pistache) - include(CheckCXXCompilerFlag) - -diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt -index 60902dd..c1d88e4 100644 ---- a/src/CMakeLists.txt -+++ b/src/CMakeLists.txt -@@ -10,9 +10,34 @@ set(SOURCE_FILES - - add_library(pistache_static ${SOURCE_FILES}) - target_link_libraries(pistache_static pthread) --install(TARGETS pistache_static DESTINATION lib) -+install(TARGETS pistache_static -+ EXPORT PistacheStaticTargets -+ DESTINATION lib) -+install(EXPORT PistacheStaticTargets -+ DESTINATION "lib/cmake/pistache" -+ EXPORT_LINK_INTERFACE_LIBRARIES -+ COMPONENT cmake-config -+) - - add_library(pistache SHARED ${SOURCE_FILES}) - target_link_libraries(pistache pthread) --install(TARGETS pistache DESTINATION lib) -+install(TARGETS pistache -+ EXPORT PistacheSharedTargets -+ DESTINATION lib) -+install(EXPORT PistacheSharedTargets -+ DESTINATION "lib/cmake/pistache" -+ EXPORT_LINK_INTERFACE_LIBRARIES -+ COMPONENT cmake-config -+) - -+include(CMakePackageConfigHelpers) -+configure_package_config_file( -+ "PistacheConfig.cmake.in" -+ "${CMAKE_CURRENT_BINARY_DIR}/PistacheConfig.cmake" -+ INSTALL_DESTINATION "lib/cmake/pistache" -+) -+install( -+ FILES "${CMAKE_CURRENT_BINARY_DIR}/PistacheConfig.cmake" -+ DESTINATION "lib/cmake/pistache" -+ COMPONENT cmake-config -+) -diff --git a/src/PistacheConfig.cmake.in b/src/PistacheConfig.cmake.in -new file mode 100644 -index 0000000..a5dca28 ---- /dev/null -+++ b/src/PistacheConfig.cmake.in -@@ -0,0 +1,4 @@ -+@PACKAGE_INIT@ -+ -+include("${CMAKE_CURRENT_LIST_DIR}/PistacheSharedTargets.cmake") -+include("${CMAKE_CURRENT_LIST_DIR}/PistacheStaticTargets.cmake") --- -2.12.1 - diff --git a/PKGBUILD b/PKGBUILD index a52e5ce..3291a91 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -5,7 +5,7 @@ pkgname=pistache-git _name=${pkgname%-git} -pkgver=176.8604968 +pkgver=189.9827cda pkgrel=1 arch=('i686' 'x86_64') pkgdesc='Modern and elegant HTTP and REST framework for C++' @@ -16,11 +16,9 @@ provides=("${_name}") conflicts=("${_name}") url="https://github.com/oktal/${_name}" source=("${_name}::git://github.com/oktal/${_name}.git" - '0001-Call-library-target-pistache-to-avoid-conflict-with-.patch' - '0002-Export-targets.patch') + '0001-Export-targets.patch') sha256sums=('SKIP' - '28383926baaa5f8b57f3513d21cafe8997dc779cff8170676904c39e20e7a71e' - '4e2a5cc2bd0c1c85d9bbff03325af03fb1742aefed7dbada231e76b4ad2d20e7') + '68140dc3747b36e3287913cdb4e4ae1a2cc85d69e28560dee3937f6143e0cc5f') pkgver() { cd "${srcdir}/${_name}" @@ -30,12 +28,15 @@ pkgver() { prepare() { cd "${srcdir}/${_name}" - patch -p1 -i "${srcdir}/0001-Call-library-target-pistache-to-avoid-conflict-with-.patch" - patch -p1 -i "${srcdir}/0002-Export-targets.patch" + patch -p1 -i "${srcdir}/0001-Export-targets.patch" } build() { cd "${srcdir}/${_name}" + + # since this is only a small lib and ABI seems very unstable at this point + # it should be ok to build it only as a static lib for now + cmake \ -DCMAKE_BUILD_TYPE=Release \ -DCMAKE_INSTALL_PREFIX="/usr" -- cgit v1.2.1