Blame SPECS/google-guice.spec

2674b2
%{?scl:%scl_package google-guice}
2674b2
%{!?scl:%global pkg_name %{name}}
2674b2
2674b2
Name:           %{?scl_prefix}google-guice
2674b2
Version:        4.2.2
2674b2
Release:        2.2%{?dist}
2674b2
Summary:        Lightweight dependency injection framework for Java 5 and above
2674b2
License:        ASL 2.0
2674b2
URL:            https://github.com/google/guice
2674b2
BuildArch:      noarch
2674b2
2674b2
# ./create-tarball.sh %%{version}
2674b2
Source0:        %{pkg_name}-%{version}.tar.xz
2674b2
Source1:        create-tarball.sh
2674b2
2674b2
BuildRequires:  %{?scl_prefix}maven-local
2674b2
BuildRequires:  %{?scl_prefix}mvn(aopalliance:aopalliance)
2674b2
BuildRequires:  %{?scl_prefix}mvn(cglib:cglib)
2674b2
BuildRequires:  %{?scl_prefix}mvn(com.google.guava:guava)
2674b2
BuildRequires:  %{?scl_prefix}mvn(javax.inject:javax.inject)
2674b2
BuildRequires:  %{?scl_prefix}mvn(javax.servlet:servlet-api)
2674b2
BuildRequires:  %{?scl_prefix}mvn(org.apache.felix:maven-bundle-plugin)
2674b2
BuildRequires:  %{?scl_prefix}mvn(org.apache.maven.plugins:maven-remote-resources-plugin)
2674b2
BuildRequires:  %{?scl_prefix}mvn(org.apache.maven.plugins:maven-source-plugin)
2674b2
BuildRequires:  %{?scl_prefix}mvn(org.codehaus.mojo:build-helper-maven-plugin)
2674b2
BuildRequires:  %{?scl_prefix}mvn(org.ow2.asm:asm)
2674b2
BuildRequires:  %{?scl_prefix}mvn(org.slf4j:slf4j-api)
2674b2
BuildRequires:  %{?scl_prefix}mvn(org.sonatype.plugins:munge-maven-plugin)
2674b2
# xmvn-builddep misses this:
2674b2
BuildRequires:  %{?scl_prefix}mvn(org.apache:apache-jar-resource-bundle)
2674b2
2674b2
%description
2674b2
Put simply, Guice alleviates the need for factories and the use of new
2674b2
in your Java code. Think of Guice's @Inject as the new new. You will
2674b2
still need to write factories in some cases, but your code will not
2674b2
depend directly on them. Your code will be easier to change, unit test
2674b2
and reuse in other contexts.
2674b2
2674b2
Guice embraces Java's type safe nature, especially when it comes to
2674b2
features introduced in Java 5 such as generics and annotations. You
2674b2
might think of Guice as filling in missing features for core
2674b2
Java. Ideally, the language itself would provide most of the same
2674b2
features, but until such a language comes along, we have Guice.
2674b2
2674b2
Guice helps you design better APIs, and the Guice API itself sets a
2674b2
good example. Guice is not a kitchen sink. We justify each feature
2674b2
with at least three use cases. When in doubt, we leave it out. We
2674b2
build general functionality which enables you to extend Guice rather
2674b2
than adding every feature to the core framework.
2674b2
2674b2
%package -n %{?scl_prefix}guice-parent
2674b2
Summary:        Guice parent POM
2674b2
2674b2
%description -n %{?scl_prefix}guice-parent
2674b2
Guice is a lightweight dependency injection framework for Java 5
2674b2
and above. This package provides parent POM for Guice modules.
2674b2
2674b2
%package -n %{?scl_prefix}guice-assistedinject
2674b2
Summary:        AssistedInject extension module for Guice
2674b2
2674b2
%description -n %{?scl_prefix}guice-assistedinject
2674b2
Guice is a lightweight dependency injection framework for Java 5
2674b2
and above. This package provides AssistedInject module for Guice.
2674b2
2674b2
%package -n %{?scl_prefix}guice-extensions
2674b2
Summary:        Extensions for Guice
2674b2
2674b2
%description -n %{?scl_prefix}guice-extensions
2674b2
Guice is a lightweight dependency injection framework for Java 5
2674b2
and above. This package provides extensions POM for Guice.
2674b2
2674b2
%package -n %{?scl_prefix}guice-grapher
2674b2
Summary:        Grapher extension module for Guice
2674b2
2674b2
%description -n %{?scl_prefix}guice-grapher
2674b2
Guice is a lightweight dependency injection framework for Java 5
2674b2
and above. This package provides Grapher module for Guice.
2674b2
2674b2
%package -n %{?scl_prefix}guice-jmx
2674b2
Summary:        JMX extension module for Guice
2674b2
2674b2
%description -n %{?scl_prefix}guice-jmx
2674b2
Guice is a lightweight dependency injection framework for Java 5
2674b2
and above. This package provides JMX module for Guice.
2674b2
2674b2
%package -n %{?scl_prefix}guice-jndi
2674b2
Summary:        JNDI extension module for Guice
2674b2
2674b2
%description -n %{?scl_prefix}guice-jndi
2674b2
Guice is a lightweight dependency injection framework for Java 5
2674b2
and above. This package provides JNDI module for Guice.
2674b2
2674b2
%package -n %{?scl_prefix}guice-multibindings
2674b2
Summary:        MultiBindings extension module for Guice
2674b2
2674b2
%description -n %{?scl_prefix}guice-multibindings
2674b2
Guice is a lightweight dependency injection framework for Java 5
2674b2
and above. This package provides MultiBindings module for Guice.
2674b2
2674b2
%package -n %{?scl_prefix}guice-servlet
2674b2
Summary:        Servlet extension module for Guice
2674b2
2674b2
%description -n %{?scl_prefix}guice-servlet
2674b2
Guice is a lightweight dependency injection framework for Java 5
2674b2
and above. This package provides Servlet module for Guice.
2674b2
2674b2
%package -n %{?scl_prefix}guice-throwingproviders
2674b2
Summary:        ThrowingProviders extension module for Guice
2674b2
2674b2
%description -n %{?scl_prefix}guice-throwingproviders
2674b2
Guice is a lightweight dependency injection framework for Java 5
2674b2
and above. This package provides ThrowingProviders module for Guice.
2674b2
2674b2
%package -n %{?scl_prefix}guice-bom
2674b2
Summary:        Bill of Materials for Guice
2674b2
2674b2
%description -n %{?scl_prefix}guice-bom
2674b2
Guice is a lightweight dependency injection framework for Java 5
2674b2
and above. This package provides Bill of Materials module for Guice.
2674b2
2674b2
%{?module_package}
2674b2
%{?javadoc_package}
2674b2
2674b2
%prep
2674b2
%setup -n %{pkg_name}-%{version} -q
2674b2
2674b2
# We don't have struts2 in Fedora yet.
2674b2
%pom_disable_module struts2 extensions
2674b2
# Android-specific extension
2674b2
%pom_disable_module dagger-adapter extensions
2674b2
2674b2
# Remove additional build profiles, which we don't use anyways
2674b2
# and which are only pulling additional dependencies.
2674b2
%pom_xpath_remove "pom:profile[pom:id='guice.with.jarjar']" core
2674b2
2674b2
# Fix OSGi metadata due to not using jarjar
2674b2
%pom_xpath_set "pom:instructions/pom:Import-Package" \
2674b2
  "!com.google.inject.*,*" core
2674b2
2674b2
# Animal sniffer is only causing problems. Disable it for now.
2674b2
%pom_remove_plugin :animal-sniffer-maven-plugin core
2674b2
%pom_remove_plugin :animal-sniffer-maven-plugin extensions
2674b2
2674b2
%pom_remove_plugin :maven-gpg-plugin
2674b2
2674b2
# We don't have the custom doclet used by upstream. Remove
2674b2
# maven-javadoc-plugin to generate javadocs with default style.
2674b2
%pom_remove_plugin -r :maven-javadoc-plugin
2674b2
2674b2
# remove test dependency to make sure we don't produce requires
2674b2
# see #1007498
2674b2
%pom_remove_dep :guava-testlib extensions
2674b2
%pom_xpath_remove "pom:dependency[pom:classifier[text()='tests']]" extensions
2674b2
2674b2
%pom_remove_parent
2674b2
%pom_set_parent com.google.inject:guice-parent:%{version} jdk8-tests
2674b2
2674b2
%pom_disable_module persist extensions
2674b2
%pom_disable_module spring extensions
2674b2
2674b2
%pom_disable_module jdk8-tests
2674b2
2674b2
# Require a newer compiler
2674b2
%pom_xpath_set "pom:build/pom:pluginManagement/pom:plugins/pom:plugin[pom:artifactId='maven-compiler-plugin']/pom:configuration/pom:source" "1.8"
2674b2
%pom_xpath_set "pom:build/pom:pluginManagement/pom:plugins/pom:plugin[pom:artifactId='maven-compiler-plugin']/pom:configuration/pom:target" "1.8"
2674b2
2674b2
%pom_disable_module testlib extensions
2674b2
2674b2
%build
2674b2
%mvn_alias "com.google.inject.extensions:" "org.sonatype.sisu.inject:"
2674b2
2674b2
%mvn_package :::no_aop: guice
2674b2
2674b2
%mvn_file  ":guice-{*}"  guice/guice-@1
2674b2
%mvn_file  ":guice" guice/%{pkg_name} %{pkg_name}
2674b2
%mvn_alias ":guice" "org.sonatype.sisu:sisu-guice"
2674b2
# Skip tests because of missing dependency guice-testlib
2674b2
%mvn_build -f -s
2674b2
2674b2
%install
2674b2
%mvn_install
2674b2
2674b2
%files -n %{name} -f .mfiles-guice
2674b2
2674b2
%files -n %{?scl_prefix}guice-parent -f .mfiles-guice-parent
2674b2
%license COPYING
2674b2
2674b2
%files -n %{?scl_prefix}guice-assistedinject -f .mfiles-guice-assistedinject
2674b2
2674b2
%files -n %{?scl_prefix}guice-extensions -f .mfiles-extensions-parent
2674b2
2674b2
%files -n %{?scl_prefix}guice-grapher -f .mfiles-guice-grapher
2674b2
2674b2
%files -n %{?scl_prefix}guice-jmx -f .mfiles-guice-jmx
2674b2
2674b2
%files -n %{?scl_prefix}guice-jndi -f .mfiles-guice-jndi
2674b2
2674b2
%files -n %{?scl_prefix}guice-multibindings -f .mfiles-guice-multibindings
2674b2
2674b2
%files -n %{?scl_prefix}guice-servlet -f .mfiles-guice-servlet
2674b2
2674b2
%files -n %{?scl_prefix}guice-throwingproviders -f .mfiles-guice-throwingproviders
2674b2
2674b2
%files -n %{?scl_prefix}guice-bom -f .mfiles-guice-bom
2674b2
2674b2
%changelog
2674b2
* Wed Sep  4 2019 Mikolaj Izdebski <mizdebsk@redhat.com> - 4.2.2-2.2
2674b2
- Mass rebuild 2019-09-04
2674b2
2674b2
* Tue Sep  3 2019 Java Maintainers <java-maint@redhat.com> - 4.2.2-2.1
2674b2
- Automated package import and SCL-ization
2674b2
2674b2
* Fri May 24 2019 Mikolaj Izdebski <mizdebsk@redhat.com> - 4.2.2-2
2674b2
- Mass rebuild for javapackages-tools 201901
2674b2
2674b2
* Fri Apr 05 2019 Marian Koncek <mkoncek@redhat.com> - 4.2.2-1
2674b2
- Update to upstream version 4.2.2
2674b2
- Fixes: RHBZ #1563661
2674b2
2674b2
* Wed Apr 18 2018 Mikolaj Izdebski <mizdebsk@redhat.com> - 4.1-11
2674b2
- Remove legacy Provides
2674b2
2674b2
* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 4.1-10
2674b2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
2674b2
2674b2
* Mon Feb 05 2018 Michael Simacek <msimacek@redhat.com> - 4.1-9
2674b2
- Use guava20
2674b2
2674b2
* Mon Oct 02 2017 Mat Booth <mat.booth@redhat.com> - 4.1-8
2674b2
- Fix OSGi metadata to import cglib and asm, since we are not bundling them with
2674b2
  jarjar
2674b2
2674b2
* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 4.1-7
2674b2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
2674b2
2674b2
* Fri Jun 23 2017 Mikolaj Izdebski <mizdebsk@redhat.com> - 4.1-6
2674b2
- Remove unused patches
2674b2
2674b2
* Fri Feb 24 2017 Mikolaj Izdebski <mizdebsk@redhat.com> - 4.1-5
2674b2
- Remove maven-javadoc-plugin from all POMs
2674b2
2674b2
* Thu Feb 23 2017 Mikolaj Izdebski <mizdebsk@redhat.com> - 4.1-4
2674b2
- Add missing BR on apache-resource-bundles
2674b2
2674b2
* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 4.1-3
2674b2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
2674b2
2674b2
* Wed Feb  1 2017 Mikolaj Izdebski <mizdebsk@redhat.com> - 4.1-2
2674b2
- Introduce build-conditionals for jpa and spring
2674b2
2674b2
* Thu Aug  4 2016 Mikolaj Izdebski <mizdebsk@redhat.com> - 4.1-1
2674b2
- Update to upstream version 4.1
2674b2
2674b2
* Wed Jun 29 2016 Mikolaj Izdebski <mizdebsk@redhat.com> - 4.0-6
2674b2
- Make aopalliance dependency optional
2674b2
2674b2
* Wed Jun 15 2016 Mikolaj Izdebski <mizdebsk@redhat.com> - 4.0-5
2674b2
- Regenerate build-requires
2674b2
2674b2
* Wed Feb 03 2016 Fedora Release Engineering <releng@fedoraproject.org> - 4.0-4
2674b2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
2674b2
2674b2
* Tue Jan 12 2016 Mikolaj Izdebski <mizdebsk@redhat.com> - 4.0-3
2674b2
- Install BOM even when without extensions
2674b2
2674b2
* Wed Jun 17 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.0-2
2674b2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
2674b2
2674b2
* Thu May 14 2015 Mikolaj Izdebski <mizdebsk@redhat.com> - 4.0-1
2674b2
- Update to upstream version 4.0
2674b2
2674b2
* Mon Apr 27 2015 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.2.6-1
2674b2
- Update to upstream version 3.2.6
2674b2
2674b2
* Fri Mar 6 2015 Alexander Kurtakov <akurtako@redhat.com> 3.2.5-2
2674b2
- Drop gone tomcat-servlet-3.0-api BR, builds fine without it.
2674b2
2674b2
* Fri Jan 23 2015 Michael Simacek <msimacek@redhat.com> - 3.2.5-1
2674b2
- Update to upstream version 3.2.5
2674b2
2674b2
* Mon Sep 29 2014 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.2.4-1
2674b2
- Update to upstream version 3.2.4
2674b2
2674b2
* Fri Jun  6 2014 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.2.2-1
2674b2
- Update to upstream version 3.2.2
2674b2
2674b2
* Wed May 28 2014 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.2.1-2
2674b2
- Rebuild to regenerate Maven auto-requires
2674b2
2674b2
* Wed Apr 16 2014 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.2.1-1
2674b2
- Update to upstream version 3.2.1
2674b2
- Add testlib subpackage
2674b2
2674b2
* Tue Mar  4 2014 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.1.10-3
2674b2
- Fix directory ownership
2674b2
2674b2
* Tue Mar 04 2014 Stanislav Ochotnicky <sochotnicky@redhat.com> - 3.1.10-3
2674b2
- Use Requires: java-headless rebuild (#1067528)
2674b2
2674b2
* Wed Feb 19 2014 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.1.10-2
2674b2
- Fix unowned directory
2674b2
2674b2
* Tue Feb 18 2014 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.1.10-1
2674b2
- Update to upstream version 3.1.10
2674b2
2674b2
* Mon Jan 20 2014 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.1.9-1
2674b2
- Update to upstream version 3.1.9
2674b2
2674b2
* Mon Nov 11 2013 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.1.8-1
2674b2
- Update to upstream version 3.1.8
2674b2
2674b2
* Wed Oct 23 2013 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.1.3-10
2674b2
- Rebuild to regenerate broken POMs
2674b2
- Related: rhbz#1021484
2674b2
2674b2
* Fri Oct 18 2013 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.1.3-9
2674b2
- Don't force generation of pom.properties
2674b2
2674b2
* Wed Sep 25 2013 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.1.3-8
2674b2
- Install no_aop artifact after javapackages update
2674b2
2674b2
* Thu Sep 12 2013 Stanislav Ochotnicky <sochotnicky@redhat.com> - 3.1.3-7
2674b2
- Remove dependency on tests from runtime
2674b2
- Related: rhbz#1007498
2674b2
2674b2
* Tue Sep 10 2013 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.1.3-6
2674b2
- Install no_aop artifact
2674b2
- Resolves: rhbz#1006491
2674b2
2674b2
* Wed Sep  4 2013 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.1.3-5
2674b2
- Enable pom.properties
2674b2
- Resolves: rhbz#1004360
2674b2
2674b2
* Wed Aug 07 2013 Michal Srb <msrb@redhat.com> - 3.1.3-4
2674b2
- Add create-tarball.sh script to SRPM
2674b2
2674b2
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.1.3-3
2674b2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
2674b2
2674b2
* Wed Apr 24 2013 Michal Srb <msrb@redhat.com> - 3.1.3-2
2674b2
- Revert update to 3.1.4 (uses asm4)
2674b2
2674b2
* Thu Mar 14 2013 Michal Srb <msrb@redhat.com> - 3.1.3-1
2674b2
- Update to upstream version 3.1.3
2674b2
- Remove bundled JARs from tarball
2674b2
2674b2
* Wed Feb 06 2013 Java SIG <java-devel@lists.fedoraproject.org> - 3.1.2-11
2674b2
- Update for https://fedoraproject.org/wiki/Fedora_19_Maven_Rebuild
2674b2
- Replace maven BuildRequires with maven-local
2674b2
2674b2
* Thu Jan 31 2013 Michal Srb <msrb@redhat.com> - 3.1.2-10
2674b2
- Remove all requires
2674b2
- Correct usage of xmvn's macros
2674b2
2674b2
* Mon Jan 28 2013 Michal Srb <msrb@redhat.com> - 3.1.2-9
2674b2
- Build with xmvn
2674b2
2674b2
* Fri Nov 16 2012 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.1.2-8
2674b2
- Remove README
2674b2
2674b2
* Fri Nov 16 2012 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.1.2-7
2674b2
- Repackage tarball
2674b2
2674b2
* Fri Nov  9 2012 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.1.2-6
2674b2
- Don't try to build extension modules unless they are needed
2674b2
2674b2
* Fri Nov  9 2012 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.1.2-5
2674b2
- Conditionalize %%install section too
2674b2
2674b2
* Fri Nov  9 2012 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.1.2-4
2674b2
- Conditionally disable extensions
2674b2
2674b2
* Thu Nov  1 2012 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.1.2-3
2674b2
- Update to new add_maven_depmap macro
2674b2
2674b2
* Wed Oct 31 2012 Stanislav Ochotnicky <sochotnicky@redhat.com> - 3.1.2-2
2674b2
- Use new generated maven filelist feature from javapackages-tools
2674b2
2674b2
* Fri Oct  5 2012 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.1.2-1
2674b2
- Complete rewrite of the spec file
2674b2
- New upstream, to ease future maintenance
2674b2
- Build with maven instead of ant
2674b2
- Split into multiple subpackages
2674b2
2674b2
* Thu Jul 19 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.0-0.7.rc2
2674b2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
2674b2
2674b2
* Thu Feb  9 2012 Stanislav Ochotnicky <sochotnicky@redhat.com> - 3.0-0.6.rc2
2674b2
- Temporary fix for maven buildroots
2674b2
2674b2
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.0-0.5.rc2
2674b2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
2674b2
2674b2
* Wed Oct 12 2011 Stanislav Ochotnicky <sochotnicky@redhat.com> - 3.0-0.4.rc2
2674b2
- Build with aqute-bnd (#745176)
2674b2
- Use new maven macros
2674b2
- Few packaging tweaks
2674b2
2674b2
* Tue May 24 2011 Stanislav Ochotnicky <sochotnicky@redhat.com> - 3.0-0.3.rc2
2674b2
- Add cglib and atinject to R
2674b2
2674b2
* Thu May 12 2011 Stanislav Ochotnicky <sochotnicky@redhat.com> - 3.0-0.2.rc2
2674b2
- Remove test and missing deps from pom.xml
2674b2
2674b2
* Tue Mar  1 2011 Stanislav Ochotnicky <sochotnicky@redhat.com> - 3.0-0.1.rc2
2674b2
- Update to 3.0rc2
2674b2
- Changes according to new guidelines (versionless jars & javadocs)
2674b2
2674b2
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0-4.1219svn
2674b2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
2674b2
2674b2
* Thu Oct 14 2010 Stanislav Ochotnicky <sochotnicky@redhat.com> - 2.0-3.1219svn
2674b2
- Add java-devel >= 1:1.6.0 to BR
2674b2
2674b2
* Wed Oct 13 2010 Stanislav Ochotnicky <sochotnicky@redhat.com> - 2.0-2.1219svn
2674b2
- Moved munge repacking to prep
2674b2
- Added -Dversion to change generated manifest version
2674b2
- Removed http part of URL
2674b2
2674b2
* Thu Oct  7 2010 Stanislav Ochotnicky <sochotnicky@redhat.com> - 2.0-1.1219svn
2674b2
- Initial version of the package