3 %bcond_without static_libs # static library
4 %bcond_with icu # use ICU instead of libidn2+libunistring for IDNA2008
6 Summary: C library for the Publix Suffix List
7 Summary(pl.UTF-8): Biblioteka C do obsługi listy przyrostków publicznych (Public Suffix List)
13 #Source0Download: https://github.com/rockdaboot/libpsl/releases
14 Source0: https://github.com/rockdaboot/libpsl/releases/download/%{version}/%{name}-%{version}.tar.lz
15 # Source0-md5: ebbc144e311a66cfdae503f48f21bf2d
17 # not required if packaged with libpsl release
18 %define psl_ref 1fc1ed365818a6a77d6f31d425ff03ca54cdc7f3
19 %define psldate 20150827
20 Source1: https://github.com/publicsuffix/list/archive/%{psl_ref}/publicsuffix_list-%{psldate}.tar.gz
21 # Source1-md5: ee9a591d4545d9f6ca350bd9df2c2e51
23 URL: https://rockdaboot.github.io/libpsl
24 BuildRequires: autoconf >= 2.59
25 BuildRequires: automake >= 1:1.10
26 BuildRequires: gettext-tools >= 0.18.1
27 BuildRequires: glib2-devel
28 BuildRequires: gtk-doc >= 1.15
29 %{?with_icu:BuildRequires: libicu-devel}
30 %{!?with_icu:BuildRequires: libidn2-devel}
31 BuildRequires: libtool >= 2:2
32 BuildRequires: libxslt-progs
33 BuildRequires: pkgconfig
34 BuildRequires: python >= 1:2.7
35 BuildRequires: sed >= 4.0
36 BuildRequires: tar >= 1:1.22
38 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
41 libpsl is a C library to handle the Public Suffix List. A "public
42 suffix" is a domain name under which Internet users can directly
45 Browsers and other web clients can use it to
46 - Avoid privacy-leaking "supercookies";
47 - Avoid privacy-leaking "super domain" certificates;
48 - Domain highlighting parts of the domain in a user interface;
49 - Sorting domain lists by site;
52 - has built-in PSL data for fast access;
53 - allows to load PSL data from files;
54 - checks if a given domain is a "public suffix";
55 - provides immediate cookie domain verification;
56 - finds the longest public part of a given domain;
57 - finds the shortest private part of a given domain;
58 - works with international domains (UTF-8 and IDNA2008 Punycode);
60 - handles IDNA2008 UTS#46;
62 %description -l pl.UTF-8
63 libpsl to biblioteka C do obsługi listy przyrostków publicznych
64 (Public Suffix List). "Przyrostek publiczny" to nazwa domeny, poniżej
65 której bezpośrednio użytkownicy Internetu mogą rejestrować własne
68 Przeglądarki i inni klienci WWW mogą jej używać w celu:
69 - zapobieganiu "superciasteczek" naruszającym prywatność
70 - zapobieganiu certyfikatom "superdomenowym" naruszającym prywatność
71 - podświetlania części domen w interfejsie użytkownika
72 - sortowania listy domen według serwisu.
75 - ma wbudowane dane PSL dla szybkiego dostępu
76 - pozwala na wczytywanie danych PSL z plików
77 - sprawdza, czy dana domena jest "przyrostkiem publicznym"
78 - zapewnia natychmiastową weryfikację domeny ciasteczka
79 - znajduje najdłuższą publiczną część podanej domeny
80 - znajduje najkrótszą prywatną część podanej domeny
81 - działa z domenami międzynarodowymi (UTF-8 i IDNA2008 Punycode)
82 - jest bezpieczna względem wątków
83 - obsługuje IDNA2008 UTS#46.
86 Summary: Development files for libpsl
87 Summary(pl.UTF-8): Pliki programistyczne biblioteki libpsl
88 Group: Development/Libraries
89 Requires: %{name} = %{version}-%{release}
92 This package contains the header file for developing applications that
95 %description devel -l pl.UTF-8
96 Ten pakiet zawiera plik nagłówkowy do tworzenia aplikacji
97 wykorzystujących bibliotekę libpsl.
100 Summary: Static libpsl library
101 Summary(pl.UTF-8): Statyczna biblioteka libpsl
102 Group: Development/Libraries
103 Requires: %{name}-devel = %{version}-%{release}
106 Static libpsl library.
108 %description static -l pl.UTF-8
109 Statyczna biblioteka libpsl.
112 Summary: API documentation for libpsl library
113 Summary(pl.UTF-8): Dokumentacja API biblioteki libpsl
115 %if "%{_rpmversion}" >= "4.6"
120 API documentation for libpsl library.
122 %description apidocs -l pl.UTF-8
123 Dokumentacja API biblioteki libpsl.
126 Summary: Commandline utility to explore the Public Suffix List
127 Summary(pl.UTF-8): Narzędzie linii poleceń do eksplorowania listy przyrostków publicznych
128 Group: Applications/Networking
129 Requires: %{name} = %{version}-%{release}
132 This package contains a commandline utility to explore the Public
133 Suffix List, for example it checks if domains are public suffixes,
134 checks if cookie-domain is acceptable for domains and so on.
136 %description utils -l pl.UTF-8
137 Ten pakiet zawiera narzędzie linii poleceń do eksplorowania listy
138 przyrostków publicznych (Public Suffix List); sprawdza ono na
139 przykład, czy domeny są przyrostkami publicznymi, czy domena
140 ciasteczka jest akceptowalna dla domen itp.
147 %{__tar} xf %{SOURCE1}
148 %{__mv} list-%{psl_ref} list
160 --disable-silent-rules \
161 %{!?with_static_libs:--disable-static} \
164 --enable-builtin=%{?with_icu:libicu}%{!?with_icu:libidn2} \
165 --enable-runtime=%{?with_icu:libicu}%{!?with_icu:libidn2} \
166 --with-html-dir=%{_gtkdocdir}
170 %{?with_tests:%{__make} check}
173 rm -rf $RPM_BUILD_ROOT
175 DESTDIR=$RPM_BUILD_ROOT
177 # obsoleted by pkg-config
178 %{__rm} $RPM_BUILD_ROOT%{_libdir}/libpsl.la
180 %{__rm} $RPM_BUILD_ROOT%{_mandir}/man1/psl-make-dafsa.1
183 rm -rf $RPM_BUILD_ROOT
185 %post -p /sbin/ldconfig
186 %postun -p /sbin/ldconfig
189 %defattr(644,root,root,755)
190 %doc AUTHORS COPYING NEWS
191 %attr(755,root,root) %{_libdir}/libpsl.so.*.*.*
192 %attr(755,root,root) %ghost %{_libdir}/libpsl.so.5
195 %defattr(644,root,root,755)
196 %attr(755,root,root) %{_libdir}/libpsl.so
197 %{_includedir}/libpsl.h
198 %{_pkgconfigdir}/libpsl.pc
199 %{_mandir}/man3/libpsl.3*
201 %if %{with static_libs}
203 %defattr(644,root,root,755)
208 %defattr(644,root,root,755)
212 %defattr(644,root,root,755)
213 %attr(755,root,root) %{_bindir}/psl
214 %{_mandir}/man1/psl.1*