| |
@@ -1,17 +1,34 @@
|
| |
Name: libss7
|
| |
Version: 2.0.0
|
| |
- Release: 4%{?dist}
|
| |
+ Release: 5%{?dist}
|
| |
+ %global so_version 2
|
| |
Summary: SS7 protocol services to applications
|
| |
|
| |
|
| |
License: GPLv2
|
| |
|
| |
- URL: http://www.asterisk.org/
|
| |
- Source0: http://downloads.digium.com/pub/telephony/libss7/releases/libss7-%{version}.tar.gz
|
| |
+ URL: https://www.asterisk.org/
|
| |
+ %global src_base https://downloads.asterisk.org/pub/telephony/%{name}/releases
|
| |
+ Source0: %{src_base}/%{name}-%{version}.tar.gz
|
| |
+ Source1: %{src_base}/%{name}-%{version}.tar.gz.asc
|
| |
+ # Keyring with developer signatures created on 2020-12-04 with:
|
| |
+ #
|
| |
+ # gpg --with-fingerprint libss7-2.0.0.tar.gz.asc 2>&1 |
|
| |
+ # awk '$2 == "using" { print "0x" $NF }' |
|
| |
+ # xargs gpg2 --no-default-keyring --keyring ./libss7-tmp.gpg \
|
| |
+ # --keyserver=hkp://pool.sks-keyservers.net --recv-keys
|
| |
+ # gpg2 --export --export-options export-minimal --keyring ./libss7-tmp.gpg \
|
| |
+ # > libss7.gpg
|
| |
+ # rm -f ./libss7-tmp.gpg
|
| |
+ #
|
| |
+ # Inspect keys using: gpg --list-keys --keyring ./libss7.gpg
|
| |
+ Source2: %{name}.gpg
|
| |
|
| |
|
| |
BuildRequires: gcc
|
| |
- BuildRequires: make
|
| |
+ BuildRequires: make
|
| |
+ BuildRequires: gnupg2
|
| |
+
|
| |
%description
|
| |
libss7 is a userspace library that is used for providing SS7 protocol
|
| |
services to applications. It has a working MTP2, MTP3, and ISUP for
|
| |
@@ -21,36 +38,68 @@
|
| |
|
| |
%package devel
|
| |
Summary: Development files for %{name}
|
| |
- Requires: %{name} = %{version}-%{release}
|
| |
+ Requires: %{name}%{?_isa} = %{version}-%{release}
|
| |
|
| |
%description devel
|
| |
The %{name}-devel package contains libraries and header files for
|
| |
developing applications that use %{name}.
|
| |
|
| |
%prep
|
| |
- %setup0 -q
|
| |
+ %{gpgverify} --keyring='%{SOURCE2}' --signature='%{SOURCE1}' --data='%{SOURCE0}'
|
| |
+ %setup -q
|
| |
|
| |
%build
|
| |
- make %{?_smp_mflags} CFLAGS="$RPM_OPT_FLAGS -fPIC"
|
| |
+ %set_build_flags
|
| |
+ # The warnings here look like real problems, and should be reported upstream. A
|
| |
+ # sample is below:
|
| |
+ #
|
| |
+ # In file included from /usr/include/string.h:519,
|
| |
+ # from isup.c:32:
|
| |
+ # In function 'strncpy',
|
| |
+ # inlined from 'isup_set_calling' at isup.c:2879:4,
|
| |
+ # inlined from 'isup_set_calling' at isup.c:2875:6:
|
| |
+ # /usr/include/bits/string_fortified.h:91:10: error: 'strncpy' specified bound 64 equals destination size [-Werror=stringop-truncation]
|
| |
+ # 91 | return __builtin___strncpy_chk (__dest, __src, __len, __bos (__dest));
|
| |
+ # | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| |
+ export CFLAGS="${CFLAGS} -Wno-error=stringop-truncation"
|
| |
+ %make_build
|
| |
|
| |
%install
|
| |
- rm -rf $RPM_BUILD_ROOT
|
| |
- make install INSTALL_PREFIX=$RPM_BUILD_ROOT libdir=%{_libdir}
|
| |
- #ln -s libss7.so.1.0 $RPM_BUILD_ROOT%{_libdir}/libss7.so.1
|
| |
- find $RPM_BUILD_ROOT -name '*.a' -exec rm -f {} ';'
|
| |
+ %make_install libdir=%{_libdir}
|
| |
+ find %{buildroot} -name '*.a' -print -delete
|
| |
|
| |
+ %if 0%{?epel} && 0%{?epel} < 8
|
| |
%ldconfig_scriptlets
|
| |
+ %endif
|
| |
|
| |
%files
|
| |
- %doc ChangeLog NEWS* README LICENSE
|
| |
- %{_libdir}/*.so.*
|
| |
+ %license LICENSE
|
| |
+ %doc ChangeLog NEWS* README
|
| |
+ %{_libdir}/%{name}.so.%{so_version}*
|
| |
|
| |
%files devel
|
| |
- %doc README LICENSE
|
| |
- %{_includedir}/*
|
| |
- %{_libdir}/*.so
|
| |
+ %{_includedir}/%{name}.h
|
| |
+ %{_libdir}/%{name}.so
|
| |
|
| |
%changelog
|
| |
+ * Sun Feb 14 2021 Benjamin A. Beasley <code@musicinmybrain.net> - 2.0.0-5
|
| |
+ - Make dependency from -devel subpackage on main package arch-specific
|
| |
+ - Use %%setup macro instead of %%setup0
|
| |
+ - Remove obsolete %%ldconfig_scriptlets, except for EPEL7
|
| |
+ - Use make macros
|
| |
+ - Do not remove the buildroot in %%install
|
| |
+ - Remove static libraries directly with find rather than calling rm
|
| |
+ - Remove unnecessary README from -devel, since it is installed with the main
|
| |
+ package
|
| |
+ - Correctly use the %%license macro
|
| |
+ - Use tighter file globs; in particular, per the packaging guidelines, specify
|
| |
+ the current so-version so that a version bump in an update will not be missed
|
| |
+ so easily
|
| |
+ - Switch URLs from HTTP to HTTPS
|
| |
+ - Add source file signature verification
|
| |
+ - Allow build to continue past string operation truncation warnings
|
| |
+ - Remove obsolete commented-out manual symlink command
|
| |
+
|
| |
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.0-4
|
| |
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
|
| |
|
| |
See changelog entry for details. Let me know if there is something you disagree with.