1 | #define svn_url e:/trees/libpsl/trunk
|
---|
2 | %define svn_url http://svn.netlabs.org/repos/ports/libpsl/trunk
|
---|
3 | %define svn_rev 1823
|
---|
4 |
|
---|
5 |
|
---|
6 | Name: libpsl
|
---|
7 | Version: 0.15.0
|
---|
8 | Release: 2%{?dist}
|
---|
9 | Summary: C library for the Publix Suffix List
|
---|
10 | License: MIT
|
---|
11 | URL: https://rockdaboot.github.io/libpsl
|
---|
12 | Vendor: bww bitwise works GmbH
|
---|
13 | Source: %{name}-%{version}%{?svn_rev:-r%{svn_rev}}.zip
|
---|
14 | BuildRequires: gettext-devel
|
---|
15 | BuildRequires: glib2-devel
|
---|
16 | #BuildRequires: gtk-doc
|
---|
17 | BuildRequires: libicu-devel
|
---|
18 | BuildRequires: libxslt
|
---|
19 | #BuildRequires: publicsuffix-list
|
---|
20 | Requires: libcx >= 0.4
|
---|
21 |
|
---|
22 | %description
|
---|
23 | libpsl is a C library to handle the Public Suffix List. A "public suffix" is a
|
---|
24 | domain name under which Internet users can directly register own names.
|
---|
25 |
|
---|
26 | Browsers and other web clients can use it to
|
---|
27 |
|
---|
28 | - Avoid privacy-leaking "supercookies";
|
---|
29 | - Avoid privacy-leaking "super domain" certificates;
|
---|
30 | - Domain highlighting parts of the domain in a user interface;
|
---|
31 | - Sorting domain lists by site;
|
---|
32 |
|
---|
33 | Libpsl...
|
---|
34 |
|
---|
35 | - has built-in PSL data for fast access;
|
---|
36 | - allows to load PSL data from files;
|
---|
37 | - checks if a given domain is a "public suffix";
|
---|
38 | - provides immediate cookie domain verification;
|
---|
39 | - finds the longest public part of a given domain;
|
---|
40 | - finds the shortest private part of a given domain;
|
---|
41 | - works with international domains (UTF-8 and IDNA2008 Punycode);
|
---|
42 | - is thread-safe;
|
---|
43 | - handles IDNA2008 UTS#46;
|
---|
44 |
|
---|
45 | %package devel
|
---|
46 | Summary: Development files for %{name}
|
---|
47 | Requires: %{name} = %{version}-%{release}
|
---|
48 | #Requires: publicsuffix-list
|
---|
49 |
|
---|
50 | %description devel
|
---|
51 | This package contains libraries and header files for
|
---|
52 | developing applications that use %{name}.
|
---|
53 |
|
---|
54 | %package -n psl
|
---|
55 | Summary: Commandline utility to explore the Public Suffix List
|
---|
56 |
|
---|
57 | %description -n psl
|
---|
58 | This package contains a commandline utility to explore the Public Suffix List,
|
---|
59 | for example it checks if domains are public suffixes, checks if cookie-domain
|
---|
60 | is acceptable for domains and so on.
|
---|
61 |
|
---|
62 |
|
---|
63 | %debug_package
|
---|
64 |
|
---|
65 |
|
---|
66 | %prep
|
---|
67 | %if %{?svn_rev:%(sh -c 'if test -f "%{_sourcedir}/%{name}-%{version}-r%{svn_rev}.zip" ; then echo 1 ; else echo 0 ; fi')}%{!?svn_rev):0}
|
---|
68 | %setup -q
|
---|
69 | %else
|
---|
70 | %setup -n "%{name}-%{version}" -Tc
|
---|
71 | svn export %{?svn_rev:-r %{svn_rev}} %{svn_url} . --force
|
---|
72 | rm -f "%{_sourcedir}/%{name}-%{version}%{?svn_rev:-r%{svn_rev}}.zip"
|
---|
73 | (cd .. && zip -SrX9 "%{_sourcedir}/%{name}-%{version}%{?svn_rev:-r%{svn_rev}}.zip" "%{name}-%{version}")
|
---|
74 | %endif
|
---|
75 |
|
---|
76 | autoreconf -fiv
|
---|
77 |
|
---|
78 | %build
|
---|
79 |
|
---|
80 | export LDFLAGS="-Zhigh-mem -Zomf -Zargs-wild -Zargs-resp"
|
---|
81 | export LIBS="-lcx"
|
---|
82 | export VENDOR="%{vendor}"
|
---|
83 | # --with-psl-file=%{_datadir}/publicsuffix/effective_tld_names.dat \
|
---|
84 | # --with-psl-testfile=%{_datadir}/publicsuffix/test_psl.txt
|
---|
85 | # --enable-gtk-doc \
|
---|
86 | %configure --disable-silent-rules \
|
---|
87 | --disable-static \
|
---|
88 | --enable-man
|
---|
89 | %make_build
|
---|
90 |
|
---|
91 | %install
|
---|
92 | %make_install
|
---|
93 |
|
---|
94 | # the corresponding script is noinst
|
---|
95 | rm %{buildroot}%{_mandir}/man1/psl-make-dafsa.1*
|
---|
96 |
|
---|
97 | find %{buildroot} -name '*.la' -delete -print
|
---|
98 |
|
---|
99 | %check
|
---|
100 | #make check || cat tests/test-suite.log
|
---|
101 |
|
---|
102 | #%post -p /sbin/ldconfig
|
---|
103 |
|
---|
104 | #%postun -p /sbin/ldconfig
|
---|
105 |
|
---|
106 | %files
|
---|
107 | %license COPYING
|
---|
108 | %{_libdir}/psl*.dll
|
---|
109 |
|
---|
110 | %files devel
|
---|
111 | %doc AUTHORS NEWS
|
---|
112 | #%{_datadir}/gtk-doc/html/libpsl/
|
---|
113 | %{_includedir}/libpsl.h
|
---|
114 | %{_libdir}/psl*_dll.a
|
---|
115 | %{_libdir}/pkgconfig/libpsl.pc
|
---|
116 | #%{_mandir}/man3/libpsl.3*
|
---|
117 |
|
---|
118 | %files -n psl
|
---|
119 | %doc AUTHORS NEWS
|
---|
120 | %license COPYING
|
---|
121 | %{_bindir}/psl.exe
|
---|
122 | %{_mandir}/man1/psl.1*
|
---|
123 |
|
---|
124 | %changelog
|
---|
125 | * Thu Nov 24 2016 Silvan Scherrer <silvan.scherrer@aroa.ch> - 0.15.0-2
|
---|
126 | - libcx req is 0.4 and not 0.4.0
|
---|
127 |
|
---|
128 | * Tue Nov 15 2016 Silvan Scherrer <silvan.scherrer@aroa.ch> - 0.15.0-1
|
---|
129 | - first version
|
---|