]> git.pld-linux.org Git - packages/browser-plugin-esteid.git/blob - browser-plugin-esteid.spec
- release 2 (boost upgrade rebuild)
[packages/browser-plugin-esteid.git] / browser-plugin-esteid.spec
1 # TODO
2 # - new dir for gecko extensions
3 # - current firebreath version is 1.5.1
4 %define         firebreath_version 1.3.2a
5 Summary:        Estonian ID card digital signing browser plugin
6 Summary(pl.UTF-8):      Wtyczka przeglądarki do cyfrowego podpisywania przy użyciu estońskich kart eID
7 Name:           browser-plugin-esteid
8 Version:        1.2.0
9 Release:        2
10 License:        LGPL v2+
11 Group:          Applications/Networking
12 #Source0Download: http://code.google.com/p/firebreath/downloads/list
13 Source0:        http://firebreath.googlecode.com/files/firebreath-%{firebreath_version}.7z
14 # Source0-md5:  15d7bfefe21b916563b0583f4ecae675
15 #Source1Download: http://code.google.com/p/esteid/downloads/list
16 Source1:        http://esteid.googlecode.com/files/esteid-browser-plugin-%{version}.tar.bz2
17 # Source1-md5:  4a26435087b8578c5727b144e5870ae6
18 URL:            http://code.google.com/p/esteid/
19 BuildRequires:  boost-devel
20 BuildRequires:  cmake
21 BuildRequires:  gettext-devel
22 BuildRequires:  gtkmm-devel
23 BuildRequires:  libstdc++-devel
24 BuildRequires:  openssl-devel
25 BuildRequires:  p7zip
26 BuildRequires:  pkgconfig
27 BuildRequires:  rpmbuild(macros) >= 1.577
28 BuildRequires:  smartcardpp-devel
29 BuildRequires:  unzip
30 BuildRequires:  zip
31 Requires:       browser-plugins >= 2.0
32 # obsolete package name upstream uses
33 Obsoletes:      esteid-browser-plugin
34 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
35
36 # this comes from install.rdf
37 %define         extension_id    \{aa84ce40-4253-11da-8cd6-0800200c9a66\}
38
39 %description
40 Esteid Browser Plugin is cross-browser plugin that exposes Estonian
41 eID card functions via JavaScript.
42
43 The plugin is used by web pages to obtain users digital signature. To
44 protect privacy, only web pages in "whitelist" can use the card. For
45 unlisted pages, a yellow notification bar appears. The plugin also
46 implements a compatibility mode to support existing web pages that use
47 old signature APIs.
48
49 %description -l pl.UTF-8
50 Esteid Browser Plugin to wtyczka dla wielu przeglądarek udostępniająca
51 funkcje estońskich kart eID z poziomu JavaScriptu.
52
53 Wtyczka może być używana na stronach WWW w celu przesłania podpisu
54 elektronicznego użytkownika. Aby chronić prywatność, podpisu mogą
55 używać tylko strony z "białej listy". W przypadku stron nie
56 znajdujących się na liście pojawia się żółty pasek powiadomienia.
57 Wtyczka ma zaimplementowany także tryb kompatybilności obsługujący
58 istniejące strony WWW używające stare API do podpisów.
59
60 %prep
61 %setup -qcT
62 # Extract firebreath
63 7z x %{SOURCE0} >/dev/null
64 mv firebreath-%{firebreath_version}/* .
65 # Extract esteid-browser-plugin into firebreath's projects/ subdir
66 install -d projects
67 tar -xf %{SOURCE1} -C projects
68
69 %build
70 install -d build
71 cd build
72 export CXXFLAGS="%{rpmcxxflags} -fno-strict-aliasing -DBOOST_FILESYSTEM_VERSION=2"
73 export CFLAGS="$CXXFLAGS"
74 %cmake .. \
75         -DCMAKE_BUILD_WITH_INSTALL_RPATH=FALSE \
76         -DCMAKE_SKIP_RPATH=TRUE \
77         -DDOCDIR=%{_docdir} \
78         -DWITH_SYSTEM_BOOST:BOOL=YES
79
80 %{__make}
81
82
83 %install
84 rm -rf $RPM_BUILD_ROOT
85 %{__make} -C build install \
86         DESTDIR=$RPM_BUILD_ROOT
87
88 install -d $RPM_BUILD_ROOT%{_libdir}/browser-plugins
89 mv $RPM_BUILD_ROOT%{_libdir}/mozilla/plugins/npesteid.so $RPM_BUILD_ROOT%{_libdir}/browser-plugins
90
91 # Install Gecko extension
92 install -d $RPM_BUILD_ROOT%{_libdir}/mozilla/extensions/%{extension_id}
93 cp -a build/projects/esteid-browser-plugin-1/Mozilla/xpi/* \
94       $RPM_BUILD_ROOT%{_libdir}/mozilla/extensions/%{extension_id}
95
96 %find_lang esteid-browser-plugin
97
98 %clean
99 rm -rf $RPM_BUILD_ROOT
100
101 %post
102 %update_browser_plugins
103
104 %postun
105 if [ "$1" = 0 ]; then
106         %update_browser_plugins
107 fi
108
109 %files -f esteid-browser-plugin.lang
110 %defattr(644,root,root,755)
111 %doc projects/esteid-browser-plugin-%{version}/AUTHORS
112 %attr(755,root,root) %{_libdir}/browser-plugins/npesteid.so
113 %{_datadir}/esteid-browser-plugin
114 %{_libdir}/mozilla/extensions/%{extension_id}
This page took 0.074755 seconds and 3 git commands to generate.