[packages/libcli] - updated to 1.10.4 (new soname)
qboosh
qboosh at pld-linux.org
Sat May 23 21:55:15 CEST 2020
commit a34705464032c853a2ee9e4f59d032a7b059e1df
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date: Sat May 23 21:55:52 2020 +0200
- updated to 1.10.4 (new soname)
libcli.spec | 57 ++++++++++++++++++++++++++++++++++++++++++++-------------
1 file changed, 44 insertions(+), 13 deletions(-)
---
diff --git a/libcli.spec b/libcli.spec
index d0bd327..01a000e 100644
--- a/libcli.spec
+++ b/libcli.spec
@@ -1,12 +1,17 @@
+#
+# Conditional build:
+%bcond_without static_libs # static library
+
Summary: Cisco-like telnet command-line library
Summary(pl.UTF-8): Biblioteka Cisco-podobnej linii poleceń telnetu
Name: libcli
-Version: 1.9.7
+Version: 1.10.4
Release: 1
License: LGPL v2.1
Group: Libraries
-Source0: https://github.com/dparrish/libcli/archive/v%{version}.tar.gz
-# Source0-md5: f33e0fdb8ae8e14e66036424704b201b
+#Source0Download: https://github.com/dparrish/libcli/releases
+Source0: https://github.com/dparrish/libcli/archive/V%{version}/%{name}-%{version}.tar.gz
+# Source0-md5: 05507ab0a08d8cad4dc0b8ed12f775a2
URL: https://github.com/dparrish/libcli
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
@@ -35,24 +40,44 @@ Header files for libcli library.
%description devel -l pl.UTF-8
Pliki nagłówkowe biblioteki libcli.
+%package static
+Summary: Static libcli library
+Summary(pl.UTF-8): Statyczna biblioteka libcli
+Group: Development/Libraries
+Requires: %{name}-devel = %{version}-%{release}
+
+%description static
+Static libcli library.
+
+%description static -l pl.UTF-8
+Statyczna biblioteka libcli.
+
%prep
%setup -q
%build
%{__make} \
CC="%{__cc}" \
- CFLAGS="%{rpmcflags}" \
- LDFLAGS='%{rpmldflags} -shared -nostartfiles -Wl,-soname,libcli.so.$(MAJOR)'
+ DEBUG= \
+ OPTIM="%{rpmcflags} %{rpmcppflags}" \
+ LDFLAGS="%{rpmldflags}" \
+ %{!?with_static_libs:STATIC_LIB=0}
%install
rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT{%{_libdir},%{_includedir}}
-install libcli.so.*.*.* $RPM_BUILD_ROOT%{_libdir}
-install libcli.h $RPM_BUILD_ROOT%{_includedir}
-# can be expanded in current directory
-ln -sf libcli.so.*.*.* $RPM_BUILD_ROOT%{_libdir}/libcli.so
-ln -sf libcli.so.*.*.* $RPM_BUILD_ROOT%{_libdir}/libcli.so.1
+%{__make} install \
+ DESTDIR=$RPM_BUILD_ROOT \
+ PREFIX=%{_prefix} \
+ %{!?with_static_libs:STATIC_LIB=0}
+
+%if "%{_lib}" != "lib"
+%{__mv} $RPM_BUILD_ROOT%{_prefix}/{lib,%{_lib}}
+%endif
+
+%if %{with static_libs}
+cp -p libcli.a $RPM_BUILD_ROOT%{_libdir}
+%endif
%clean
rm -rf $RPM_BUILD_ROOT
@@ -62,11 +87,17 @@ rm -rf $RPM_BUILD_ROOT
%files
%defattr(644,root,root,755)
-%doc README
+%doc README.md
%attr(755,root,root) %{_libdir}/libcli.so.*.*.*
-%attr(755,root,root) %ghost %{_libdir}/libcli.so.1
+%attr(755,root,root) %ghost %{_libdir}/libcli.so.1.10
%files devel
%defattr(644,root,root,755)
%attr(755,root,root) %{_libdir}/libcli.so
%{_includedir}/libcli.h
+
+%if %{with static_libs}
+%files static
+%defattr(644,root,root,755)
+%{_libdir}/libcli.a
+%endif
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/libcli.git/commitdiff/a34705464032c853a2ee9e4f59d032a7b059e1df
More information about the pld-cvs-commit
mailing list