]> git.pld-linux.org Git - packages/libzip.git/blame - libzip.spec
- updated to 1.8.0
[packages/libzip.git] / libzip.spec
CommitLineData
48e5daac
JB
1#
2# Conditional build:
3%bcond_with gnutls # GnuTLS instead of OpenSSL for AES
4
01f8639f 5Summary: C library for reading, creating, and modifying zip archives
717e415e 6Summary(pl.UTF-8): Biblioteka C do odczytu, zapisu i modyfikacji archiwów zip
01f8639f 7Name: libzip
d6b0a072
JB
8Version: 1.8.0
9Release: 1
01f8639f
MB
10License: BSD
11Group: Libraries
48e5daac 12Source0: https://libzip.org/download/%{name}-%{version}.tar.xz
d6b0a072
JB
13# Source0-md5: c0448fb7be85bc1caa87bc2fe5ab5ff8
14Patch0: %{name}-pc.patch
48e5daac
JB
15URL: https://libzip.org/
16BuildRequires: bzip2-devel
17BuildRequires: cmake >= 3.0.2
18BuildRequires: groff
d6b0a072 19# also mbedtls >= 1.0 supported
48e5daac 20%{?with_gnutls:BuildRequires: gnutls-devel}
6e3f4812 21%{?with_gnutls:BuildRequires: nettle-devel >= 3.0}
48e5daac 22%{!?with_gnutls:BuildRequires: openssl-devel}
6e3f4812 23BuildRequires: rpmbuild(macros) >= 1.605
916db4c0
JB
24BuildRequires: tar >= 1:1.22
25BuildRequires: xz
6e3f4812 26BuildRequires: xz-devel >= 1:5.2
01f8639f 27BuildRequires: zlib-devel >= 1.1.2
d6b0a072 28BuildRequires: zstd-devel
58a1b755 29Requires: zlib >= 1.1.2
6e3f4812 30Requires: xz-libs >= 1:5.2
01f8639f
MB
31BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
32
33%description
34libzip is a C library for reading, creating, and modifying zip
35archives. Files can be added from data buffers, files or compressed
36data copied directly from other zip archives. Changes made without
37closing the archive can be reverted.
38
4f9ddb84
JR
39%description -l pl.UTF-8
40libzip jest biblioteką C do odczytu, zapisu i modyfikacji archiwów
41zip. Pliki mogą być dodawane z buforów, plików lub skompresowanych
42danych kopiowanych bezpośrednio z innych archiwów zip. Wykonane zmiany
43mogą zostać cofnięte przed zamknięciem archiwum.
01f8639f
MB
44
45%package devel
46Summary: Header files for libzip library
717e415e 47Summary(pl.UTF-8): Pliki nagłówkowe biblioteki libzip
01f8639f
MB
48Group: Development/Libraries
49Requires: %{name} = %{version}-%{release}
48e5daac 50Requires: bzip2-devel
6e3f4812
JB
51%{?with_gnutls:Requires: gnutls-devel}
52%{?with_gnutls:Requires: nettle-devel >= 3.0}
53%{!?with_gnutls:Requires: openssl-devel}
54Requires: xz-devel >= 1:5.2
d11404a8 55Requires: zlib-devel >= 1.1.2
85497929 56Obsoletes: libzip-static < 1.4.0
01f8639f
MB
57
58%description devel
59Header files for libzip library.
60
4f9ddb84
JR
61%description devel -l pl.UTF-8
62Pliki nagłówkowe biblioteki libzip.
01f8639f 63
01f8639f
MB
64%prep
65%setup -q
d6b0a072 66%patch0 -p1
01f8639f
MB
67
68%build
8acd80d1
AM
69install -d build
70cd build
48e5daac
JB
71# .pc file generation expects dirs relative to CMAKE_INSTALL_PREFIX
72%cmake .. \
73 -DCMAKE_INSTALL_BINDIR=bin \
74 -DCMAKE_INSTALL_INCLUDEDIR=include \
75 -DCMAKE_INSTALL_LIBDIR=%{_lib} \
76 -DENABLE_COMMONCRYPTO=OFF \
77 %{!?with_gnutls:-DENABLE_GNUTLS=OFF} \
78 %{?with_gnutls:-DENABLE_OPENSSL=OFF}
79
01f8639f
MB
80%{__make}
81
82%install
83rm -rf $RPM_BUILD_ROOT
01f8639f 84
8acd80d1
AM
85%{__make} -C build install \
86 DESTDIR=$RPM_BUILD_ROOT
6487f921 87
01f8639f
MB
88%clean
89rm -rf $RPM_BUILD_ROOT
90
91%post -p /sbin/ldconfig
92%postun -p /sbin/ldconfig
93
94%files
95%defattr(644,root,root,755)
48e5daac 96%doc AUTHORS LICENSE NEWS.md README.md THANKS
01f8639f
MB
97%attr(755,root,root) %{_bindir}/zipcmp
98%attr(755,root,root) %{_bindir}/zipmerge
8e4c4949 99%attr(755,root,root) %{_bindir}/ziptool
8acd80d1 100%attr(755,root,root) %{_libdir}/libzip.so.*.*
a9097b68 101%attr(755,root,root) %ghost %{_libdir}/libzip.so.5
82a837b4
JB
102%{_mandir}/man1/zipcmp.1*
103%{_mandir}/man1/zipmerge.1*
8e4c4949 104%{_mandir}/man1/ziptool.1*
01f8639f
MB
105
106%files devel
107%defattr(644,root,root,755)
8acd80d1 108%doc API-CHANGES.md TODO.md
01f8639f
MB
109%attr(755,root,root) %{_libdir}/libzip.so
110%{_includedir}/zip.h
8acd80d1 111%{_includedir}/zipconf.h
6e3f4812 112%{_libdir}/cmake/libzip
01f8639f 113%{_pkgconfigdir}/libzip.pc
58a1b755 114%{_mandir}/man3/ZIP_SOURCE_GET_ARGS.3*
82a837b4
JB
115%{_mandir}/man3/libzip.3*
116%{_mandir}/man3/zip_*.3*
This page took 0.123689 seconds and 4 git commands to generate.