Blame SPECS/log4j.spec

d8ea4d
d8ea4d
%global bootstrap %{?_with_bootstrap:1}%{!?_with_bootstrap:%{?_without_bootstrap:0}%{!?_without_bootstrap:%{?_bootstrap:%{_bootstrap}}%{!?_bootstrap:0}}}
d8ea4d
d8ea4d
Name:           log4j
d8ea4d
Version:        1.2.17
d8ea4d
Release:        16%{?dist}
d8ea4d
Epoch:          0
d8ea4d
Summary:        Java logging package
d8ea4d
BuildArch:      noarch
d8ea4d
License:        ASL 2.0
d8ea4d
URL:            http://logging.apache.org/%{name}
d8ea4d
Source0:        http://www.apache.org/dist/logging/%{name}/%{version}/%{name}-%{version}.tar.gz
d8ea4d
# Converted from src/java/org/apache/log4j/lf5/viewer/images/lf5_small_icon.gif
d8ea4d
Source102:      %{name}-logfactor5.sh
d8ea4d
Source104:      %{name}-logfactor5.1
d8ea4d
# Converted from docs/images/logo.jpg
d8ea4d
Source112:      %{name}-chainsaw.sh
d8ea4d
Source114:      %{name}-chainsaw.1
d8ea4d
Source200:      %{name}.catalog
d8ea4d
Patch0:         0001-logfactor5-changed-userdir.patch
d8ea4d
Patch1:         0006-Remove-mvn-clirr-plugin.patch
d8ea4d
Patch2:         0009-Fix-tests.patch
d8ea4d
Patch3:         0010-Fix-javadoc-link.patch
d8ea4d
Patch4:         0011-Remove-openejb.patch
d8ea4d
Patch5:         0012-Add-proper-bundle-symbolicname.patch
d8ea4d
Patch6:         0001-Backport-fix-for-CVE-2017-5645.patch
d8ea4d
d8ea4d
BuildRequires:  %{__perl}
d8ea4d
BuildRequires:  maven-local
d8ea4d
BuildRequires:  javamail
d8ea4d
BuildRequires:  junit
d8ea4d
BuildRequires:  geronimo-jms
d8ea4d
BuildRequires:  jakarta-oro
d8ea4d
BuildRequires:  ant-contrib
d8ea4d
BuildRequires:  ant-junit
d8ea4d
d8ea4d
%description
d8ea4d
Log4j is a tool to help the programmer output log statements to a
d8ea4d
variety of output targets.
d8ea4d
d8ea4d
%package        manual
d8ea4d
Summary:        Developer manual for %{name}
d8ea4d
Requires:       %{name}-javadoc = %{version}-%{release}
d8ea4d
d8ea4d
%description    manual
d8ea4d
%{summary}.
d8ea4d
d8ea4d
%package        javadoc
d8ea4d
Summary:        API documentation for %{name}
d8ea4d
d8ea4d
%description    javadoc
d8ea4d
%{summary}.
d8ea4d
d8ea4d
%prep
d8ea4d
%setup -q -n apache-%{name}-%{version}
d8ea4d
# see patch files themselves for reasons for applying
d8ea4d
%patch0 -p1 -b .logfactor-home
d8ea4d
%patch1 -p1 -b .remove-mvn-clirr
d8ea4d
%patch2 -p1 -b .fix-tests
d8ea4d
%patch3 -p1 -b .xlink-javadoc
d8ea4d
%patch4 -p1 -b .openejb
d8ea4d
%patch5 -p1 -b .bundlename
d8ea4d
%patch6 -p1 -b .cve-2017-5645
d8ea4d
%pom_remove_plugin :maven-site-plugin
d8ea4d
d8ea4d
sed -i "s|groupId>ant<|groupId>org.apache.ant<|g" pom.xml
d8ea4d
d8ea4d
sed -i 's/\r//g' LICENSE NOTICE site/css/*.css site/xref/*.css \
d8ea4d
    site/xref-test/*.css
d8ea4d
d8ea4d
# fix encoding of mailbox files
d8ea4d
for i in contribs/JimMoore/mail*;do
d8ea4d
    iconv --from=ISO-8859-1 --to=UTF-8 "$i" > new
d8ea4d
    mv new "$i"
d8ea4d
done
d8ea4d
d8ea4d
# remove all the stuff we'll build ourselves
d8ea4d
find -name "*.jar" -o -name "*.class" -delete
d8ea4d
rm -rf docs/api
d8ea4d
d8ea4d
# Needed by tests
d8ea4d
mkdir -p tests/lib/
d8ea4d
(cd tests/lib/
d8ea4d
  ln -s `build-classpath jakarta-oro`
d8ea4d
  ln -s `build-classpath javamail/mail`
d8ea4d
  ln -s `build-classpath junit`
d8ea4d
)
d8ea4d
d8ea4d
d8ea4d
%build
d8ea4d
%mvn_file : %{name}
d8ea4d
%mvn_build
d8ea4d
d8ea4d
%install
d8ea4d
%mvn_install
d8ea4d
d8ea4d
# scripts
d8ea4d
install -pD -T -m 755 %{SOURCE102} %{buildroot}%{_bindir}/logfactor5
d8ea4d
install -pD -T -m 755 %{SOURCE112} %{buildroot}%{_bindir}/chainsaw
d8ea4d
d8ea4d
# Manual pages
d8ea4d
install -d -m 755 ${RPM_BUILD_ROOT}%{_mandir}/man1
d8ea4d
install -p -m 644 %{SOURCE104} ${RPM_BUILD_ROOT}%{_mandir}/man1/logfactor5.1
d8ea4d
install -p -m 644 %{SOURCE114} ${RPM_BUILD_ROOT}%{_mandir}/man1/chainsaw.1
d8ea4d
d8ea4d
# DTD and the SGML catalog (XML catalog handled in scriptlets)
d8ea4d
install -pD -T -m 644 src/main/javadoc/org/apache/log4j/xml/doc-files/log4j.dtd \
d8ea4d
  %{buildroot}%{_datadir}/sgml/%{name}/log4j.dtd
d8ea4d
install -pD -T -m 644 %{SOURCE200} \
d8ea4d
  %{buildroot}%{_datadir}/sgml/%{name}/catalog
d8ea4d
d8ea4d
# fix perl location
d8ea4d
%__perl -p -i -e 's|/opt/perl5/bin/perl|%{__perl}|' \
d8ea4d
contribs/KitchingSimon/udpserver.pl
d8ea4d
d8ea4d
d8ea4d
%post
d8ea4d
# Note that we're using versioned catalog, so this is always ok.
d8ea4d
if [ -x %{_bindir}/install-catalog -a -d %{_sysconfdir}/sgml ]; then
d8ea4d
  %{_bindir}/install-catalog --add \
d8ea4d
    %{_sysconfdir}/sgml/%{name}-%{version}-%{release}.cat \
d8ea4d
    %{_datadir}/sgml/%{name}/catalog > /dev/null || :
d8ea4d
fi
d8ea4d
if [ -x %{_bindir}/xmlcatalog -a -w %{_sysconfdir}/xml/catalog ]; then
d8ea4d
  %{_bindir}/xmlcatalog --noout --add public "-//APACHE//DTD LOG4J 1.2//EN" \
d8ea4d
    file://%{_datadir}/sgml/%{name}/log4j.dtd %{_sysconfdir}/xml/catalog \
d8ea4d
    > /dev/null
d8ea4d
  %{_bindir}/xmlcatalog --noout --add system log4j.dtd \
d8ea4d
    file://%{_datadir}/sgml/%{name}/log4j.dtd %{_sysconfdir}/xml/catalog \
d8ea4d
    > /dev/null || :
d8ea4d
fi
d8ea4d
d8ea4d
d8ea4d
%preun
d8ea4d
if [ $1 -eq 0 ]; then
d8ea4d
  if [ -x %{_bindir}/xmlcatalog -a -w %{_sysconfdir}/xml/catalog ]; then
d8ea4d
    %{_bindir}/xmlcatalog --noout --del \
d8ea4d
      file://%{_datadir}/sgml/%{name}/log4j.dtd \
d8ea4d
      %{_sysconfdir}/xml/catalog > /dev/null || :
d8ea4d
  fi
d8ea4d
fi
d8ea4d
d8ea4d
d8ea4d
%postun
d8ea4d
# Note that we're using versioned catalog, so this is always ok.
d8ea4d
if [ -x %{_bindir}/install-catalog -a -d %{_sysconfdir}/sgml ]; then
d8ea4d
  %{_bindir}/install-catalog --remove \
d8ea4d
    %{_sysconfdir}/sgml/%{name}-%{version}-%{release}.cat \
d8ea4d
    %{_datadir}/sgml/%{name}/catalog > /dev/null || :
d8ea4d
fi
d8ea4d
d8ea4d
%files -f .mfiles
d8ea4d
%doc LICENSE NOTICE
d8ea4d
%{_bindir}/*
d8ea4d
%{_mandir}/*/*
d8ea4d
%{_datadir}/sgml/%{name}
d8ea4d
d8ea4d
%files manual
d8ea4d
%doc LICENSE NOTICE
d8ea4d
%doc site/*.html site/css site/images/ site/xref site/xref-test contribs
d8ea4d
d8ea4d
%files javadoc
d8ea4d
%doc LICENSE NOTICE
d8ea4d
%doc %{_javadocdir}/%{name}
d8ea4d
d8ea4d
d8ea4d
%changelog
d8ea4d
* Tue Jul 11 2017 Mikolaj Izdebski <mizdebsk@redhat.com> - 0:1.2.17-16
d8ea4d
- Fix socket receiver deserialization vulnerability
d8ea4d
- Resolves: CVE-2017-5645
d8ea4d
d8ea4d
* Fri Dec 27 2013 Daniel Mach <dmach@redhat.com> - 01.2.17-15
d8ea4d
- Mass rebuild 2013-12-27
d8ea4d
d8ea4d
* Thu Oct 24 2013 Mikolaj Izdebski <mizdebsk@redhat.com> - 0:1.2.17-14
d8ea4d
- Remove desktop files
d8ea4d
d8ea4d
* Thu Jul 11 2013 Michal Srb <msrb@redhat.com> - 0:1.2.17-13
d8ea4d
- Enable tests
d8ea4d
- Fix BR
d8ea4d
d8ea4d
* Tue May 14 2013 Ville Skyttä <ville.skytta@iki.fi> - 0:1.2.17-12
d8ea4d
- Add DTD public id to XML and SGML catalogs.
d8ea4d
d8ea4d
* Mon Apr 29 2013 Mikolaj Izdebski <mizdebsk@redhat.com> - 0:1.2.17-11
d8ea4d
- Remove unneeded BR: maven-idea-plugin
d8ea4d
d8ea4d
* Thu Apr 11 2013 Mikolaj Izdebski <mizdebsk@redhat.com> - 0:1.2.17-10
d8ea4d
- Fix manpage names, thanks to Michal Srb for reporting
d8ea4d
d8ea4d
* Mon Apr  8 2013 Mikolaj Izdebski <mizdebsk@redhat.com> - 0:1.2.17-9
d8ea4d
- Reindex sources in more sensible way
d8ea4d
- Add manual pages; resolves: rhbz#949413
d8ea4d
d8ea4d
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0:1.2.17-8
d8ea4d
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
d8ea4d
d8ea4d
* Wed Feb 06 2013 Java SIG <java-devel@lists.fedoraproject.org> - 0:1.2.17-7
d8ea4d
- Update for https://fedoraproject.org/wiki/Fedora_19_Maven_Rebuild
d8ea4d
- Replace maven BuildRequires with maven-local
d8ea4d
d8ea4d
* Mon Jan 21 2013 Mikolaj Izdebski <mizdebsk@redhat.com> - 0:1.2.17-6
d8ea4d
- Build aggregated javadocs with xmvn
d8ea4d
d8ea4d
* Fri Jan 18 2013 Michal Srb <msrb@redhat.com> - 0:1.2.17-5
d8ea4d
- Build with xmvn
d8ea4d
d8ea4d
* Mon Sep 24 2012 Mikolaj Izdebski <mizdebsk@redhat.com> - 0:1.2.17-4
d8ea4d
- Generate javadocs without maven skin
d8ea4d
d8ea4d
* Thu Jul 19 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0:1.2.17-3
d8ea4d
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
d8ea4d
d8ea4d
* Thu Jun 14 2012 Stanislav Ochotnicky <sochotnicky@redhat.com> - 0:1.2.17-2
d8ea4d
- Remove "uses" OSGI directives from MANIFEST (related #826776)
d8ea4d
d8ea4d
* Mon Jun 04 2012 Stanislav Ochotnicky <sochotnicky@redhat.com> - 0:1.2.17-1
d8ea4d
- Update to latest version
d8ea4d
- Change OSGI bundle symbolic name to org.apache.log4j
d8ea4d
- Resolves #826776
d8ea4d
d8ea4d
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0:1.2.16-11
d8ea4d
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
d8ea4d
d8ea4d
* Fri Oct 28 2011 Alexander Kurtakov <akurtako@redhat.com> 0:1.2.16-10
d8ea4d
- Remove duplicate import-package declaration.
d8ea4d
- Adapt to current guidelines.
d8ea4d
- Remove no longer needed patches.
d8ea4d
d8ea4d
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0:1.2.16-9
d8ea4d
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
d8ea4d
d8ea4d
* Tue Jan 18 2011 Ville Skyttä <ville.skytta@iki.fi> - 0:1.2.16-8
d8ea4d
- Drop executable file mode bits from icons.
d8ea4d
d8ea4d
* Fri Dec 17 2010 Stanislav Ochotnicky <sochotnicky@redhat.com> - 0:1.2.16-7
d8ea4d
- Use package instead of install mvn target to fix build
d8ea4d
d8ea4d
* Thu Dec 16 2010 Alexander Kurtakov <akurtako@redhat.com> 0:1.2.16-6
d8ea4d
- Do not require jaxp_parser_impl. Maven build is not using it all and it's provided by every Java5 JVM.
d8ea4d
d8ea4d
* Thu Dec  9 2010 Stanislav Ochotnicky <sochotnicky@redhat.com> - 0:1.2.16-5
d8ea4d
- Add patch to fix ant groupId
d8ea4d
- Versionless jars & javadocs
d8ea4d
d8ea4d
* Tue Sep  7 2010 Stanislav Ochotnicky <sochotnicky@redhat.com> - 0:1.2.16-4
d8ea4d
- Fix BRs to include ant-junit
d8ea4d
- Fix changed path for javadocs after build run
d8ea4d
d8ea4d
* Thu Jul  8 2010 Stanislav Ochotnicky <sochotnicky@redhat.com> - 0:1.2.16-3
d8ea4d
- Add license to javadoc and manual subpackages
d8ea4d
d8ea4d
* Fri May 28 2010 Stanislav Ochotnicky <sochotnicky@redhat.com> - 0:1.2.16-2
d8ea4d
- Install pom file
d8ea4d
- Trim changelog
d8ea4d
- Add jpackage-utils to javadoc Requires
d8ea4d
d8ea4d
* Mon May 17 2010 Stanislav Ochotnicky <sochotnicky@redhat.com> - 0:1.2.16-1
d8ea4d
- Complete re-working of whole ebuild to work with maven
d8ea4d
- Rebase to new version
d8ea4d
- Drop gcj support
d8ea4d
d8ea4d
* Sat Jul 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0:1.2.14-6.3
d8ea4d
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
d8ea4d
d8ea4d
* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0:1.2.14-5.3
d8ea4d
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
d8ea4d
d8ea4d
* Wed Jul  9 2008 Tom "spot" Callaway <tcallawa@redhat.com> - 0:1.2.14-4.3
d8ea4d
- drop repotag
d8ea4d
d8ea4d
* Thu May 29 2008 Tom "spot" Callaway <tcallawa@redhat.com> - 0:1.2.14-4jpp.2
d8ea4d
- fix license tag
d8ea4d
d8ea4d
* Tue Feb 19 2008 Fedora Release Engineering <rel-eng@fedoraproject.org> - 0:1.2.14-4jpp.1
d8ea4d
- Autorebuild for GCC 4.3
d8ea4d
d8ea4d
* Sat May 26 2007 Vivek Lakshmanan <vivekl@redhat.com> 0:1.2.14-3jpp.1
d8ea4d
- Upgrade to 1.2.14
d8ea4d
- Modify the categories for the .desktop files so they are only
d8ea4d
  displayed under the development/programming menus
d8ea4d
- Resolves: bug 241447
d8ea4d
d8ea4d
* Fri May 11 2007 Jason Corley <jason.corley@gmail.com> 0:1.2.14-3jpp
d8ea4d
- rebuild through mock and centos 4
d8ea4d
- replace vendor and distribution with macros
d8ea4d
d8ea4d
* Fri Apr 20 2007 Ralph Apel <r.apel at r-apel.de> - 0:1.2.14-2jpp
d8ea4d
- Patch to allow build of org.apache.log4j.jmx.* with mx4j
d8ea4d
- Restore Vendor: and Distribution:
d8ea4d
d8ea4d
* Sat Feb 17 2007 Fernando Nasser <fnasser@redhat.com> - 0:1.2.14-1jpp
d8ea4d
- Upgrade
d8ea4d
d8ea4d
* Mon Feb 12 2007 Ralph Apel <r.apel at r-apel.de> - 0:1.2.13-4jpp
d8ea4d
- Add bootstrap option to build core
d8ea4d
d8ea4d
* Wed Aug 09 2006 Vivek Lakshmanan <vivekl@redhat.com> - 0:1.2.13-3jpp.2
d8ea4d
- Remove patch for BZ #157585 because it doesnt seem to be needed anymore.
d8ea4d
d8ea4d
* Tue Aug 08 2006 Vivek Lakshmanan <vivekl@redhat.com> - 0:1.2.13-3jpp.1
d8ea4d
- Re-sync with latest from JPP.
d8ea4d
- Update patch for BZ #157585 to apply cleanly.
d8ea4d
- Partially adopt new naming convention.
d8ea4d
d8ea4d
* Sat Jul 22 2006 Jakub Jelinek <jakub@redhat.com> - 0:1.2.13-2jpp_2fc
d8ea4d
- Rebuilt
d8ea4d
d8ea4d
* Fri Jul 21 2006 Vivek Lakshmanan <vivekl@redhat.com> - 0:1.2.13-2jpp_1fc
d8ea4d
- Merge spec and patches with latest from JPP.
d8ea4d
- Clean source tar ball off prebuilt jars and classes.
d8ea4d
- Use classpathx-jaf and jms for buildrequires for the time being.
d8ea4d
d8ea4d
* Wed Jul 12 2006 Jesse Keating <jkeating@redhat.com> - 0:1.2.8-7jpp_9fc
d8ea4d
- rebuild
d8ea4d
d8ea4d
* Mon Mar  6 2006 Jeremy Katz <katzj@redhat.com> - 0:1.2.8-7jpp_8fc
d8ea4d
- fix scriptlet spew
d8ea4d
d8ea4d
* Wed Dec 21 2005 Jesse Keating <jkeating@redhat.com> 0:1.2.8-7jpp7fc
d8ea4d
- rebuilt again
d8ea4d
d8ea4d
* Fri Dec 09 2005 Jesse Keating <jkeating@redhat.com>
d8ea4d
- rebuilt
d8ea4d
d8ea4d
* Thu Nov  3 2005 Archit Shah <ashah@redhat.com> 0:1.2.8-7jpp_6fc
d8ea4d
- Reenable building of example that uses rmic
d8ea4d
d8ea4d
* Wed Jun 22 2005 Gary Benson <gbenson@redhat.com> 0:1.2.8-7jpp_5fc
d8ea4d
- Reenable building of classes that require jms.
d8ea4d
- Remove classes and jarfiles from the tarball.
d8ea4d
d8ea4d
* Mon May 23 2005 Gary Benson <gbenson@redhat.com> 0:1.2.8-7jpp_4fc
d8ea4d
- Work around chainsaw failure (#157585).
d8ea4d
d8ea4d
* Tue Jan 11 2005 Gary Benson <gbenson@redhat.com> 0:1.2.8-7jpp_3fc
d8ea4d
- Reenable building of classes that require javax.swing (#130006).
d8ea4d
d8ea4d
* Thu Nov  4 2004 Gary Benson <gbenson@redhat.com> 0:1.2.8-7jpp_2fc
d8ea4d
- Build into Fedora.