Compare commits

...

No commits in common. 'epel9' and 'i9' have entirely different histories.
epel9 ... i9

34
.gitignore vendored

@ -1,33 +1 @@
/mupdf-0.7.tar.gz
/mupdf-0.8.15-source.tar.gz
/mupdf-0.8.165-source.tar.gz
/mupdf-0.9-source.tar.gz
/mupdf-1.0-source.tar.gz
/mupdf-1.1-source.tar.gz
/mupdf-1.4-source.tar.gz
/mupdf-1.5-source.tar.gz
/mupdf-1.7-source.tar.gz
/mupdf-1.7a-source.tar.gz
/mupdf-1.8-source.tar.gz
/mupdf-1.10a-source.tar.gz
/mupdf-1.11-source.tar.gz
/mupdf-1.12-rc1-source.tar.gz
/mupdf-1.12.0-source.tar.gz
/mupdf-1.13.0-rc1-source.tar.gz
/mupdf-1.13.0-source.tar.gz
/mupdf-1.14.0-rc1-source.tar.gz
/mupdf-1.14.0-source.tar.gz
/mupdf-1.15.0-rc1-source.tar.gz
/mupdf-1.15.0-source.tar.gz
/mupdf-1.16.1-source.tar.gz
/mupdf-1.17.0-source.tar.gz
/mupdf-1.18.0-rc1-source.tar.gz
/mupdf-1.18.0-source.tar.gz
/mupdf-1.19.0-source.tar.gz
/mupdf-1.20.0-rc1-source.tar.gz
/mupdf-1.20.0-rc2-source.tar.gz
/mupdf-1.20.0-source.tar.gz
/mupdf-1.20.3-source.tar.gz
/mupdf-1.21.0-rc1-source.tar.gz
/mupdf-1.21.0-source.tar.gz
/mupdf-1.21.1-source.tar.gz
SOURCES/mupdf-1.21.1-source.tar.gz

@ -0,0 +1 @@
eb6e6c468416f7ad9f37be33ae00f899dad237e2 SOURCES/mupdf-1.21.1-source.tar.gz

@ -1,42 +0,0 @@
From 43f2c1076467570fbd999116eb42266ec2b6cc78 Mon Sep 17 00:00:00 2001
Message-ID: <43f2c1076467570fbd999116eb42266ec2b6cc78.1735230633.git.mjg@fedoraproject.org>
From: Sebastian Rasmussen <sebras@gmail.com>
Date: Mon, 2 Sep 2024 22:06:32 +0200
Subject: [PATCH] Bug 707996: Declare variable fz_var to avoid stale values.
A fuzzed file provoked an ASAN warning when building release mode.
For good measure, also declare a variable in an unrelated function
in the same tool fz_var.
(cherry picked from commit b5c898a30f068b5342e8263a2cd5b9f0be291aac)
---
source/tools/pdfextract.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/source/tools/pdfextract.c b/source/tools/pdfextract.c
index 0b42e9189..dc1f2c23f 100644
--- a/source/tools/pdfextract.c
+++ b/source/tools/pdfextract.c
@@ -119,6 +119,7 @@ static void saveimage(pdf_obj *ref)
int type;
fz_var(image);
+ fz_var(mask);
fz_var(pix);
fz_try(ctx)
@@ -252,7 +253,9 @@ static void savefont(pdf_obj *dict)
static void extractobject(int num)
{
- pdf_obj *ref;
+ pdf_obj *ref = NULL;
+
+ fz_var(ref);
if (!doc)
fz_throw(ctx, FZ_ERROR_GENERIC, "no file specified");
--
2.48.0.rc0.310.g2fcc1078a8

@ -1,3 +1,201 @@
## START: Set by rpmautospec
## (rpmautospec version 0.3.5)
## RPMAUTOSPEC: autorelease, autochangelog
%define autorelease(e:s:pb:n) %{?-p:0.}%{lua:
release_number = 5;
base_release_number = tonumber(rpm.expand("%{?-b*}%{!?-b:1}"));
print(release_number + base_release_number - 1);
}%{?-e:.%{-e*}}%{?-s:.%{-s*}}%{!?-n:%{?dist}}
## END: Set by rpmautospec
# Desired jbig2dec header files and library version
# Apparantly, jbig2dec complains even about newer versions.
# Please update if needed.
%global jbig2dec_version 0.19
Name: mupdf
Version: 1.21.1
# upstream prerelease versions tags need to be translated to Fedorian
%global upversion %{version}
Release: %autorelease
Summary: A lightweight PDF viewer and toolkit
License: AGPL-3.0-or-later
URL: http://mupdf.com/
Source0: http://mupdf.com/downloads/archive/%{name}-%{upversion}-source.tar.gz
Source1: %{name}.desktop
Source2: %{name}-gl.desktop
Patch: mupdf-1.21.1-fix-png_write_band.patch
BuildRequires: gcc gcc-c++ make binutils desktop-file-utils coreutils pkgconfig
BuildRequires: openjpeg2-devel desktop-file-utils
BuildRequires: libjpeg-devel freetype-devel libXext-devel curl-devel
BuildRequires: harfbuzz-devel openssl-devel mesa-libEGL-devel
BuildRequires: mesa-libGL-devel mesa-libGLU-devel libXi-devel libXrandr-devel
BuildRequires: gumbo-parser-devel leptonica-devel tesseract-devel
BuildRequires: jbig2dec-devel = %{jbig2dec_version}
BuildRequires: jbig2dec-libs = %{jbig2dec_version}
Requires: jbig2dec-libs = %{jbig2dec_version}
# We need to build against the Artifex fork of lcms2 so that we are thread safe
# (see bug #1553915). Artifex make sure to rebase against upstream, who refuse
# to integrate Artifex's changes.
Provides: bundled(lcms2-devel) = 2.14~rc1^59-g88b6a72
# We need to build against the Artifex fork of freeglut so that we are unicode safe.
Provides: bundled(freeglut-devel) = 3.0.0^11.g13ae6aa
# muPDF needs the muJS sources for the build even if we build against the system
# version so bundling them is the safer choice.
Provides: bundled(mujs-devel) = 1.3.2
# muPDF builds only against in-tree extract which is versioned along with ghostpdl.
Provides: bundled(extract) = 9.56.0^53-gc18d9f3
%description
MuPDF is a lightweight PDF viewer and toolkit written in portable C.
The renderer in MuPDF is tailored for high quality anti-aliased
graphics. MuPDF renders text with metrics and spacing accurate to
within fractions of a pixel for the highest fidelity in reproducing
the look of a printed page on screen.
MuPDF has a small footprint. A binary that includes the standard
Roman fonts is only one megabyte. A build with full CJK support
(including an Asian font) is approximately seven megabytes.
MuPDF has support for all non-interactive PDF 1.7 features, and the
toolkit provides a simple API for accessing the internal structures of
the PDF document. Example code for navigating interactive links and
bookmarks, encrypting PDF files, extracting fonts, images, and
searchable text, and rendering pages to image files is provided.
%package devel
Summary: Development files for %{name}
Requires: %{name} = %{version}-%{release}
Provides: %{name}-static = %{version}-%{release}
%description devel
The mupdf-devel package contains header files for developing
applications that use mupdf and static libraries
%prep
%autosetup -p1 -n %{name}-%{upversion}-source
for d in $(ls thirdparty | grep -v -e extract -e freeglut -e lcms2 -e mujs)
do
rm -rf thirdparty/$d
done
echo > user.make "\
USE_SYSTEM_FREETYPE := yes
USE_SYSTEM_HARFBUZZ := yes
USE_SYSTEM_JBIG2DEC := yes
USE_SYSTEM_JPEGXR := yes # not used without HAVE_JPEGXR
USE_SYSTEM_LCMS2 := no # need lcms2-art fork
USE_SYSTEM_LIBJPEG := yes
USE_SYSTEM_MUJS := no # build needs source anyways
USE_SYSTEM_OPENJPEG := yes
USE_SYSTEM_ZLIB := yes
USE_SYSTEM_GLUT := no # need freeglut2-art fork
USE_SYSTEM_CURL := yes
USE_SYSTEM_GUMBO := yes
USE_TESSERACT := yes
USE_SYSTEM_LEPTONICA := yes
USE_SYSTEM_TESSERACT := yes
"
%build
export XCFLAGS="%{optflags} -fPIC -DJBIG_NO_MEMENTO -DTOFU -DTOFU_CJK_EXT"
make %{?_smp_mflags} build=debug verbose=yes
%install
make DESTDIR=%{buildroot} install prefix=%{_prefix} libdir=%{_libdir} build=debug verbose=yes
## handle docs on our own
rm -rf %{buildroot}/%{_docdir}
desktop-file-install --dir=%{buildroot}%{_datadir}/applications %{SOURCE1}
desktop-file-install --dir=%{buildroot}%{_datadir}/applications %{SOURCE2}
mkdir -p %{buildroot}%{_datadir}/icons/hicolor/scalable/apps
install -p -m644 docs/logo/mupdf-logo.svg %{buildroot}%{_datadir}/icons/hicolor/scalable/apps/mupdf.svg
install -p -m644 docs/logo/mupdf-logo.svg %{buildroot}%{_datadir}/icons/hicolor/scalable/apps/mupdf-gl.svg
## fix strange permissons
chmod 0644 %{buildroot}%{_libdir}/*.a
find %{buildroot}/%{_mandir} -type f -exec chmod 0644 {} \;
find %{buildroot}/%{_includedir} -type f -exec chmod 0644 {} \;
cd %{buildroot}/%{_bindir} && ln -s %{name}-x11 %{name}
%files
%license COPYING
%doc README CHANGES docs/*
%{_bindir}/*
%{_datadir}/applications/mupdf*.desktop
%{_datadir}/icons/hicolor/*/apps/*
%{_mandir}/man1/*.1.gz
%files devel
%{_includedir}/%{name}
%{_libdir}/lib%{name}*.a
%changelog
* Fri Sep 08 2023 Arkady L. Shane <ashejn@msvsphere.ru> - 1.21.1-5
- Rebuilt for MSVSphere 9.2
* Fri Dec 23 2022 Sandro Mani <manisandro@gmail.com> - 1.21.1-5
- Rebuild (tesseract)
* Wed Dec 21 2022 Sandro Mani <manisandro@gmail.com> - 1.21.1-4
- Rebuild (leptonica)
* Tue Dec 20 2022 Michael J Gruber <mjg@fedoraproject.org> - 1.21.1-3
- fix png_write_band (rhbz#2154545) (gsbz#706227)
* Sat Dec 17 2022 Michael J Gruber <mjg@fedoraproject.org> - 1.21.1-2
- SPDX migration
* Tue Dec 13 2022 Michael J Gruber <mjg@fedoraproject.org> - 1.21.1-1
- rebase to 1.21.1 (rhbz#2152708)
* Fri Nov 11 2022 Michael J Gruber <mjg@fedoraproject.org> - 1.21.0-1
- rebase to 1.21.0 (rhbz#2140776)
* Thu Oct 27 2022 Michael J Gruber <mjg@fedoraproject.org> - 1.21.0~rc1-1
- rebase to 1.21.0-rc1
* Fri Aug 12 2022 Michael J Gruber <mjg@fedoraproject.org> - 1.20.3-1
- rebase to 1.20.3 (bz #2104499)
* Fri Jul 22 2022 Fedora Release Engineering <releng@fedoraproject.org> - 1.20.0-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
* Fri Jul 08 2022 Sandro Mani <manisandro@gmail.com> - 1.20.0-2
- Rebuild (tesseract)
* Wed Jun 15 2022 Michael J Gruber <mjg@fedoraproject.org> - 1.20.0-1
- rebase to 1.20.0 (bz #2094792)
* Wed Jun 15 2022 Michael J Gruber <mjg@fedoraproject.org> - 1.20.0~rc2-1
- rebase to 1.20.0-rc2
* Wed Jun 15 2022 Michael J Gruber <mjg@fedoraproject.org> - 1.20.0~rc1-1
- rebase to 1.20.0-rc1
* Fri May 20 2022 Sandro Mani <manisandro@gmail.com> - 1.19.0-9
- Rebuild for gdal-3.5.0 and/or openjpeg-2.5.0
* Wed Mar 09 2022 Sandro Mani <manisandro@gmail.com> - 1.19.0-8
- Rebuild for tesseract-5.1.0
* Fri Feb 25 2022 Sandro Mani <manisandro@gmail.com> - 1.19.0-7
- Bump as F36 needs another rebuild
* Fri Feb 25 2022 Sandro Mani <manisandro@gmail.com> - 1.19.0-6
- Rebuild (leptonica)
* Thu Jan 20 2022 Fedora Release Engineering <releng@fedoraproject.org> - 1.19.0-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
* Sun Dec 19 2021 Sandro Mani <manisandro@gmail.com> - 1.19.0-4
- Rebuild (tesseract)
* Tue Dec 14 2021 Sandro Mani <manisandro@gmail.com> - 1.19.0-3
- Rebuild (tesseract)
* Tue Oct 12 2021 Michael J Gruber <mjg@fedoraproject.org> - 1.19.0-2
- enable OCR (leptonica/tesseract)
* Wed Oct 06 2021 Michael J Gruber <mjg@fedoraproject.org> - 1.19.0-1
- rebase to 1.19.0
* Tue Sep 14 2021 Sahana Prasad <sahana@redhat.com> - 1.18.0-9
- Rebuilt with OpenSSL 3.0.0
@ -267,3 +465,4 @@
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild

@ -1,121 +0,0 @@
# Desired jbig2dec header files and library version
# Apparantly, jbig2dec complains even about newer versions.
# Please update if needed.
%global jbig2dec_version 0.19
Name: mupdf
Version: 1.21.1
# upstream prerelease versions tags need to be translated to Fedorian
%global upversion %{version}
Release: %autorelease
Summary: A lightweight PDF viewer and toolkit
License: AGPL-3.0-or-later
URL: http://mupdf.com/
Source0: http://mupdf.com/downloads/archive/%{name}-%{upversion}-source.tar.gz
Source1: %{name}.desktop
Source2: %{name}-gl.desktop
Patch: mupdf-1.21.1-fix-png_write_band.patch
Patch: 0001-Bug-707996-Declare-variable-fz_var-to-avoid-stale-va.patch
BuildRequires: gcc gcc-c++ make binutils desktop-file-utils coreutils pkgconfig
BuildRequires: openjpeg2-devel desktop-file-utils
BuildRequires: libjpeg-devel freetype-devel libXext-devel curl-devel
BuildRequires: harfbuzz-devel openssl-devel mesa-libEGL-devel
BuildRequires: mesa-libGL-devel mesa-libGLU-devel libXi-devel libXrandr-devel
BuildRequires: gumbo-parser-devel leptonica-devel tesseract-devel
BuildRequires: jbig2dec-devel = %{jbig2dec_version}
BuildRequires: jbig2dec-libs = %{jbig2dec_version}
Requires: jbig2dec-libs = %{jbig2dec_version}
# We need to build against the Artifex fork of lcms2 so that we are thread safe
# (see bug #1553915). Artifex make sure to rebase against upstream, who refuse
# to integrate Artifex's changes.
Provides: bundled(lcms2-devel) = 2.14~rc1^59-g88b6a72
# We need to build against the Artifex fork of freeglut so that we are unicode safe.
Provides: bundled(freeglut-devel) = 3.0.0^11.g13ae6aa
# muPDF needs the muJS sources for the build even if we build against the system
# version so bundling them is the safer choice.
Provides: bundled(mujs-devel) = 1.3.2
# muPDF builds only against in-tree extract which is versioned along with ghostpdl.
Provides: bundled(extract) = 9.56.0^53-gc18d9f3
%description
MuPDF is a lightweight PDF viewer and toolkit written in portable C.
The renderer in MuPDF is tailored for high quality anti-aliased
graphics. MuPDF renders text with metrics and spacing accurate to
within fractions of a pixel for the highest fidelity in reproducing
the look of a printed page on screen.
MuPDF has a small footprint. A binary that includes the standard
Roman fonts is only one megabyte. A build with full CJK support
(including an Asian font) is approximately seven megabytes.
MuPDF has support for all non-interactive PDF 1.7 features, and the
toolkit provides a simple API for accessing the internal structures of
the PDF document. Example code for navigating interactive links and
bookmarks, encrypting PDF files, extracting fonts, images, and
searchable text, and rendering pages to image files is provided.
%package devel
Summary: Development files for %{name}
Requires: %{name} = %{version}-%{release}
Provides: %{name}-static = %{version}-%{release}
%description devel
The mupdf-devel package contains header files for developing
applications that use mupdf and static libraries
%prep
%autosetup -p1 -n %{name}-%{upversion}-source
for d in $(ls thirdparty | grep -v -e extract -e freeglut -e lcms2 -e mujs)
do
rm -rf thirdparty/$d
done
echo > user.make "\
USE_SYSTEM_FREETYPE := yes
USE_SYSTEM_HARFBUZZ := yes
USE_SYSTEM_JBIG2DEC := yes
USE_SYSTEM_JPEGXR := yes # not used without HAVE_JPEGXR
USE_SYSTEM_LCMS2 := no # need lcms2-art fork
USE_SYSTEM_LIBJPEG := yes
USE_SYSTEM_MUJS := no # build needs source anyways
USE_SYSTEM_OPENJPEG := yes
USE_SYSTEM_ZLIB := yes
USE_SYSTEM_GLUT := no # need freeglut2-art fork
USE_SYSTEM_CURL := yes
USE_SYSTEM_GUMBO := yes
USE_TESSERACT := yes
USE_SYSTEM_LEPTONICA := yes
USE_SYSTEM_TESSERACT := yes
"
%build
export XCFLAGS="%{optflags} -fPIC -DJBIG_NO_MEMENTO -DTOFU -DTOFU_CJK_EXT"
make %{?_smp_mflags} build=debug verbose=yes
%install
make DESTDIR=%{buildroot} install prefix=%{_prefix} libdir=%{_libdir} build=debug verbose=yes
## handle docs on our own
rm -rf %{buildroot}/%{_docdir}
desktop-file-install --dir=%{buildroot}%{_datadir}/applications %{SOURCE1}
desktop-file-install --dir=%{buildroot}%{_datadir}/applications %{SOURCE2}
mkdir -p %{buildroot}%{_datadir}/icons/hicolor/scalable/apps
install -p -m644 docs/logo/mupdf-logo.svg %{buildroot}%{_datadir}/icons/hicolor/scalable/apps/mupdf.svg
install -p -m644 docs/logo/mupdf-logo.svg %{buildroot}%{_datadir}/icons/hicolor/scalable/apps/mupdf-gl.svg
## fix strange permissons
chmod 0644 %{buildroot}%{_libdir}/*.a
find %{buildroot}/%{_mandir} -type f -exec chmod 0644 {} \;
find %{buildroot}/%{_includedir} -type f -exec chmod 0644 {} \;
cd %{buildroot}/%{_bindir} && ln -s %{name}-x11 %{name}
%files
%license COPYING
%doc README CHANGES docs/*
%{_bindir}/*
%{_datadir}/applications/mupdf*.desktop
%{_datadir}/icons/hicolor/*/apps/*
%{_mandir}/man1/*.1.gz
%files devel
%{_includedir}/%{name}
%{_libdir}/lib%{name}*.a
%changelog
%autochangelog

@ -1 +0,0 @@
SHA512 (mupdf-1.21.1-source.tar.gz) = 11eeea409e0b44d3f754a44b00b15522c2ae2d94171b8c7067efa7acbb1d597eefe1e27607fab90a56bf6c73579bbfb77b7599080fc2504a5881aaf7cc1957c7
Loading…
Cancel
Save