]> git.pld-linux.org Git - packages/netsurf.git/blame - netsurf.spec
- drop Werror (fails to build on current glibc)
[packages/netsurf.git] / netsurf.spec
CommitLineData
17158ae4
JB
1#
2# Conditional build:
3%bcond_without gstreamer # GStreamer-based video support
4%bcond_with pdf # PDF export and GTK+ printing support via libharu [needs update?]
5%bcond_without webp # WebP image support
6#
7Summary: Light WWW browser with CSS support
8Summary(pl.UTF-8): Lekka przeglądarka WWW z obsługą CSS
5c67da6c 9Name: netsurf
6c09c25d 10Version: 3.1
42855131 11Release: 2
17158ae4 12License: GPL v2 with OpenSSL exception (code), MIT (artwork)
5c67da6c 13Group: Applications/Networking
6c09c25d
WF
14Source0: http://download.netsurf-browser.org/netsurf/releases/source/%{name}-%{version}-src.tar.gz
15# Source0-md5: b83932b311716054a5189f121cdd5fd4
17e5188e 16Source1: %{name}.desktop
e49db766 17Patch0: nsfb-ldflags.patch
17158ae4 18Patch1: %{name}-link.patch
42855131 19Patch2: no-Werror.patch
5c67da6c 20URL: http://netsurf-browser.org/
5c67da6c 21BuildRequires: curl-devel
17158ae4
JB
22BuildRequires: freetype-devel >= 2
23%{?with_gstreamer:BuildRequires: gstreamer0.10-devel >= 0.10}
24BuildRequires: gtk+2-devel >= 2.0
25BuildRequires: js185-devel
6c09c25d
WF
26BuildRequires: libCSS-devel >= 0.3.0
27BuildRequires: libdom-devel >= 0.1.0
5c67da6c 28BuildRequires: libglade2-devel
17158ae4 29%{?with_pdf:BuildRequires: libharu-devel}
6c09c25d 30BuildRequires: libhubbub-devel >= 0.3.0
5c67da6c 31BuildRequires: libjpeg-devel
6c09c25d
WF
32BuildRequires: libnsbmp-devel >= 0.1.1
33BuildRequires: libnsfb-devel >= 0.1.1
34BuildRequires: libnsgif-devel >= 0.1.1
35BuildRequires: libparserutils-devel >= 0.2.0
5c67da6c 36BuildRequires: libpng-devel
37BuildRequires: librsvg-devel
6c09c25d
WF
38BuildRequires: libsvgtiny-devel >= 0.1.1
39BuildRequires: libwapcaplet-devel >= 0.2.1
17158ae4
JB
40%{?with_webp:BuildRequires: libwebp-devel}
41BuildRequires: openssl-devel
6c09c25d
WF
42BuildRequires: netsurf-buildsystem >= 1.1
43BuildRequires: nsgenbind >= 0.1.0
44BuildRequires: perl-HTML-Parser
5c67da6c 45BuildRequires: pkgconfig
17158ae4 46BuildRequires: sed >= 4.0
5c67da6c 47BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
48
49%description
17158ae4
JB
50NetSurf is a multi-platform lightweight web browser. Its aim is to
51provide comprehensive rendering of HTML 5 with CSS 2 in a small
52resource footprint while remaining fast.
53
54%description -l pl.UTF-8
55NetSurf to wieloplatformowa, lekka przeglądarka WWW. Celem jest
56zapewnienie kompletnego renderowania HTML 5 z CSS 2 przy małym
57wykorzystanie zasobów, z zachowaniem dużej szybkości.
5c67da6c 58
59%package common
17158ae4
JB
60Summary: NetSurf - common files
61Summary(pl.UTF-8): NetSurf - pliki wspólne
5c67da6c 62Group: Applications/Networking
63
64%description common
17158ae4 65NetSurf - common files.
5c67da6c 66
67%description common -l pl.UTF-8
17158ae4 68NetSurf - wspólne pliki.
5c67da6c 69
70%package gtk
17158ae4
JB
71Summary: NetSurf web browser - GTK+ version
72Summary(pl.UTF-8): Wersja GTK+ przeglądarki WWW NetSurf
5c67da6c 73Group: Applications/Networking
74Requires: %{name}-common = %{version}-%{release}
17158ae4
JB
75Requires: libCSS >= 0.3.0
76Requires: libdom >= 0.1.0
77Requires: libhubbub >= 0.3.0
78Requires: libnsbmp >= 0.1.1
79Requires: libnsgif >= 0.1.1
80Requires: libparserutils >= 0.2.0
81Requires: libsvgtiny >= 0.1.1
82Requires: libwapcaplet >= 0.2.1
5c67da6c 83
84%description gtk
17158ae4
JB
85NetSurf is a multi-platform lightweight web browser. Its aim is to
86provide comprehensive rendering of HTML 5 with CSS 2 in a small
87resource footprint while remaining fast.
88
89This package contains GTK+ version.
5c67da6c 90
17158ae4 91%description gtk -l pl.UTF-8
f2c002fa
JB
92NetSurf to wieloplatformowa, lekka przeglądarka WWW. Celem jest
93zapewnienie kompletnego renderowania HTML 5 z CSS 2 przy małym
94wykorzystanie zasobów, z zachowaniem dużej szybkości.
17158ae4
JB
95
96Ten pakiet zawiera wersję GTK+.
5c67da6c 97
98%package sdl
17158ae4
JB
99Summary: NetSurf web browser - SDL version
100Summary(pl.UTF-8): Wersja SDL przeglądarki WWW NetSurf
5c67da6c 101Group: Applications/Networking
102Requires: %{name}-common = %{version}-%{release}
17158ae4
JB
103Requires: libCSS >= 0.3.0
104Requires: libdom >= 0.1.0
105Requires: libhubbub >= 0.3.0
106Requires: libnsbmp >= 0.1.1
107Requires: libnsfb >= 0.1.1
108Requires: libnsgif >= 0.1.1
109Requires: libparserutils >= 0.2.0
110Requires: libsvgtiny >= 0.1.1
111Requires: libwapcaplet >= 0.2.1
5c67da6c 112
113%description sdl
17158ae4
JB
114NetSurf is a multi-platform lightweight web browser. Its aim is to
115provide comprehensive rendering of HTML 5 with CSS 2 in a small
116resource footprint while remaining fast.
117
118This package contains SDL version.
5c67da6c 119
17158ae4 120%description sdl -l pl.UTF-8
f2c002fa
JB
121NetSurf to wieloplatformowa, lekka przeglądarka WWW. Celem jest
122zapewnienie kompletnego renderowania HTML 5 z CSS 2 przy małym
123wykorzystanie zasobów, z zachowaniem dużej szybkości.
17158ae4
JB
124
125Ten pakiet zawiera wersję SDL.
5c67da6c 126
127%prep
6c09c25d 128%setup -q
e49db766 129%patch0 -p1
17158ae4 130%patch1 -p1
42855131 131%patch2 -p1
5c67da6c 132
6c09c25d 133cat << EOF > Makefile.config
5c67da6c 134NETSURF_FB_FONTLIB := freetype
17e5188e 135NETSURF_FB_FONTPATH := %{_datadir}/fonts/TTF
17158ae4
JB
136NETSURF_USE_NSSVG := YES
137NETSURF_USE_RSVG := YES
138%{?with_webp:NETSURF_USE_WEBP := YES}
139%{?with_gstreamer:NETSURF_USE_VIDEO := YES}
140%{?with_pdf:NETSURF_USE_HARU_PDF := YES}
5c67da6c 141EOF
142
17158ae4
JB
143%if %{with gstreamer}
144# GStreamer 0.10 uses now deprecated glib mutex APIs
145%{__sed} -i -e '/-DG_DISABLE_DEPRECATED/d' gtk/Makefile.target
146%endif
147
5c67da6c 148%build
2dbd7f13 149export CC="%{__cc}"
f8d10195 150# while cxx not needed, somewhy it helps race condition on carme build
2dbd7f13 151export CXX="%{__cxx}"
f8d10195
ER
152# silence -Werror:
153#src/surface/vnc.c: In function 'vnc_input':
154#src/surface/vnc.c:489:9: error: variable 'ret' set but not used [-Werror=unused-but-set-variable]
2dbd7f13
ER
155export CFLAGS="%{rpmcflags} -Wno-error=unused-but-set-variable"
156export LDFLAGS="%{rpmldflags}"
157
f8d10195
ER
158# make -j1 or it won't find libwapcaplet/libwapcaplet.h
159
2dbd7f13
ER
160%{__make} -j1 \
161 PREFIX=%{_prefix} \
5c67da6c 162 Q='' \
163 TARGET=gtk
164
2dbd7f13
ER
165%{__make} -j1 \
166 PREFIX=%{_prefix} \
5c67da6c 167 Q='' \
168 TARGET=framebuffer
169
170%install
51a5e7c1 171rm -rf $RPM_BUILD_ROOT
5c67da6c 172%{__make} install \
2dbd7f13 173 Q='' \
5c67da6c 174 PREFIX=%{_prefix} \
175 TARGET=gtk \
2dbd7f13 176 DESTDIR=$RPM_BUILD_ROOT
5c67da6c 177
178
179%{__make} install \
2dbd7f13 180 Q='' \
5c67da6c 181 PREFIX=%{_prefix} \
182 TARGET=framebuffer \
2dbd7f13 183 DESTDIR=$RPM_BUILD_ROOT
5c67da6c 184
2dbd7f13 185# this is binary from last "make install", we install more specific binary ourself
d03be798 186%{__rm} -f $RPM_BUILD_ROOT%{_bindir}/netsurf
2dbd7f13
ER
187
188install -d $RPM_BUILD_ROOT{%{_desktopdir},%{_pixmapsdir}}
189cp -p %{SOURCE1} $RPM_BUILD_ROOT%{_desktopdir}
17158ae4
JB
190install nsfb $RPM_BUILD_ROOT%{_bindir}
191install nsgtk $RPM_BUILD_ROOT%{_bindir}
5c67da6c 192
193%clean
194rm -rf $RPM_BUILD_ROOT
195
196%files common
197%defattr(644,root,root,755)
17158ae4 198%doc COPYING README
5c67da6c 199%dir %{_datadir}/%{name}
200%{_datadir}/%{name}/*
201
202%files gtk
203%defattr(644,root,root,755)
204%attr(755,root,root) %{_bindir}/nsgtk
205%{_desktopdir}/netsurf.desktop
206
207%files sdl
208%defattr(644,root,root,755)
209%attr(755,root,root) %{_bindir}/nsfb
This page took 0.151291 seconds and 4 git commands to generate.