Sophie

Sophie

distrib > Mageia > 6 > armv7hl > by-pkgid > 468e470609f4f29c48d36cab23e5db85 > files > 7

apache-poi-3.14-1.mga6.src.rpm

%global reldate %{nil}
%global rcver %{nil}

Name:          apache-poi
Version:       3.14
Release:       %mkrel 1
Group:         Development/Java
Summary:       The Java API for Microsoft Documents
# ASLv2 + GPLv3 src/resources/scratchpad/org/apache/poi/hdgf/chunks_parse_cmds.tbl
# https://bugzilla.redhat.com/show_bug.cgi?id=1146670#c13
License:       ASL 2.0 and (CC-BY and CC-BY-SA and W3C) and GPLv3
URL:           http://poi.apache.org/
Source0:       http://www.apache.org/dist/poi/release/src/poi-src-%{version}%{reldate}.tar.gz 
#Source0:       http://www.apache.org/dist/poi/dev/src/poi-src-%%{version}%%{?rcver}-%%{reldate}.tar.gz
# Creative Commons license 4.0 (Attribution-ShareAlike)
Source1:       http://www.ecma-international.org/publications/files/ECMA-ST/Office-Open-XML-1st-edition-Part-4.zip
Source2:       http://www.ecma-international.org/publications/files/ECMA-ST/Office-Open-XML-1st-edition-Part-2.zip
# Creative Commons Attribution 3.0 License
Source3:       http://dublincore.org/schemas/xmls/qdc/2003/04/02/dc.xsd
Source4:       http://dublincore.org/schemas/xmls/qdc/2003/04/02/dcterms.xsd
Source5:       http://dublincore.org/schemas/xmls/qdc/2003/04/02/dcmitype.xsd
# W3C
Source6:       http://www.w3.org/TR/2002/REC-xmldsig-core-20020212/xmldsig-core-schema.xsd
# http://www.etsi.org/index.php/terms-of-use
# see https://bz.apache.org/bugzilla/show_bug.cgi?id=57862
Source7:       http://uri.etsi.org/01903/v1.3.2/XAdES.xsd
Source8:       http://uri.etsi.org/01903/v1.4.1/XAdESv141.xsd

Source9:       http://repo2.maven.org/maven2/org/apache/poi/poi/%{version}/poi-%{version}.pom
Source10:      http://repo2.maven.org/maven2/org/apache/poi/poi-examples/%{version}/poi-examples-%{version}.pom
Source11:      http://repo2.maven.org/maven2/org/apache/poi/poi-excelant/%{version}/poi-excelant-%{version}.pom
Source12:      http://repo2.maven.org/maven2/org/apache/poi/poi-ooxml/%{version}/poi-ooxml-%{version}.pom
Source13:      http://repo2.maven.org/maven2/org/apache/poi/poi-ooxml-schemas/%{version}/poi-ooxml-schemas-%{version}.pom
Source14:      http://repo2.maven.org/maven2/org/apache/poi/poi-scratchpad/%{version}/poi-scratchpad-%{version}.pom

#Force compile of xsds if disconnected
Patch1:        apache-poi-3.14-compile-xsds.patch
Patch2:        apache-poi-build.patch

BuildArch:     noarch

BuildRequires: jacoco
BuildRequires: javapackages-local
BuildRequires: mvn(com.github.virtuald:curvesapi)
BuildRequires: mvn(commons-codec:commons-codec)
BuildRequires: mvn(commons-logging:commons-logging)
BuildRequires: mvn(dom4j:dom4j)
BuildRequires: mvn(junit:junit)
BuildRequires: mvn(log4j:log4j:1.2.17)
BuildRequires: mvn(org.apache.ant:ant-junit)
BuildRequires: mvn(org.apache.santuario:xmlsec) >= 2.0.1
BuildRequires: mvn(org.apache.xmlbeans:xmlbeans)
BuildRequires: mvn(org.bouncycastle:bcpkix-jdk15on)
BuildRequires: mvn(org.bouncycastle:bcprov-jdk15on)
BuildRequires: mvn(org.hamcrest:hamcrest-core)
BuildRequires: mvn(org.ow2.asm:asm-all)
BuildRequires: mvn(org.slf4j:slf4j-api)
BuildRequires: mvn(rhino:js)

#Fonts for testing
BuildRequires: fontconfig fonts-ttf-liberation 

Obsoletes:     %{name}-manual <= %{version}-%{release}

%description
The Apache POI Project's mission is to create and maintain Java APIs for
manipulating various file formats based upon the Office Open XML standards
(OOXML) and Microsoft's OLE 2 Compound Document format (OLE2). In short, you
can read and write MS Excel files using Java. In addition, you can read and
write MS Word and MS PowerPoint files using Java. Apache POI is your Java
Excel solution (for Excel 97-2008). We have a complete API for porting other
OOXML and OLE2 formats and welcome others to participate.

OLE2 files include most Microsoft Office files such as XLS, DOC, and PPT as
well as MFC serialization API based file formats. The project provides APIs
for the OLE2 Filesystem (POIFS) and OLE2 Document Properties (HPSF).

Office OpenXML Format is the new standards based XML file format found in
Microsoft Office 2007 and 2008. This includes XLSX, DOCX and PPTX. The
project provides a low level API to support the Open Packaging Conventions
using openxml4j.

For each MS Office application there exists a component module that attempts
to provide a common high level Java API to both OLE2 and OOXML document
formats. This is most developed for Excel workbooks (SS=HSSF+XSSF). Work is
progressing for Word documents (HWPF+XWPF) and PowerPoint presentations
(HSLF+XSLF).

The project has recently added support for Outlook (HSMF). Microsoft opened
the specifications to this format in October 2007. We would welcome
contributions.

There are also projects for Visio (HDGF) and Publisher (HPBF). 

%package javadoc
Summary:        Javadoc for %{name}

%description javadoc
This package contains the API documentation for %{name}.

%prep
%setup -q -n poi-%{version}%{?rcver}
%patch1 -p1 -b .compile-xsds
%patch2 -p1 -b .build

# Disable java8doc doclint
sed -i 's|additionalparam="-notimestamp"|additionalparam="-notimestamp -Xdoclint:none"|' build.xml

find -name '*.class' -delete
find -name '*.jar' -delete

mkdir lib ooxml-lib
build-jar-repository -s -p lib ant commons-codec commons-logging jacoco hamcrest/core junit bcprov bcpkix objectweb-asm/asm-all xmlsec slf4j/slf4j-api
ln -sf $(build-classpath log4j-1.2.17) lib/log4j.jar
build-jar-repository -s -p ooxml-lib dom4j xmlbeans/xbean curvesapi
#Unpack the XMLSchema
pushd ooxml-lib
unzip "%SOURCE1" OfficeOpenXML-XMLSchema.zip
unzip "%SOURCE2" OpenPackagingConventions-XMLSchema.zip
cp -p %SOURCE3 .
cp -p %SOURCE4 .
cp -p %SOURCE5 .
cp -p %SOURCE6 .
cp -p %SOURCE7 .
cp -p %SOURCE8 .
popd

# Customize pom file
cp -p %SOURCE11 .
%pom_xpath_inject "pom:dependencies/pom:dependency[pom:artifactId ='ant']" "
<scope>provided</scope>" poi-excelant-%{version}.pom

%mvn_file org.apache.poi:poi poi/%{name} poi/poi
for m in examples excelant ooxml ooxml-schemas scratchpad;do
%mvn_file org.apache.poi:poi-${m} poi/%{name}-${m} poi/poi-${m}
done

%build
cat > build.properties <<'EOF'
main.ant.jar=lib/ant.jar
main.commons-codec.jar=lib/commons-codec.jar
main.commons-logging.jar=lib/commons-logging.jar
main.log4j.jar=lib/log4j.jar
main.junit.jar=lib/junit.jar
main.hamcrest.jar=lib/hamcrest_core.jar
ooxml.dom4j.jar=ooxml-lib/dom4j.jar
ooxml.curvesapi.jar=ooxml-lib/curvesapi.jar
ooxml.xmlbeans23.jar=ooxml-lib/xmlbeans_xbean.jar
ooxml.xmlbeans26.jar=ooxml-lib/xmlbeans_xbean.jar
dsig.xmlsec.jar=lib/xmlsec.jar
dsig.bouncycastle-prov.jar=lib/bcprov.jar
dsig.bouncycastle-pkix.jar=lib/bcpkix.jar
dsig.sl4j-api.jar=lib/slf4j_slf4j-api.jar
asm.jar=lib/objectweb-asm_asm-all.jar
disconnected=1
DSTAMP=%{reldate}
EOF

export ANT_OPTS="-Xmx768m"
ant -propertyfile build.properties compile-ooxml-xsds jar javadocs

%install
%mvn_artifact $RPM_SOURCE_DIR/poi-%{version}.pom build/dist/poi-%{version}-%{reldate}.jar
%mvn_artifact poi-excelant-%{version}.pom build/dist/poi-excelant-%{version}-%{reldate}.jar
for m in examples ooxml ooxml-schemas scratchpad;do
%mvn_artifact $RPM_SOURCE_DIR/poi-${m}-%{version}.pom build/dist/poi-${m}-%{version}-%{reldate}.jar
done

%mvn_install -J build/tmp/site/build/site/apidocs

%check
# To enable 8-bit character tests
export LANG=en_US.UTF-8
# Ignore test failures for now
ant -propertyfile build.properties test || :

%files -f .mfiles
%doc KEYS
%license LICENSE NOTICE
 
%files javadoc -f .mfiles-javadoc
%license LICENSE NOTICE



%changelog
* Wed May 03 2017 neoclust <neoclust> 3.14-1.mga6
+ Revision: 1098860
- New version 3.14 (mga#19029)

* Thu Feb 18 2016 neoclust <neoclust> 3.13-2.mga6
+ Revision: 966459
- imported package apache-poi

* Tue Feb 09 2016 umeabot <umeabot> 3.10.1-4.mga6
+ Revision: 952422
- Mageia 6 Mass Rebuild

* Wed Feb 25 2015 luigiwalser <luigiwalser> 3.10.1-3.mga5
+ Revision: 816960
- sync patch from fedora to fix CVE-2014-9527

* Fri Dec 26 2014 pterjan <pterjan> 3.10.1-2.mga5
+ Revision: 806286
- Clean rebuild
- Sync with Fedora 21 (update to 3.10.1)
- Restore

  + sander85 <sander85>
    - Unmaintained + unfixed security issues

  + umeabot <umeabot>
    - Second Mageia 5 Mass Rebuild
    - Mageia 5 Mass Rebuild

* Mon Oct 21 2013 umeabot <umeabot> 3.9-2.mga4
+ Revision: 538255
- Mageia 4 Mass Rebuild

* Sun Sep 29 2013 dmorgan <dmorgan> 3.9-1.mga4
+ Revision: 489094
- New version

* Mon Jan 14 2013 dmorgan <dmorgan> 3.8-4.mga3
+ Revision: 387673
- Rebuild with fixed xmlbeans
- Add P2: Fix CVE 2012-0213
- New version 3.8 Final

  + umeabot <umeabot>
    - Mass Rebuild - https://wiki.mageia.org/en/Feature:Mageia3MassRebuild

* Sun Aug 14 2011 dmorgan <dmorgan> 3.8-1.mga2
+ Revision: 133026
- Clean spec file

  + gil <gil>
    - imported package apache-poi


* Wed Feb 03 2016 Fedora Release Engineering <releng@fedoraproject.org> - 3.13-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild

* Sat Sep 26 2015 gil cattaneo <puntogil@libero.it> 3.13-1
- Update to 3.13

* Tue Sep 01 2015 gil cattaneo <puntogil@libero.it> 3.12-2
- build fix
- fix license field
- obsoletes manual sub-package

* Tue Jul  7 2015 Zbigniew Jędrzejewski-Szmek <zbyszek@laptop> - 3.12-1
- Update to latest version

* Wed Jun 17 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.10.1-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild

* Wed Feb 11 2015 gil cattaneo <puntogil@libero.it> 3.10.1-2
- fix for RHBZ#1138135 (CVE-2014-3574)
- introduce license macro

* Thu Sep 4 2014 Orion Poplawski <orion@cora.nwra.com> - 3.10.1-1
- Update to 3.10.1 (Bug 1138135: CVE-2014-3574 CVE-2014-3529)

* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.10-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild

* Mon Feb 24 2014 Orion Poplawski <orion@cora.nwra.com> - 3.10-1
- Update to 3.10

* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.9-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild

* Wed Jun 12 2013 Orion Poplawski <orion@cora.nwra.com> - 3.9-1
- Update to 3.9 final
- Install all jars and add poms for each
- Cleanup and update spec

* Fri Apr 05 2013 Karsten Hopp <karsten@redhat.com> 3.8-5
- drop excludearch ppc64

* Wed Feb 13 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.8-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild

* Wed Jul 18 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.8-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild

* Fri Jul 13 2012 Orion Poplawski <orion@cora.nwra.com> - 3.8-2
- Add patch to fix compilation with JDK 1.7

* Thu May 10 2012 Orion Poplawski <orion@cora.nwra.com> - 3.8-1
- Update to 3.8 final
- Add patch to fix CVE-2012-0213 (bugs 799078, 820788)

* Thu Jan 5 2012 Orion Poplawski <orion@cora.nwra.com> - 3.8-0.3.beta5
- Update to 3.8-beta5

* Fri Jul 22 2011 Orion Poplawski <orion@cora.nwra.com> - 3.8-0.2.beta3
- Update to 3.8-beta3
- Add commons-codec to the build jar repository

* Wed Apr 20 2011 Orion Poplawski <orion@cora.nwra.com> - 3.8-0.1.beta2
- Update to 3.8-beta2
- Add BR fontconfig needed for tests to find fonts
- Fix javadoc link

* Mon Feb 07 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.7-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild

* Tue Dec 21 2010 Orion Poplawski <orion@cora.nwra.com> - 3.7-4
- No java >= 1:1.6.0 on ppc64

* Tue Dec 21 2010 Alexander Kurtakov <akurtako@redhat.com> 3.7-3
- No poi-contrib.jar.

* Tue Dec 21 2010 Alexander Kurtakov <akurtako@redhat.com> 3.7-2
- Url encode the source.

* Mon Dec 6 2010 Orion Poplawski <orion@cora.nwra.com> - 3.7-1
- Update to 3.7 final

* Mon Nov 8 2010 Orion Poplawski <orion@cora.nwra.com> - 3.7-0.5.beta3
- Add pom

* Mon Nov 1 2010 Orion Poplawski <orion@cora.nwra.com> - 3.7-0.4.beta3
- Fix manual package

* Wed Oct 27 2010 Orion Poplawski <orion@cora.nwra.com> - 3.7-0.3.beta3
- Update to 3.7 beta3
- Add more Requires

* Wed Sep 1 2010 Orion Poplawski <orion@cora.nwra.com> - 3.7-0.2.beta2
- Update to 3.7 beta2

* Fri Jun 25 2010 Orion Poplawski <orion@cora.nwra.com> - 3.7-0.1.beta1
- Update to 3.7 beta1
- Rebase compile-xsds patch

* Fri Jun 25 2010 Orion Poplawski <orion@cora.nwra.com> - 3.6-1
- Initial Fedora package