SHA256
8
0
forked from pool/aws-c-cal

Accepting request 851117 from home:glaubitz:branches:devel:libraries:c_c++

- Add new package aws-c-cal as a transistive dependency for aws-c-eventstreams

OBS-URL: https://build.opensuse.org/request/show/851117
OBS-URL: https://build.opensuse.org/package/show/devel:libraries:c_c++/aws-c-cal?expand=0&rev=1
This commit is contained in:
2020-11-26 17:39:05 +00:00
committed by Git OBS Bridge
commit c93723d8ad
7 changed files with 200 additions and 0 deletions
+5
View File
@@ -0,0 +1,5 @@
-------------------------------------------------------------------
Thu Nov 26 15:54:04 UTC 2020 - John Paul Adrian Glaubitz <adrian.glaubitz@suse.com>
- Initial build
+ Version 0.4.5
+107
View File
@@ -0,0 +1,107 @@
#
# spec file for package aws-c-cal
#
# Copyright (c) 2020 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%define library_version 1.0.0
%define library_soversion 0unstable
Name: aws-c-cal
Version: 0.4.5
Release: 0
Summary: AWS Cross-Platform, C99 wrapper for cryptography primitives
License: Apache-2.0
Group: Development/Libraries/C and C++
URL: https://github.com/awslabs/aws-c-cal
Source0: https://github.com/awslabs/%{name}/archive/v%{version}.tar.gz
Patch0: acc_fix-cmake-modules-path.patch
Patch1: acc_add-so-version.patch
BuildRequires: cmake
BuildRequires: fdupes
BuildRequires: libaws-c-common-devel
BuildRequires: libaws-checksums-devel
BuildRequires: libopenssl-devel
BuildRequires: libs2n-devel
BuildRequires: ninja
BuildRequires: pkgconfig
%description
AWS Crypto Abstraction Layer: Cross-Platform, C99 wrapper for cryptography primitives.
%package -n lib%{name}%{library_soversion}
Summary: Shared library files for aws-c-cal library
Group: Development/Libraries/C and C++
%description -n lib%{name}%{library_soversion}
AWS Crypto Abstraction Layer: Cross-Platform, C99 wrapper for cryptography primitives.
This package contains the dynamically linked library.
%package -n lib%{name}-devel
Summary: Development files for aws-c-cal library
Group: Development/Libraries/C and C++
Requires: lib%{name}%{library_soversion} = %{version}
%description -n lib%{name}-devel
AWS Crypto Abstraction Layer: Cross-Platform, C99 wrapper for cryptography primitives.
This package contains the development files.
%package -n %{name}-bin
Summary: Command line utilities of aws-c-cal library
Group: Development/Libraries/C and C++
Requires: lib%{name}%{library_soversion} = %{version}
%description -n %{name}-bin
AWS Crypto Abstraction Layer: Cross-Platform, C99 wrapper for cryptography primitives.
This package contains the command line utilities.
%prep
%setup -q
%patch0 -p1
%patch1 -p1
%build
%define __builder ninja
%cmake \
-DCMAKE_BUILD_TYPE=Release
%make_jobs
%check
export LD_LIBRARY_PATH=%{_builddir}/%{name}-%{version}/build
%ctest
%install
%cmake_install
%post -n lib%{name}%{library_soversion} -p /sbin/ldconfig
%postun -n lib%{name}%{library_soversion} -p /sbin/ldconfig
%files -n lib%{name}%{library_soversion}
%doc README.md
%license LICENSE
%{_libdir}/*.so.%{library_soversion}
%{_libdir}/*.so.%{library_version}
%files -n lib%{name}-devel
%{_libdir}/cmake/%{name}/
%{_libdir}/*.so
%{_includedir}/*
%files -n %{name}-bin
%{_bindir}/*
%changelog
+23
View File
@@ -0,0 +1,23 @@
## Default LFS
*.7z filter=lfs diff=lfs merge=lfs -text
*.bsp filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.gem filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.jar filter=lfs diff=lfs merge=lfs -text
*.lz filter=lfs diff=lfs merge=lfs -text
*.lzma filter=lfs diff=lfs merge=lfs -text
*.obscpio filter=lfs diff=lfs merge=lfs -text
*.oxt filter=lfs diff=lfs merge=lfs -text
*.pdf filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.rpm filter=lfs diff=lfs merge=lfs -text
*.tbz filter=lfs diff=lfs merge=lfs -text
*.tbz2 filter=lfs diff=lfs merge=lfs -text
*.tgz filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
*.txz filter=lfs diff=lfs merge=lfs -text
*.whl filter=lfs diff=lfs merge=lfs -text
*.xz filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.zst filter=lfs diff=lfs merge=lfs -text
+1
View File
@@ -0,0 +1 @@
.osc
+11
View File
@@ -0,0 +1,11 @@
diff -Nru aws-c-cal-0.4.5.orig/CMakeLists.txt aws-c-cal-0.4.5/CMakeLists.txt
--- aws-c-cal-0.4.5.orig/CMakeLists.txt 2020-11-21 06:21:48.000000000 +0100
+++ aws-c-cal-0.4.5/CMakeLists.txt 2020-11-26 12:52:06.019080125 +0100
@@ -108,6 +108,7 @@
# Our ABI is not yet stable
set_target_properties(${PROJECT_NAME} PROPERTIES VERSION 1.0.0)
+set_target_properties(${CMAKE_PROJECT_NAME} PROPERTIES SOVERSION 0unstable)
target_include_directories(${PROJECT_NAME} PUBLIC
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
+50
View File
@@ -0,0 +1,50 @@
diff -Nru aws-c-cal-0.4.5.orig/CMakeLists.txt aws-c-cal-0.4.5/CMakeLists.txt
--- aws-c-cal-0.4.5.orig/CMakeLists.txt 2020-11-21 06:21:48.000000000 +0100
+++ aws-c-cal-0.4.5/CMakeLists.txt 2020-11-26 13:19:01.537346115 +0100
@@ -18,18 +18,12 @@
file(TO_CMAKE_PATH "${CMAKE_INSTALL_PREFIX}" CMAKE_INSTALL_PREFIX)
endif()
-if (UNIX AND NOT APPLE)
- include(GNUInstallDirs)
-elseif(NOT DEFINED CMAKE_INSTALL_LIBDIR)
- set(CMAKE_INSTALL_LIBDIR "lib")
-endif()
+find_package(aws-c-common REQUIRED)
+find_package(aws-checksums REQUIRED)
+set(CMAKE_MODULE_PATH ${aws-c-common_DIR})
-# This is required in order to append /lib/cmake to each element in CMAKE_PREFIX_PATH
-set(AWS_MODULE_DIR "/${CMAKE_INSTALL_LIBDIR}/cmake")
-string(REPLACE ";" "${AWS_MODULE_DIR};" AWS_MODULE_PATH "${CMAKE_PREFIX_PATH}${AWS_MODULE_DIR}")
-# Append that generated list to the module search path
-list(APPEND CMAKE_MODULE_PATH ${AWS_MODULE_PATH})
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}/cmake/modules")
+include(GNUInstallDirs)
include(AwsCFlags)
include(AwsCheckHeaders)
@@ -133,12 +127,12 @@
endif()
install(EXPORT "${PROJECT_NAME}-targets"
- DESTINATION "${LIBRARY_DIRECTORY}/${PROJECT_NAME}/cmake/${TARGET_DIR}/"
+ DESTINATION "${LIB_INSTALL_DIR}/cmake/${CMAKE_PROJECT_NAME}/${TARGET_DIR}/"
NAMESPACE AWS::
COMPONENT Development)
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}-config.cmake"
- DESTINATION "${LIBRARY_DIRECTORY}/${PROJECT_NAME}/cmake"
+ DESTINATION "${LIB_INSTALL_DIR}/cmake/${CMAKE_PROJECT_NAME}"
COMPONENT Development)
list(APPEND EXPORT_MODULES
@@ -146,7 +140,7 @@
)
install(FILES ${EXPORT_MODULES}
- DESTINATION "${LIBRARY_DIRECTORY}/${PROJECT_NAME}/cmake/modules"
+ DESTINATION "${LIB_INSTALL_DIR}/cmake/${CMAKE_PROJECT_NAME}/modules"
COMPONENT Development)
if (NOT CMAKE_CROSSCOMPILING AND NOT BYO_CRYPTO)
+3
View File
@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:0d5525045c836e0deb3b10b4832d69d3a79fd36cb9c8cd0a4f376e28e1c6ec2f
size 51956