[arch-commits] Commit in restbed/trunk (5 files)

Bruno Pagani archange at archlinux.org
Mon Jul 1 18:50:08 UTC 2019


    Date: Monday, July 1, 2019 @ 18:50:07
  Author: archange
Revision: 487171

upgpkg: restbed 4.6+104+gf74f932-1

Update restbed to follow Jami requirements.

Added:
  restbed/trunk/find-catch2.patch
Modified:
  restbed/trunk/PKGBUILD
Deleted:
  restbed/trunk/0001-build-Only-run-tests-if-catch2-is-installed.patch
  restbed/trunk/0002-build-make-static-shared-builds-optional.patch
  restbed/trunk/0003-build-allow-only-static-or-shared-crypto-lib.patch

---------------------------------------------------------+
 0001-build-Only-run-tests-if-catch2-is-installed.patch  |   62 ---------
 0002-build-make-static-shared-builds-optional.patch     |   88 --------------
 0003-build-allow-only-static-or-shared-crypto-lib.patch |   25 ---
 PKGBUILD                                                |   49 ++++---
 find-catch2.patch                                       |   16 ++
 5 files changed, 45 insertions(+), 195 deletions(-)

Deleted: 0001-build-Only-run-tests-if-catch2-is-installed.patch
===================================================================
--- 0001-build-Only-run-tests-if-catch2-is-installed.patch	2019-07-01 18:31:16 UTC (rev 487170)
+++ 0001-build-Only-run-tests-if-catch2-is-installed.patch	2019-07-01 18:50:07 UTC (rev 487171)
@@ -1,62 +0,0 @@
-From 5c8fc4e9a6afe0e0b5bcfa4f3e7dbb4bfe167ba1 Mon Sep 17 00:00:00 2001
-From: Baptiste Jonglez <git at bitsofnetworks.org>
-Date: Thu, 3 Jan 2019 00:47:39 +0100
-Subject: [PATCH] build: Only run tests if catch2 is installed
-
----
- CMakeLists.txt        | 14 ++++++++------
- cmake/Findcatch.cmake | 11 +++--------
- 2 files changed, 11 insertions(+), 14 deletions(-)
-
-diff --git a/CMakeLists.txt b/CMakeLists.txt
-index c618244..95889e1 100644
---- a/CMakeLists.txt
-+++ b/CMakeLists.txt
-@@ -42,7 +42,14 @@ endif ( )
- set( CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${PROJECT_SOURCE_DIR}/cmake" )
- 
- find_package( asio REQUIRED )
--find_package( catch REQUIRED )
-+find_package( catch )
-+if ( CATCH_FOUND )
-+    enable_testing( )
-+    add_subdirectory( "${PROJECT_SOURCE_DIR}/test/unit" )
-+    add_subdirectory( "${PROJECT_SOURCE_DIR}/test/feature" )
-+    add_subdirectory( "${PROJECT_SOURCE_DIR}/test/regression" )
-+    add_subdirectory( "${PROJECT_SOURCE_DIR}/test/integration" )
-+endif ( )
- if ( BUILD_SSL )
-     find_package( openssl REQUIRED )
- endif ( )
-@@ -77,11 +84,6 @@ else ( )
-     target_link_libraries( ${SHARED_LIBRARY_NAME} )
- endif ( )
- 
--enable_testing( )
--add_subdirectory( "${PROJECT_SOURCE_DIR}/test/unit" )
--add_subdirectory( "${PROJECT_SOURCE_DIR}/test/feature" )
--add_subdirectory( "${PROJECT_SOURCE_DIR}/test/regression" )
--add_subdirectory( "${PROJECT_SOURCE_DIR}/test/integration" )
- 
- #
- # Install
-diff --git a/cmake/Findcatch.cmake b/cmake/Findcatch.cmake
-index d070243..6c5be19 100644
---- a/cmake/Findcatch.cmake
-+++ b/cmake/Findcatch.cmake
-@@ -1,9 +1,4 @@
--find_path( catch_INCLUDE catch.hpp HINTS "${PROJECT_SOURCE_DIR}/dependency/catch/single_include" "/usr/include/catch2/single_include" "/usr/local/include/catch2/single_include" "/opt/local/include/catch2/single_include" )
-+find_path( catch_INCLUDE catch.hpp HINTS "${PROJECT_SOURCE_DIR}/dependency/catch/single_include" "/usr/include/catch2" "/usr/local/include/catch2/single_include" "/opt/local/include/catch2/single_include" )
- 
--if ( catch_INCLUDE )
--    set( CATCH_FOUND TRUE )
--
--    message( STATUS "Found Catch include at: ${catch_INCLUDE}" )
--else ( )
--    message( FATAL_ERROR "Failed to locate Catch dependency." )
--endif ( )
-+include(FindPackageHandleStandardArgs)
-+FIND_PACKAGE_HANDLE_STANDARD_ARGS(catch DEFAULT_MSG catch_INCLUDE)
--- 
-2.20.0
-

Deleted: 0002-build-make-static-shared-builds-optional.patch
===================================================================
--- 0002-build-make-static-shared-builds-optional.patch	2019-07-01 18:31:16 UTC (rev 487170)
+++ 0002-build-make-static-shared-builds-optional.patch	2019-07-01 18:50:07 UTC (rev 487171)
@@ -1,88 +0,0 @@
-From 23fc2778b9ce6288cdcb33ae6b40926dc7dd69bf Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Adrien=20B=C3=A9raud?= <adrien.beraud at savoirfairelinux.com>
-Date: Mon, 1 Oct 2018 16:36:08 -0400
-Subject: [PATCH] build: make static, shared builds optional
-
----
- CMakeLists.txt | 52 ++++++++++++++++++++++++++++++--------------------
- 1 file changed, 31 insertions(+), 21 deletions(-)
-
-diff --git a/CMakeLists.txt b/CMakeLists.txt
-index 2b27743..5e99964 100644
---- a/CMakeLists.txt
-+++ b/CMakeLists.txt
-@@ -7,6 +7,8 @@ message( "Copyright 2013-2018, Corvusoft Ltd, All Rights Reserved." )
- # Build Options
- #
- option( BUILD_SSL      "Build secure socket layer support."  ON )
-+option( BUILD_STATIC   "Build static library."  ON )
-+option( BUILD_SHARED   "Build shared library."  OFF )
- 
- #
- # Configuration
-@@ -61,27 +63,31 @@ include_directories( ${INCLUDE_DIR} SYSTEM ${asio_INCLUDE} ${kashmir_INCLUDE} ${
- #
- file( GLOB_RECURSE MANIFEST "${SOURCE_DIR}/*.cpp" )
- 
--set( STATIC_LIBRARY_NAME "${PROJECT_NAME}-static" )
--add_library( ${STATIC_LIBRARY_NAME} STATIC ${MANIFEST} )
--set_property( TARGET ${STATIC_LIBRARY_NAME} PROPERTY CXX_STANDARD 11 )
--set_property( TARGET ${STATIC_LIBRARY_NAME} PROPERTY CXX_STANDARD_REQUIRED ON )
--set_target_properties( ${STATIC_LIBRARY_NAME} PROPERTIES OUTPUT_NAME ${PROJECT_NAME} )
--if ( BUILD_SSL )
--    target_link_libraries( ${STATIC_LIBRARY_NAME} LINK_PRIVATE ${ssl_LIBRARY_STATIC} ${crypto_LIBRARY_STATIC} )
--else ( )
--    target_link_libraries( ${STATIC_LIBRARY_NAME} )
-+if ( BUILD_STATIC )
-+    set( STATIC_LIBRARY_NAME "${PROJECT_NAME}-static" )
-+    add_library( ${STATIC_LIBRARY_NAME} STATIC ${MANIFEST} )
-+    set_property( TARGET ${STATIC_LIBRARY_NAME} PROPERTY CXX_STANDARD 11 )
-+    set_property( TARGET ${STATIC_LIBRARY_NAME} PROPERTY CXX_STANDARD_REQUIRED ON )
-+    set_target_properties( ${STATIC_LIBRARY_NAME} PROPERTIES OUTPUT_NAME ${PROJECT_NAME} )
-+    if ( BUILD_SSL )
-+        target_link_libraries( ${STATIC_LIBRARY_NAME} LINK_PRIVATE ${ssl_LIBRARY_STATIC} ${crypto_LIBRARY_STATIC} )
-+    else ( )
-+        target_link_libraries( ${STATIC_LIBRARY_NAME} )
-+    endif ( )
- endif ( )
- 
--set( SHARED_LIBRARY_NAME "${PROJECT_NAME}-shared" )
--add_library( ${SHARED_LIBRARY_NAME} SHARED ${MANIFEST} )
--set_property( TARGET ${SHARED_LIBRARY_NAME} PROPERTY CXX_STANDARD 11 )
--set_property( TARGET ${SHARED_LIBRARY_NAME} PROPERTY CXX_STANDARD_REQUIRED ON )
--set_target_properties( ${SHARED_LIBRARY_NAME} PROPERTIES OUTPUT_NAME ${PROJECT_NAME} )
--set_target_properties( ${SHARED_LIBRARY_NAME} PROPERTIES SOVERSION ${PROJECT_VERSION_MAJOR} VERSION ${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR} )
--if ( BUILD_SSL )
--    target_link_libraries( ${SHARED_LIBRARY_NAME} LINK_PRIVATE ${ssl_LIBRARY_SHARED} ${crypto_LIBRARY_SHARED} )
--else ( )
--    target_link_libraries( ${SHARED_LIBRARY_NAME} )
-+if ( BUILD_SHARED )
-+    set( SHARED_LIBRARY_NAME "${PROJECT_NAME}-shared" )
-+    add_library( ${SHARED_LIBRARY_NAME} SHARED ${MANIFEST} )
-+    set_property( TARGET ${SHARED_LIBRARY_NAME} PROPERTY CXX_STANDARD 11 )
-+    set_property( TARGET ${SHARED_LIBRARY_NAME} PROPERTY CXX_STANDARD_REQUIRED ON )
-+    set_target_properties( ${SHARED_LIBRARY_NAME} PROPERTIES OUTPUT_NAME ${PROJECT_NAME} )
-+    set_target_properties( ${SHARED_LIBRARY_NAME} PROPERTIES SOVERSION ${PROJECT_VERSION_MAJOR} VERSION ${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR} )
-+    if ( BUILD_SSL )
-+        target_link_libraries( ${SHARED_LIBRARY_NAME} LINK_PRIVATE ${ssl_LIBRARY_SHARED} ${crypto_LIBRARY_SHARED} )
-+    else ( )
-+        target_link_libraries( ${SHARED_LIBRARY_NAME} )
-+    endif ( )
- endif ( )
- 
- 
-@@ -92,5 +98,9 @@ file( GLOB ARTIFACTS "${SOURCE_DIR}/*.hpp" )
- 
- install( FILES "${INCLUDE_DIR}/${PROJECT_NAME}" DESTINATION "${CMAKE_INSTALL_PREFIX}/include" )
- install( FILES ${ARTIFACTS} DESTINATION "${CMAKE_INSTALL_PREFIX}/include/corvusoft/${PROJECT_NAME}" )
--install( TARGETS ${STATIC_LIBRARY_NAME} LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} COMPONENT library )
--install( TARGETS ${SHARED_LIBRARY_NAME} LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} COMPONENT library )
-+if ( BUILD_STATIC )
-+    install( TARGETS ${STATIC_LIBRARY_NAME} LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} COMPONENT library )
-+endif ( )
-+if ( BUILD_SHARED )
-+    install( TARGETS ${SHARED_LIBRARY_NAME} LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} COMPONENT library )
-+endif ( )
--- 
-2.20.0
-

Deleted: 0003-build-allow-only-static-or-shared-crypto-lib.patch
===================================================================
--- 0003-build-allow-only-static-or-shared-crypto-lib.patch	2019-07-01 18:31:16 UTC (rev 487170)
+++ 0003-build-allow-only-static-or-shared-crypto-lib.patch	2019-07-01 18:50:07 UTC (rev 487171)
@@ -1,25 +0,0 @@
-From c3e28adaf8b15b34162da6c1ed5514606288f91b Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Adrien=20B=C3=A9raud?= <adrien.beraud at savoirfairelinux.com>
-Date: Sun, 21 Oct 2018 20:30:53 -0400
-Subject: [PATCH] build: allow only static or shared crypto lib
-
----
- cmake/Findopenssl.cmake | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/cmake/Findopenssl.cmake b/cmake/Findopenssl.cmake
-index 2fea2d3..2c9d7c5 100644
---- a/cmake/Findopenssl.cmake
-+++ b/cmake/Findopenssl.cmake
-@@ -24,7 +24,7 @@ if ( NOT ssl_INCLUDE )
-   find_path( ssl_INCLUDE openssl/ssl.h HINTS "${PROJECT_SOURCE_DIR}/dependency/openssl/inc32" "${PROJECT_SOURCE_DIR}/dependency/openssl/include" "/usr/local/opt/openssl/include" "/usr/include" "/usr/local/include" "/opt/local/include" NO_CMAKE_FIND_ROOT_PATH)
- endif ( )
- 
--if ( ssl_LIBRARY_STATIC AND ssl_LIBRARY_SHARED AND crypto_LIBRARY_STATIC AND crypto_LIBRARY_SHARED )
-+if ( (ssl_LIBRARY_STATIC AND crypto_LIBRARY_STATIC) OR (ssl_LIBRARY_SHARED AND crypto_LIBRARY_SHARED) )
-     set( OPENSSL_FOUND TRUE )
-     add_definitions( -DBUILD_SSL=TRUE )
- 
--- 
-2.20.0
-

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2019-07-01 18:31:16 UTC (rev 487170)
+++ PKGBUILD	2019-07-01 18:50:07 UTC (rev 487171)
@@ -3,36 +3,47 @@
 # Contributor: Justin Wilcox <nat1192 at gmail dot com>
 
 pkgname=restbed
-pkgver=4.6+89+ga1e9c97
+pkgver=4.6+104+gf74f932
 pkgrel=1
 pkgdesc="A framework for asynchronous RESTful functionality in C++11 applications"
-arch=('x86_64')
+arch=(x86_64)
 url="https://github.com/Corvusoft/restbed"
-license=('AGPL3')
-depends=('openssl')
-makedepends=('cmake' 'asio')
-checkdepends=('catch2')
-_commit=a1e9c970cf0886ab9e115f776f7d3c5dab52b964
+license=(AGPL3)
+depends=(openssl)
+makedepends=(cmake asio)
+checkdepends=(catch2)
+_commit=f74f9329dac82e662c1d570b7cd72c192b729eb4
 source=("${url}/archive/${_commit}/${pkgname}-${pkgver}.tar.gz"
-        '0001-build-Only-run-tests-if-catch2-is-installed.patch'
-        '0002-build-make-static-shared-builds-optional.patch'
-        '0003-build-allow-only-static-or-shared-crypto-lib.patch')
-sha256sums=('65c0bd66073b2646bd42b7b254820f55f8ac2ae0d1298fa64f59e104e503196e'
-            '6ec39ca415b7f09246238fb9c43664caeec71601d55545f529401e7fcedc175c'
-            'aaf94a7c0ceb94b1dbd3cd7dfe4541a99c107af5a528353615ff792b1f591673'
-            'ca6ddb1bc8a8a623d37351b418a8c897046cfb915f7760060f1f0cfe12a2c92f')
+        find-catch2.patch
+        restbed-build-allow-only-static-or-shared-crypto-lib.patch::"https://github.com/aberaud/restbed/commit/a26b364e03228de27498974bb1bbebd73145d30e.patch"
+        restbed-socket_impl-cb9caf20724c6c73782f3b42c580b8aec31e989a.patch::"https://github.com/aberaud/restbed/commit/cb9caf20724c6c73782f3b42c580b8aec31e989a.patch"
+        restbed-socket_impl-b02cbb77923349fa45348ba7cbd0d918d4610c9c.patch::"https://github.com/aberaud/restbed/commit/b02cbb77923349fa45348ba7cbd0d918d4610c9c.patch"
+        restbed-socket_impl-c88fc0aac3f041967ff35ce7f54cae222b4748da.patch::"https://github.com/aberaud/restbed/commit/c88fc0aac3f041967ff35ce7f54cae222b4748da.patch"
+        restbed-service_impl-58eaf0a1df49917145357f86c87b3f1acadaa66a.patch::"https://github.com/aberaud/restbed/commit/58eaf0a1df49917145357f86c87b3f1acadaa66a.patch")
+sha256sums=('77baf21ac79c1a4d2d604a546f74bb8ca1c2e1e0bc48f35839c92f2eadf75cb8'
+            '7f4454a875355b4d430f9d4b3408831de27d27bd760dcd70435fcfe4e1ce3c18'
+            'd1b5225f465e2a713213a59b5e0da3f17db81231ae9f1c93b67ec22fb54e02ea'
+            'ae5b70fdc06e141c2d28ca65763bfe93dc587eca1a490482cf678bea95ae1d25'
+            '38754ee2a042e37ebfdea8de10c8a27a74d86f9f3cfdb22326a280f05b6d1cd2'
+            '6b0ac759efb65d3ac741aa88a90ae647bb92c8235f7a5d66a2c453fa9b0e916f'
+            'a7e18586592e3a19130948146fabaafcc5365ff8a82098a7e047e486696d82c8')
 
 prepare() {
   mkdir -p build
   cd ${pkgname}-${_commit}
   # Allows to disable static builds
-  patch -p1 -i ../0001-build-Only-run-tests-if-catch2-is-installed.patch
-  patch -p1 -i ../0002-build-make-static-shared-builds-optional.patch
-  patch -p1 -i ../0003-build-allow-only-static-or-shared-crypto-lib.patch
+  patch -p1 -i ../restbed-build-allow-only-static-or-shared-crypto-lib.patch
+  # Find catch2 correctly
+  patch -p1 -i ../find-catch2.patch
   # Add missing include directory for tests
   sed -i -e 's/include_directories( SYSTEM /include_directories( ${INCLUDE_DIR} SYSTEM /' test/{integration,unit,regression,feature}/CMakeLists.txt
   # Force tests to use shared library, for correct dependencies and linking
   sed -i -e '/^target_link_libraries/ s#${STATIC_LIBRARY_NAME}#restbed-shared#' test/{integration,unit,regression,feature}/CMakeLists.txt
+  # Patches required by Ring/Jami
+  patch -p1 -i ../restbed-socket_impl-cb9caf20724c6c73782f3b42c580b8aec31e989a.patch
+  patch -p1 -i ../restbed-socket_impl-b02cbb77923349fa45348ba7cbd0d918d4610c9c.patch
+  patch -p1 -i ../restbed-socket_impl-c88fc0aac3f041967ff35ce7f54cae222b4748da.patch
+  patch -p1 -i ../restbed-service_impl-58eaf0a1df49917145357f86c87b3f1acadaa66a.patch
 }
 
 build() {
@@ -48,9 +59,7 @@
 
 check() {
   cd build
-  # Currently http_integration_test_suite is failing while running the wrong
-  # part of a ifdef BUILD_SSL guarded code…
-  make test || warning "Tests failed"
+  make test
 }
 
 package() {

Added: find-catch2.patch
===================================================================
--- find-catch2.patch	                        (rev 0)
+++ find-catch2.patch	2019-07-01 18:50:07 UTC (rev 487171)
@@ -0,0 +1,16 @@
+diff --git a/cmake/Findcatch.cmake b/cmake/Findcatch.cmake
+--- a/cmake/Findcatch.cmake
++++ b/cmake/Findcatch.cmake
+@@ -1,9 +1,4 @@
+-find_path( catch_INCLUDE catch.hpp HINTS "${PROJECT_SOURCE_DIR}/dependency/catch/single_include" "/usr/include/catch2/single_include" "/usr/local/include/catch2/single_include" "/opt/local/include/catch2/single_include" )
++find_path( catch_INCLUDE catch.hpp HINTS "${PROJECT_SOURCE_DIR}/dependency/catch/single_include" "/usr/include/catch2" "/usr/local/include/catch2/single_include" "/opt/local/include/catch2/single_include" )
+ 
+-if ( catch_INCLUDE )
+-    set( CATCH_FOUND TRUE )
+-
+-    message( STATUS "Found Catch include at: ${catch_INCLUDE}" )
+-else ( )
+-    message( FATAL_ERROR "Failed to locate Catch dependency." )
+-endif ( )
++include(FindPackageHandleStandardArgs)
++FIND_PACKAGE_HANDLE_STANDARD_ARGS(catch DEFAULT_MSG catch_INCLUDE)


More information about the arch-commits mailing list