# Note to packagers: When rebasing this to a later version, do not # forget to ensure that sources 1 and 2 are up to date as well as # the Requires list. Name: groovy Version: 1.7.10 Release: %mkrel 4 Summary: Dynamic language for the Java Platform Group: Development/Java License: ASL 2.0 URL: http://groovy.codehaus.org/ Source0: http://dist.groovy.codehaus.org/distributions/groovy-src-%{version}.zip Source1: groovy17-script Source2: groovy17-starter.conf Source3: groovy.desktop Patch1: groovy-1.7.7-nojansi.patch Patch2: groovy-1.7.10-skipOsgi.patch Patch3: groovy-1.7.10-antbuild.patch BuildArch: noarch BuildRequires: ant BuildRequires: antlr BuildRequires: ant-antlr BuildRequires: objectweb-asm BuildRequires: bsf BuildRequires: apache-ivy BuildRequires: jline BuildRequires: jsp21 BuildRequires: junit BuildRequires: servlet25 BuildRequires: xstream BuildRequires: java-devel >= 1.6 BuildRequires: desktop-file-utils BuildRequires: jpackage-utils BuildRequires: apache-commons-cli BuildRequires: aqute-bndlib BuildRequires: apache-commons-beanutils BuildRequires: apache-commons-lang BuildRequires: apache-commons-logging BuildRequires: jansi BuildRequires: livetribe-jsr223 BuildRequires: mockobjects BuildRequires: qdox BuildRequires: jarjar BuildRequires: unzip Requires: jpackage-utils # The are all runtime dependencies of the script # TODO: Think of splitting them into a separate subpackage Requires: ant Requires: ant-junit Requires: antlr-tool Requires: objectweb-asm Requires: bsf Requires: apache-commons-cli Requires: apache-commons-logging Requires: apache-ivy Requires: jline Requires: jsp21 Requires: junit Requires: servlet25 Requires: xstream Requires: ant-antlr Requires: jansi Requires: jarjar Requires: livetribe-jsr223 Requires: mockobjects Requires: qdox Provides: groovy17 Obsoletes: groovy17 %description Groovy is an agile and dynamic language for the Java Virtual Machine, built upon Java with features inspired by languages like Python, Ruby and Smalltalk. It seamlessly integrates with all existing Java objects and libraries and compiles straight to Java bytecode so you can use it anywhere you can use Java. %package javadoc Summary: API Documentation for %{name} Group: Development/Java Requires: %{name} = %{version}-%{release} Requires: jpackage-utils %description javadoc JavaDoc documentation for %{name} %prep %setup -q -n groovy-%{version} ##%patch1 -p1 -b .jansi %patch2 -p0 %patch3 -p1 %build mkdir -p target/lib/{compile,runtime,tools} # Construct classpath export CLASSPATH="" CLASSPATH=$CLASSPATH:$(build-classpath antlr ant ant/ant-junit ant/ant-antlr ant-launcher servlet jsp bsf) CLASSPATH=$CLASSPATH:$(build-classpath jansi commons-cli mockobjects-core qdox jarjar livetribe-jsr223 junit) CLASSPATH=$CLASSPATH:$(build-classpath log4j aqute-bndlib objectweb-asm commons-beanutils commons-beanutils-core) CLASSPATH=$CLASSPATH:$(build-classpath commons-lang commons-logging oro jline xstream ivy) # Build # TODO: Build at least tests, maybe examples ant -DskipTests=on -DskipExamples=on -DskipFetch=on \ install javadoc %install # Code install -d $RPM_BUILD_ROOT%{_javadir} install -p -m644 target/dist/groovy.jar $RPM_BUILD_ROOT%{_javadir}/%{name}.jar ln -sf %{name}.jar $RPM_BUILD_ROOT%{_javadir}/%{name}17.jar install -p -m644 target/dist/groovy-all.jar $RPM_BUILD_ROOT%{_javadir}/%{name}-all.jar ln -sf %{name}-all.jar $RPM_BUILD_ROOT%{_javadir}/%{name}17-all.jar # Startup scripts install -d $RPM_BUILD_ROOT%{_bindir} install -p -m755 %{SOURCE1} $RPM_BUILD_ROOT%{_bindir}/groovy for TOOL in grape groovyc groovyConsole java2groovy groovysh do ln $RPM_BUILD_ROOT%{_bindir}/groovy \ $RPM_BUILD_ROOT%{_bindir}/$TOOL done # Configuration install -d $RPM_BUILD_ROOT%{_sysconfdir} #install -p -m644 %{SOURCE2} \ # $RPM_BUILD_ROOT%{_sysconfdir}/groovy17-starter.conf install -p -m644 %{SOURCE2} \ $RPM_BUILD_ROOT%{_sysconfdir}/groovy-starter.conf # Desktop icon install -d $RPM_BUILD_ROOT%{_datadir}/pixmaps install -d $RPM_BUILD_ROOT%{_datadir}/applications install -p -m644 src/main/groovy/ui/ConsoleIcon.png \ $RPM_BUILD_ROOT%{_datadir}/pixmaps/groovy.png desktop-file-install --dir $RPM_BUILD_ROOT%{_datadir}/applications \ %{SOURCE3} # API Documentation install -d $RPM_BUILD_ROOT%{_javadocdir}/%{name}-%{version} find target -type d |xargs chmod 755 cp -rp target/html/api/. $RPM_BUILD_ROOT%{_javadocdir}/%{name}-%{version} # Maven depmap install -d $RPM_BUILD_ROOT%{_mavenpomdir} install -p -m644 pom.xml $RPM_BUILD_ROOT/%{_mavenpomdir}/JPP-%{name}.pom %add_maven_depmap JPP-%{name}.pom %{name}.jar install -p -m644 target/groovy-all.pom $RPM_BUILD_ROOT/%{_mavenpomdir}/JPP-%{name}-all.pom %add_maven_depmap JPP-%{name}-all.pom %{name}-all.jar # req for gmaven %add_to_maven_depmap org.codehaus.groovy groovy17 %{version} JPP groovy17 %add_to_maven_depmap org.codehaus.groovy groovy17-all %{version} JPP groovy17-all %files %defattr(-,root,root,-) %{_bindir}/* %{_javadir}/* %{_datadir}/pixmaps/* %{_datadir}/applications/* %{_mavendepmapfragdir}/* %{_mavenpomdir}/* %config(noreplace) %{_sysconfdir}/* %doc LICENSE.txt NOTICE.txt README.txt %files javadoc %defattr(-,root,root,-) %{_javadocdir}/* %post %update_maven_depmap %postun %update_maven_depmap %changelog * Thu Dec 22 2011 gil <gil> 1.7.10-4.mga2 + Revision: 185652 - build fix edit desktop file change icon name * Thu Dec 08 2011 gil <gil> 1.7.10-3.mga2 + Revision: 178983 - corrected groovy17-all link * Tue Aug 30 2011 gil <gil> 1.7.10-2.mga2 + Revision: 136788 - edit desktop file - Revert to groovy 1.7.10 - update to 1.8.1 - edit spec file, added groovy-all jar required by gradle * Thu Apr 28 2011 dmorgan <dmorgan> 1.7.10-2.mga1 + Revision: 92450 - Rebuild after bootstrapping - imported package groovy * Tue Mar 22 2011 Alexander Kurtakov <akurtako@redhat.com> 1.7.10-1 - Update to upstream release. * Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.7.7-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild * Sat Nov 6 2010 Alexander Kurtakov <akurtako@redhat.com> 1.7.2-3 - Build with servlet and jsp apis from tomcat6. * Thu Jun 17 2010 Lubomir Rintel <lkundrak@v3.sk> - 1.7.2-2 - Fix a typo * Tue Apr 20 2010 Lubomir Rintel <lkundrak@v3.sk> - 1.7.2-1 - Bump version * Fri Apr 02 2010 Lubomir Rintel <lkundrak@v3.sk> - 1.7.1-1 - Bump version - Revert addition of jansi dependency * Fri Apr 02 2010 Lubomir Rintel <lkundrak@v3.sk> - 1.7.0-2 - Add maven depmap * Wed Feb 17 2010 Lubomir Rintel <lkundrak@v3.sk> - 1.7.0-1 - New upstream version - Use asm 3.1 instead of asm2 * Wed Dec 04 2009 Lubomir Rintel <lkundrak@v3.sk> - 1.6.7-1 - New upstream version - Make Jochen happy * Thu Dec 03 2009 Lubomir Rintel <lkundrak@v3.sk> - 1.6.6-2 - Build with OpenJDK * Mon Nov 30 2009 Lubomir Rintel <lkundrak@v3.sk> - 1.6.6-1 - Bump to 1.6.6 - Don't mistakenly require itself (Jochen Schmitt, #534168#c3) * Fri Nov 27 2009 Lubomir Rintel <lkundrak@v3.sk> - 1.6.5-2 - Hopefully fix mockbuild * Mon Nov 09 2009 Lubomir Rintel <lkundrak@v3.sk> - 1.6.5-1 - Initial Fedora packaging