- updated to 1.14.0
[packages/mupdf.git] / mupdf.spec
1 Summary:        MuPDF - lightweight PDF, XPS and CBZ viewer and parser/rendering library
2 Summary(pl.UTF-8):      MuPDF - lekka przeglÄ…darka PDF, XPS, CBZ
3 Name:           mupdf
4 Version:        1.14.0
5 Release:        1
6 License:        AGPL v3+
7 Group:          Applications/Text
8 Source0:        https://www.mupdf.com/downloads/archive/%{name}-%{version}-source.tar.gz
9 # Source0-md5:  98adc2f430cc7900397ab50a478485c5
10 URL:            https://www.mupdf.com/
11 BuildRequires:  OpenGL-glut-devel
12 BuildRequires:  curl-devel >= 7.51.0
13 BuildRequires:  freetype-devel >= 1:2.9.1
14 BuildRequires:  harfbuzz-devel >= 1.9.0
15 BuildRequires:  jbig2dec-devel >= 0.14
16 BuildRequires:  libjpeg-devel
17 BuildRequires:  libstdc++-devel
18 BuildRequires:  mujs-devel >= 1.0.4
19 BuildRequires:  openjpeg2-devel >= 2.3.0
20 BuildRequires:  openssl-devel >= 1.1.0
21 BuildRequires:  pkgconfig
22 BuildRequires:  xorg-lib-libX11-devel
23 BuildRequires:  xorg-lib-libXext-devel
24 BuildRequires:  zlib-devel >= 1.2.11
25 Requires:       curl-libs-devel >= 7.51.0
26 Requires:       freetype >= 1:2.9.1
27 Requires:       harfbuzz >= 1.9.0
28 Requires:       jbig2dec >= 0.14
29 Requires:       openjpeg2 >= 2.3.0
30 Requires:       zlib >= 1.2.11
31 Obsoletes:      mupdf-devel < 1.13.0
32 Obsoletes:      mupdf-libs < 1.13.0
33 Obsoletes:      mupdf-static < 1.13.0
34 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
35
36 %description
37 MuPDF is a lightweight PDF, XPS and CBZ viewer.
38
39 %description -l pl.UTF-8
40 MuPDF to lekka przeglÄ…darka pliki PDF, XPS i CBZ.
41
42 %prep
43 %setup -q -n %{name}-%{version}-source
44
45 # use system libs instead:
46 # curl 7.51.0
47 # freetype 2.9.1
48 # harfbuzz 1.9.0 + git update (nothing crucial)
49 # jbig2dec 0.14
50 # libjpeg 9
51 # mujs ?
52 # openjpeg 2.3.0
53 # zlib 1.2.11
54 %{__rm} -r thirdparty/{curl,freetype,jbig2dec,libjpeg,mujs,openjpeg,zlib}
55 # but keep:
56 # freeglut - 3.0.0 + some additional keyboard and clipboard APIs
57 # lcms2 - "art" fork with tread safety
58
59 %build
60 CFLAGS="%{rpmcflags} %{rpmcppflags}" \
61 LDFLAGS="%{rpmldflags}" \
62 %{__make} -j1 \
63         CC="%{__cc}" \
64         CXX="%{__cxx}" \
65         SYS_OPENJPEG_CFLAGS="$(pkg-config --cflags libopenjp2)" \
66         USE_SYSTEM_LIBS=yes \
67         USE_SYSTEM_MUJS=yes \
68         build=release \
69         libdir=%{_libdir} \
70         verbose=yes
71
72 %install
73 rm -rf $RPM_BUILD_ROOT
74
75 %{__make} install \
76         DESTDIR=$RPM_BUILD_ROOT \
77         USE_SYSTEM_LIBS=yes \
78         USE_SYSTEM_MUJS=yes \
79         build=release \
80         prefix=%{_prefix} \
81         libdir=%{_libdir}
82
83 # packaged as %doc
84 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/mupdf
85
86 %clean
87 rm -rf $RPM_BUILD_ROOT
88
89 %files
90 %defattr(644,root,root,755)
91 %doc CHANGES CONTRIBUTORS README
92 %attr(755,root,root) %{_bindir}/mupdf-gl
93 %attr(755,root,root) %{_bindir}/mupdf-x11
94 %attr(755,root,root) %{_bindir}/mutool
95 %{_mandir}/man1/mupdf.1*
96 %{_mandir}/man1/mutool.1*
This page took 0.061761 seconds and 3 git commands to generate.