[packages/libsigrok] - pl, added bconditional -static
qboosh
qboosh at pld-linux.org
Mon Jul 21 21:23:30 CEST 2014
commit 729324b6b0f719275e101505bfc4a4ba1dd2b5f2
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date: Mon Jul 21 21:28:41 2014 +0200
- pl, added bconditional -static
libsigrok.spec | 62 +++++++++++++++++++++++++++++++++++++++++++++-------------
1 file changed, 48 insertions(+), 14 deletions(-)
---
diff --git a/libsigrok.spec b/libsigrok.spec
index 7d12726..12cf7d4 100644
--- a/libsigrok.spec
+++ b/libsigrok.spec
@@ -1,12 +1,17 @@
+#
+# Conditional build:
+%bcond_without static_libs # static library
+
Summary: Basic hardware access drivers for logic analyzers
+Summary(pl.UTF-8): Podstawowe sterowniki dostępu do sprzętu dla analizatorów logicznych
Name: libsigrok
Version: 0.2.2
Release: 3
License: GPL v3+
Group: Libraries
-URL: http://www.sigrok.org/
Source0: http://sigrok.org/download/source/libsigrok/%{name}-%{version}.tar.gz
# Source0-md5: c14ae407e33b43cae33751246a045ab9
+URL: http://www.sigrok.org/
BuildRequires: alsa-lib-devel
BuildRequires: autoconf
BuildRequires: automake
@@ -23,18 +28,41 @@ BuildRequires: zlib-devel
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
%description
-%{name} is a shared library written in C which provides the basic API
-for talking to logic analyzer hardware and reading/writing the
+libsigrok is a shared library written in C which provides the basic
+API for talking to logic analyzer hardware and reading/writing the
acquired data into various input/output file formats.
+%description -l pl.UTF-8
+libsigrok to napisana w C biblioteka współdzielona udostępniająca
+podstawowe API do komunikacji ze sprzętowymi analizatorami logicznymi
+oraz odczytu/zapisu uzyskanych danych z/do różnych formatów plików
+wejściowych/wyjściowych.
+
%package devel
-Summary: Development files for %{name}
+Summary: Development files for libsigrok
+Summary(pl.UTF-8): Pliki programistyczne biblioteki libsigrok
Group: Development/Libraries
Requires: %{name} = %{version}-%{release}
%description devel
-The %{name}-devel package contains libraries and header files for
-developing applications that use %{name}.
+This package contains the header files for developing applications
+that use libsigrok.
+
+%description devel -l pl.UTF-8
+Ten pakiet zawiera pliki nagłówkowe do tworzenia aplikacji
+wykorzystujących bibliotekę libsigrok.
+
+%package static
+Summary: Static libsigrok library
+Summary(pl.UTF-8): Statyczna biblioteka libsigrok
+Group: Development/Libraries
+Requires: %{name} = %{version}-%{release}
+
+%description static
+Static libsigrok library.
+
+%description static -l pl.UTF-8
+Statyczna biblioteka libsigrok.
%prep
%setup -q
@@ -43,13 +71,13 @@ developing applications that use %{name}.
install -d autostuff
%{__libtoolize}
%{__aclocal}
+%{__autoconf}
%{__autoheader}
%{__automake}
-%{__autoconf}
%configure \
- --disable-static \
- --disable-silent-rules \
--enable-all-drivers \
+ --disable-silent-rules \
+ %{!?with_static_libs:--disable-static}
%{__make}
@@ -57,19 +85,19 @@ doxygen Doxyfile
%install
rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT{/lib/udev/rules.d/,%{_datadir}/sigrok-firmware}
+install -d $RPM_BUILD_ROOT{/lib/udev/rules.d,%{_datadir}/sigrok-firmware}
%{__make} install \
DESTDIR=$RPM_BUILD_ROOT
sed -e 's#plugdev#usb#g' contrib/z60_libsigrok.rules > $RPM_BUILD_ROOT/lib/udev/rules.d/60-libsigrok.rules
-%post -p /sbin/ldconfig
-%postun -p /sbin/ldconfig
-
%clean
rm -rf $RPM_BUILD_ROOT
+%post -p /sbin/ldconfig
+%postun -p /sbin/ldconfig
+
%files
%defattr(644,root,root,755)
%doc README NEWS
@@ -81,6 +109,12 @@ rm -rf $RPM_BUILD_ROOT
%files devel
%defattr(644,root,root,755)
%doc doxy/html-api/*
-%{_includedir}/libsigrok
%attr(755,root,root) %{_libdir}/libsigrok.so
+%{_includedir}/libsigrok
%{_pkgconfigdir}/libsigrok.pc
+
+%if %{with static_libs}
+%files static
+%defattr(644,root,root,755)
+%{_libdir}/libsigrok.a
+%endif
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/libsigrok.git/commitdiff/729324b6b0f719275e101505bfc4a4ba1dd2b5f2
More information about the pld-cvs-commit
mailing list