apache-pdfbox/apache-pdfbox.spec

114 lines
3.9 KiB
RPMSpec
Raw Normal View History

#
# spec file for package apache-pdfbox
#
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
# Only fontbox and jempbox are built as pdfbox itself depends on Adobe's pcif.
Name: apache-pdfbox
Version: 1.8.16
Release: 0
Summary: Java PDF Library
License: Apache-2.0
Group: Development/Libraries/Java
Url: https://pdfbox.apache.org/
Source0: http://www-us.apache.org/dist/pdfbox/%{version}/pdfbox-%{version}-src.zip
Source1: http://central.maven.org/maven2/org/apache/pdfbox/pdfbox/%{version}/pdfbox-%{version}.pom
Source2: http://central.maven.org/maven2/org/apache/pdfbox/fontbox/%{version}/fontbox-%{version}.pom
Source3: http://central.maven.org/maven2/org/apache/pdfbox/jempbox/%{version}/jempbox-%{version}.pom
Patch0: pdfbox-1.8.12-bouncycastle.patch
Patch1: disable-downloads.patch
Patch2: fix-javadoc-dep.patch
Patch3: pdfbox-1.8.12-sourcetarget.patch
Accepting request 620188 from home:favogt:branches:Java:packages - Update to 1.8.15: * [PDFBOX-4197] - PDStructureElement.getAttributes() ignores reference objects (CVE-2018-8036,bsc#1099721) - Update to 1.8.14: * [PDFBOX-3625] - Use correct file encoding when saving fdf data * [PDFBOX-3724] - Wrong size in rendering of some artifacts * [PDFBOX-3733] - image added to pdf by tool AddImageToPDF is turn-overed * [PDFBOX-3739] - ImageWriterIterator.next() and ImageReaderIterator.next() can return null * [PDFBOX-3742] - Unknown dir object c='>' cInt=62 peek='>' peekInt=62 * [PDFBOX-3813] - PDF Box crash when using PDFToImage or PDFDebug * [PDFBOX-3843] - Rect of Annotation contains indirect elements + Patch * [PDFBOX-3889] - javax.crypto.BadPaddingException: Given final block not properly padded * [PDFBOX-3909] - End of inline image not detected * [PDFBOX-3919] - Infinite loop while parsing (2) * [PDFBOX-3933] - PDFParser swallows a CR at the end of a stream * [PDFBOX-3942] - ClassCastException in getOptionalContentGroups * [PDFBOX-4005] - Incorrect use of PDNumberTreeNode in PDPageLabels * [PDFBOX-4011] - BBox in signature forms has wrong order * [PDFBOX-4027] - IndexOutOfBoundsException when XObject form matrix has only 5 elements * [PDFBOX-4030] - ClassCastException when matrix array has indirect objects * [PDFBOX-4064] - cm operator has 7 numbers * [PDFBOX-4083] - Line annotation /LL, /LLE and /LLO have wrong default values * [PDFBOX-4088] - Root/StructTreeRoot/K/S must be name, not string (merge) * [PDFBOX-3635] - Remove workaround to avoid SSLHandshakeException * [PDFBOX-4142] - Don't use md5 checksum due to changes to the release distribuition policy - Update to 1.8.13: * [PDFBOX-2420] - DateConverter doesn't handle time zones outside -12 to +12 range properly * [PDFBOX-2919] - org.apache.fontbox.cff.CFFParser.readEntry sometimes throws java.lang.IllegalArgumentException * [PDFBOX-3315] - Dates falsely detected as different by preflight * [PDFBOX-3335] - Issue while Merging PDF with Hidden Layers * [PDFBOX-3341] - currentAccessPermission.setReadOnly() not set in StandardSecurityHandler * [PDFBOX-3355] - PDPageLabels.getLabelsByPageIndices() returns Uppercase letters for style a * [PDFBOX-3368] - ContainsKey don't work for the Map<String, Object> returned by PDStructureTreeRoot.getRoleMap * [PDFBOX-3369] - Error expected floating point number actual='0.00-35095424' * [PDFBOX-3409] - TextToPDF drops leading spaces * [PDFBOX-3420] - Can't sign pdf with a particular attachment * [PDFBOX-3446] - Infinite loop while parsing * [PDFBOX-3448] - NullPointerException at org.apache.pdfbox.pdmodel.common.COSArrayList.convertFloatCOSArrayToList * [PDFBOX-3450] - ArrayIndexOutOfBoundsException at org.apache.fontbox.cmap.CMapParser.increment * [PDFBOX-3463] - XMPSchemaBasic.getLabel() always returns null * [PDFBOX-3466] - Java 9 warnings * [PDFBOX-3472] - NPE when PDF/A identification metadata does not contain ID * [PDFBOX-3477] - CA and ca values should be clipped * [PDFBOX-3481] - Localization in XRef generation results in unusable PDFs * [PDFBOX-3487] - ClassCastException in COSWriter.write() when saving PDF * [PDFBOX-3491] - NumberFormatException in CFFParser.readRealNumber * [PDFBOX-3500] - Error expected floating point number actual='0.-262' * [PDFBOX-3532] - Java 6 errors * [PDFBOX-3546] - IOException over DataFormatException, "invalid stored block lengths" on a valid PDF * [PDFBOX-3551] - CLI Decrypt broken, only allows 1 argument * [PDFBOX-3555] - FlateFilter.decode cause native memory leaks * [PDFBOX-3558] - NPE in JBig2Filter if BitsPerComponent is missing * [PDFBOX-3570] - JDK-8054565 Java 8 close contract issue * [PDFBOX-3571] - sRGB Color Space Profile is subject to 3rd party copyright * [PDFBOX-3578] - java.lang.IllegalArgumentException: dash lengths all zero * [PDFBOX-3590] - AccessPermission not applied * [PDFBOX-3594] - Use PDOutlineItem#findDestinationPage() cannot get PDPage, return was null * [PDFBOX-3609] - ClassCastException in PDCIDFont.readWidths() * [PDFBOX-3410] - TextToPDF needs orientation control * [PDFBOX-3352] - Calendar values are parsed with unknown timezones - Refresh pdfbox-1.8.12-bouncycastle.patch - Add patch to fix the version number: * fix-version.patch - Use %license OBS-URL: https://build.opensuse.org/request/show/620188 OBS-URL: https://build.opensuse.org/package/show/Java:packages/apache-pdfbox?expand=0&rev=17
2018-07-02 11:32:27 +02:00
Patch4: fix-version.patch
BuildRequires: ant
BuildRequires: apache-commons-logging
BuildRequires: bouncycastle
BuildRequires: fdupes
BuildRequires: icu4j
BuildRequires: java-devel >= 1.8
BuildRequires: javapackages-local
BuildRequires: javapackages-tools
BuildRequires: junit
BuildRequires: unzip
Requires: apache-commons-logging
Requires: icu4j
BuildArch: noarch
%description
The Apache PDFBox library is an open source Java tool for working with PDF documents.
This project allows creation of new PDF documents, manipulation of existing documents
and the ability to extract content from documents.
Apache PDFBox also includes several command line utilities.
%package javadoc
Summary: API Documentation for PDFBox
Group: Documentation/HTML
Requires: %{name} = %{version}-%{release}
%description javadoc
JavaDoc documentation for %{name}
%prep
%setup -q -n pdfbox-%{version}
Accepting request 620188 from home:favogt:branches:Java:packages - Update to 1.8.15: * [PDFBOX-4197] - PDStructureElement.getAttributes() ignores reference objects (CVE-2018-8036,bsc#1099721) - Update to 1.8.14: * [PDFBOX-3625] - Use correct file encoding when saving fdf data * [PDFBOX-3724] - Wrong size in rendering of some artifacts * [PDFBOX-3733] - image added to pdf by tool AddImageToPDF is turn-overed * [PDFBOX-3739] - ImageWriterIterator.next() and ImageReaderIterator.next() can return null * [PDFBOX-3742] - Unknown dir object c='>' cInt=62 peek='>' peekInt=62 * [PDFBOX-3813] - PDF Box crash when using PDFToImage or PDFDebug * [PDFBOX-3843] - Rect of Annotation contains indirect elements + Patch * [PDFBOX-3889] - javax.crypto.BadPaddingException: Given final block not properly padded * [PDFBOX-3909] - End of inline image not detected * [PDFBOX-3919] - Infinite loop while parsing (2) * [PDFBOX-3933] - PDFParser swallows a CR at the end of a stream * [PDFBOX-3942] - ClassCastException in getOptionalContentGroups * [PDFBOX-4005] - Incorrect use of PDNumberTreeNode in PDPageLabels * [PDFBOX-4011] - BBox in signature forms has wrong order * [PDFBOX-4027] - IndexOutOfBoundsException when XObject form matrix has only 5 elements * [PDFBOX-4030] - ClassCastException when matrix array has indirect objects * [PDFBOX-4064] - cm operator has 7 numbers * [PDFBOX-4083] - Line annotation /LL, /LLE and /LLO have wrong default values * [PDFBOX-4088] - Root/StructTreeRoot/K/S must be name, not string (merge) * [PDFBOX-3635] - Remove workaround to avoid SSLHandshakeException * [PDFBOX-4142] - Don't use md5 checksum due to changes to the release distribuition policy - Update to 1.8.13: * [PDFBOX-2420] - DateConverter doesn't handle time zones outside -12 to +12 range properly * [PDFBOX-2919] - org.apache.fontbox.cff.CFFParser.readEntry sometimes throws java.lang.IllegalArgumentException * [PDFBOX-3315] - Dates falsely detected as different by preflight * [PDFBOX-3335] - Issue while Merging PDF with Hidden Layers * [PDFBOX-3341] - currentAccessPermission.setReadOnly() not set in StandardSecurityHandler * [PDFBOX-3355] - PDPageLabels.getLabelsByPageIndices() returns Uppercase letters for style a * [PDFBOX-3368] - ContainsKey don't work for the Map<String, Object> returned by PDStructureTreeRoot.getRoleMap * [PDFBOX-3369] - Error expected floating point number actual='0.00-35095424' * [PDFBOX-3409] - TextToPDF drops leading spaces * [PDFBOX-3420] - Can't sign pdf with a particular attachment * [PDFBOX-3446] - Infinite loop while parsing * [PDFBOX-3448] - NullPointerException at org.apache.pdfbox.pdmodel.common.COSArrayList.convertFloatCOSArrayToList * [PDFBOX-3450] - ArrayIndexOutOfBoundsException at org.apache.fontbox.cmap.CMapParser.increment * [PDFBOX-3463] - XMPSchemaBasic.getLabel() always returns null * [PDFBOX-3466] - Java 9 warnings * [PDFBOX-3472] - NPE when PDF/A identification metadata does not contain ID * [PDFBOX-3477] - CA and ca values should be clipped * [PDFBOX-3481] - Localization in XRef generation results in unusable PDFs * [PDFBOX-3487] - ClassCastException in COSWriter.write() when saving PDF * [PDFBOX-3491] - NumberFormatException in CFFParser.readRealNumber * [PDFBOX-3500] - Error expected floating point number actual='0.-262' * [PDFBOX-3532] - Java 6 errors * [PDFBOX-3546] - IOException over DataFormatException, "invalid stored block lengths" on a valid PDF * [PDFBOX-3551] - CLI Decrypt broken, only allows 1 argument * [PDFBOX-3555] - FlateFilter.decode cause native memory leaks * [PDFBOX-3558] - NPE in JBig2Filter if BitsPerComponent is missing * [PDFBOX-3570] - JDK-8054565 Java 8 close contract issue * [PDFBOX-3571] - sRGB Color Space Profile is subject to 3rd party copyright * [PDFBOX-3578] - java.lang.IllegalArgumentException: dash lengths all zero * [PDFBOX-3590] - AccessPermission not applied * [PDFBOX-3594] - Use PDOutlineItem#findDestinationPage() cannot get PDPage, return was null * [PDFBOX-3609] - ClassCastException in PDCIDFont.readWidths() * [PDFBOX-3410] - TextToPDF needs orientation control * [PDFBOX-3352] - Calendar values are parsed with unknown timezones - Refresh pdfbox-1.8.12-bouncycastle.patch - Add patch to fix the version number: * fix-version.patch - Use %license OBS-URL: https://build.opensuse.org/request/show/620188 OBS-URL: https://build.opensuse.org/package/show/Java:packages/apache-pdfbox?expand=0&rev=17
2018-07-02 11:32:27 +02:00
%autopatch -p1
%build
# Build
ant -buildfile pdfbox/build.xml \
-Dbcprov.jar=$(build-classpath bcprov) -Djunit.jar=$(build-classpath junit4) \
-Dicu4j.jar=$(build-classpath icu4j) -Dlogging.jar=$(build-classpath commons-logging) \
-Dbuild.sysclasspath=first -Dcompile.source=8 -Dcompile.target=8 \
fontbox.package jempbox.package javadoc
%install
# Code
install -d %{buildroot}%{_javadir}
for jar in fontbox jempbox; do
install -p -m644 ${jar}/target/${jar}-%{version}.jar %{buildroot}%{_javadir}/${jar}.jar
done
install -d -m 0755 %{buildroot}/%{_mavenpomdir}/
install -m 0644 %{SOURCE2} %{buildroot}/%{_mavenpomdir}/JPP-fontbox.pom
install -m 0644 %{SOURCE3} %{buildroot}/%{_mavenpomdir}/JPP-jempbox.pom
%add_maven_depmap JPP-fontbox.pom fontbox.jar
%add_maven_depmap JPP-jempbox.pom jempbox.jar
# JavaDoc
install -dm 755 %{buildroot}%{_javadocdir}/%{name}-%{version}
cp -pr pdfbox/target/javadoc/* %{buildroot}%{_javadocdir}/%{name}-%{version}
%fdupes %{buildroot}%{_javadocdir}/%{name}-%{version}
ln -s %{name}-%{version} %{buildroot}%{_javadocdir}/%{name}
%files javadoc
%{_javadocdir}/%{name}-%{version}
%{_javadocdir}/%{name}
%files
Accepting request 620188 from home:favogt:branches:Java:packages - Update to 1.8.15: * [PDFBOX-4197] - PDStructureElement.getAttributes() ignores reference objects (CVE-2018-8036,bsc#1099721) - Update to 1.8.14: * [PDFBOX-3625] - Use correct file encoding when saving fdf data * [PDFBOX-3724] - Wrong size in rendering of some artifacts * [PDFBOX-3733] - image added to pdf by tool AddImageToPDF is turn-overed * [PDFBOX-3739] - ImageWriterIterator.next() and ImageReaderIterator.next() can return null * [PDFBOX-3742] - Unknown dir object c='>' cInt=62 peek='>' peekInt=62 * [PDFBOX-3813] - PDF Box crash when using PDFToImage or PDFDebug * [PDFBOX-3843] - Rect of Annotation contains indirect elements + Patch * [PDFBOX-3889] - javax.crypto.BadPaddingException: Given final block not properly padded * [PDFBOX-3909] - End of inline image not detected * [PDFBOX-3919] - Infinite loop while parsing (2) * [PDFBOX-3933] - PDFParser swallows a CR at the end of a stream * [PDFBOX-3942] - ClassCastException in getOptionalContentGroups * [PDFBOX-4005] - Incorrect use of PDNumberTreeNode in PDPageLabels * [PDFBOX-4011] - BBox in signature forms has wrong order * [PDFBOX-4027] - IndexOutOfBoundsException when XObject form matrix has only 5 elements * [PDFBOX-4030] - ClassCastException when matrix array has indirect objects * [PDFBOX-4064] - cm operator has 7 numbers * [PDFBOX-4083] - Line annotation /LL, /LLE and /LLO have wrong default values * [PDFBOX-4088] - Root/StructTreeRoot/K/S must be name, not string (merge) * [PDFBOX-3635] - Remove workaround to avoid SSLHandshakeException * [PDFBOX-4142] - Don't use md5 checksum due to changes to the release distribuition policy - Update to 1.8.13: * [PDFBOX-2420] - DateConverter doesn't handle time zones outside -12 to +12 range properly * [PDFBOX-2919] - org.apache.fontbox.cff.CFFParser.readEntry sometimes throws java.lang.IllegalArgumentException * [PDFBOX-3315] - Dates falsely detected as different by preflight * [PDFBOX-3335] - Issue while Merging PDF with Hidden Layers * [PDFBOX-3341] - currentAccessPermission.setReadOnly() not set in StandardSecurityHandler * [PDFBOX-3355] - PDPageLabels.getLabelsByPageIndices() returns Uppercase letters for style a * [PDFBOX-3368] - ContainsKey don't work for the Map<String, Object> returned by PDStructureTreeRoot.getRoleMap * [PDFBOX-3369] - Error expected floating point number actual='0.00-35095424' * [PDFBOX-3409] - TextToPDF drops leading spaces * [PDFBOX-3420] - Can't sign pdf with a particular attachment * [PDFBOX-3446] - Infinite loop while parsing * [PDFBOX-3448] - NullPointerException at org.apache.pdfbox.pdmodel.common.COSArrayList.convertFloatCOSArrayToList * [PDFBOX-3450] - ArrayIndexOutOfBoundsException at org.apache.fontbox.cmap.CMapParser.increment * [PDFBOX-3463] - XMPSchemaBasic.getLabel() always returns null * [PDFBOX-3466] - Java 9 warnings * [PDFBOX-3472] - NPE when PDF/A identification metadata does not contain ID * [PDFBOX-3477] - CA and ca values should be clipped * [PDFBOX-3481] - Localization in XRef generation results in unusable PDFs * [PDFBOX-3487] - ClassCastException in COSWriter.write() when saving PDF * [PDFBOX-3491] - NumberFormatException in CFFParser.readRealNumber * [PDFBOX-3500] - Error expected floating point number actual='0.-262' * [PDFBOX-3532] - Java 6 errors * [PDFBOX-3546] - IOException over DataFormatException, "invalid stored block lengths" on a valid PDF * [PDFBOX-3551] - CLI Decrypt broken, only allows 1 argument * [PDFBOX-3555] - FlateFilter.decode cause native memory leaks * [PDFBOX-3558] - NPE in JBig2Filter if BitsPerComponent is missing * [PDFBOX-3570] - JDK-8054565 Java 8 close contract issue * [PDFBOX-3571] - sRGB Color Space Profile is subject to 3rd party copyright * [PDFBOX-3578] - java.lang.IllegalArgumentException: dash lengths all zero * [PDFBOX-3590] - AccessPermission not applied * [PDFBOX-3594] - Use PDOutlineItem#findDestinationPage() cannot get PDPage, return was null * [PDFBOX-3609] - ClassCastException in PDCIDFont.readWidths() * [PDFBOX-3410] - TextToPDF needs orientation control * [PDFBOX-3352] - Calendar values are parsed with unknown timezones - Refresh pdfbox-1.8.12-bouncycastle.patch - Add patch to fix the version number: * fix-version.patch - Use %license OBS-URL: https://build.opensuse.org/request/show/620188 OBS-URL: https://build.opensuse.org/package/show/Java:packages/apache-pdfbox?expand=0&rev=17
2018-07-02 11:32:27 +02:00
%doc RELEASE-NOTES.txt NOTICE.txt README.txt
%license LICENSE.txt
%{_javadir}/fontbox.jar
%{_javadir}/jempbox.jar
%{_mavenpomdir}/JPP-fontbox.pom
%{_mavenpomdir}/JPP-jempbox.pom
%if %{defined _maven_repository}
%{_mavendepmapfragdir}/%{name}
%else
%{_datadir}/maven-metadata/%{name}.xml*
%endif
%changelog