diff --git a/ant/ant.conf b/ant/ant.conf index 96793bf610..2c9c82dd15 100644 --- a/ant/ant.conf +++ b/ant/ant.conf @@ -2,3 +2,6 @@ ## @l_prefix@/etc/ant/ant.conf -- Configuration file of Apache Ant build tool ## +ANT_HOME="@l_prefix@" +export ANT_HOME + diff --git a/ant/ant.spec b/ant/ant.spec index 307afb3176..ef75e030ed 100644 --- a/ant/ant.spec +++ b/ant/ant.spec @@ -37,7 +37,7 @@ Distribution: OpenPKG [EVAL] Group: Development License: Apache Software License Version: %{V_opkg} -Release: 20030418 +Release: 20030709 # list of sources Source0: http://www.apache.org/dist/ant/binaries/apache-ant-%{V_real}-bin.tar.bz2 @@ -48,7 +48,7 @@ Source2: rc.ant Prefix: %{l_prefix} BuildRoot: %{l_buildroot} BuildPreReq: OpenPKG, openpkg >= 20020206 -PreReq: OpenPKG, openpkg >= 20020206, JRE, perl, python +PreReq: OpenPKG, openpkg >= 20020206, JRE AutoReq: no AutoReqProv: no @@ -66,19 +66,6 @@ AutoReqProv: no # and egg problem. But in the end this doesn't hurt very much since we # are talking about Java byte code and shell scripts which are portable # anyway. - ( cd bin - %{l_shtool} subst \ - -e 's;^#!/usr/bin/perl;#!@l_prefix@/bin/perl;' \ - antRun.pl complete-ant-cmd.pl runant.pl - %{l_shtool} subst \ - -e 's;^#!/usr/bin/python;#!@l_prefix@/bin/python;' \ - runant.py - %{l_shtool} subst \ - -e 's;/etc/ant.conf;@l_prefix@/etc/ant/ant.conf;' \ - ant - %{l_shtool} subst \ - -e 's;\r$;;' \ - ant antRun antRun.pl complete-ant-cmd.pl runant.pl runant.py ) %install rm -rf $RPM_BUILD_ROOT @@ -86,14 +73,15 @@ AutoReqProv: no $RPM_BUILD_ROOT%{l_prefix}/bin \ $RPM_BUILD_ROOT%{l_prefix}/etc/ant \ $RPM_BUILD_ROOT%{l_prefix}/etc/rc.d \ - $RPM_BUILD_ROOT%{l_prefix}/lib - for i in ant antRun antRun.pl complete-ant-cmd.pl runant.pl runant.py; do - %{l_shtool} install -c -m 755 \ - -e 's;@l_prefix@;%{l_prefix};g' \ - bin/$i $RPM_BUILD_ROOT%{l_prefix}/bin/ - done + $RPM_BUILD_ROOT%{l_prefix}/libexec/ant + %{l_shtool} install -c -m 755 \ + -e 's;/etc/ant.conf;@l_prefix@/etc/ant/ant.conf;' \ + -e 's;@l_prefix@;%{l_prefix};g' \ + -e 's;^\(ANT_LIB="\)[^"]*\("\);\1%{l_prefix}/libexec/ant\2;' \ + -e 's;\r$;;' \ + bin/ant $RPM_BUILD_ROOT%{l_prefix}/bin/ %{l_shtool} install -c -m 644 \ - lib/*.jar $RPM_BUILD_ROOT%{l_prefix}/lib/ + lib/*.jar $RPM_BUILD_ROOT%{l_prefix}/libexec/ant/ %{l_shtool} install -c -m 644 -e 's;@l_prefix@;%{l_prefix};g' \ %{SOURCE ant.conf} $RPM_BUILD_ROOT%{l_prefix}/etc/ant/ %{l_shtool} install -c -m 755 -e 's;@l_prefix@;%{l_prefix};g' \