%global pkgvers 0 %global scdate0 20240323 %global schash0 a46a126fb1f3b4f1dfb6040f9a90886615972198 %global branch0 master %global source0 https://gerrit.osmocom.org/libosmo-pfcp.git %global sshort0 %{expand:%%{lua:print(('%{schash0}'):sub(1,8))}} Name: libosmo-pfcp Version: 0.3.0 Release: %{scdate0}.%{pkgvers}.git%{sshort0}%{?dist} Summary: Osmocom PFCP License: GPLv2 URL: https://osmocom.org/projects/libosmo-sccp/wiki BuildRequires: git make autoconf automake libtool doxygen systemd BuildRequires: libosmocore-devel %undefine _hardened_build %undefine _annotated_build %description PFCP protocol encoding and decoding, and generic PFCP endpoint implementation. %package devel Summary: Development files for %{name} Requires: %{name} = %{version}-%{release} %description devel Development files for %{name}. %prep %setup -T -c -n %{name} git clone --depth 1 -n -b %{branch0} %{source0} . git fetch --depth 1 origin %{schash0} git reset --hard %{schash0} git log --format=fuller %build %global optflags %(echo %optflags | sed 's|-Wp,-D_GLIBCXX_ASSERTIONS||g') autoreconf -fi %configure --enable-shared \ --disable-static \ --enable-manual sed -i -e 's|tests||g' Makefile # Fix unused direct shlib dependency sed -i -e 's! -shared ! -Wl,--as-needed\0!g' libtool make %{?_smp_mflags} VERBOSE=0 %install make install DESTDIR=%{buildroot} # Remove libtool archives find %{buildroot} -name '*.la' -exec rm -f {} \; find %{buildroot} -name '*.a' -exec rm -f {} \; # versioning sed -i 's|UNKNOWN|%{version}|' %{buildroot}%{_libdir}/pkgconfig/*.pc %check make check %post -p /sbin/ldconfig %postun -p /sbin/ldconfig %files %{_libdir}/*.so.* %files devel %{_includedir}/osmocom/* %{_libdir}/*.so %{_libdir}/pkgconfig/*.pc %changelog * Fri Jan 26 2024 Cristian Balint - git update releases