directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fel...@apache.org
Subject svn commit: r640329 - /directory/daemon/branches/bigbang/plugin/src/main/java/org/apache/directory/daemon/installers/rpm/RpmInstallerCommand.java
Date Mon, 24 Mar 2008 06:45:27 GMT
Author: felixk
Date: Sun Mar 23 23:45:27 2008
New Revision: 640329

URL: http://svn.apache.org/viewvc?rev=640329&view=rev
Log:
- IMO it's even worse practice to pollute users home directory with files created during a
build process.
Changing directory leaded to errors - fixed in daemon-plugin-1.1.2-SNAPSHOT, therefor use
this version for rpm generation.
- Fix messed up of use of configuration and system(default) properties.

Modified:
    directory/daemon/branches/bigbang/plugin/src/main/java/org/apache/directory/daemon/installers/rpm/RpmInstallerCommand.java

Modified: directory/daemon/branches/bigbang/plugin/src/main/java/org/apache/directory/daemon/installers/rpm/RpmInstallerCommand.java
URL: http://svn.apache.org/viewvc/directory/daemon/branches/bigbang/plugin/src/main/java/org/apache/directory/daemon/installers/rpm/RpmInstallerCommand.java?rev=640329&r1=640328&r2=640329&view=diff
==============================================================================
--- directory/daemon/branches/bigbang/plugin/src/main/java/org/apache/directory/daemon/installers/rpm/RpmInstallerCommand.java
(original)
+++ directory/daemon/branches/bigbang/plugin/src/main/java/org/apache/directory/daemon/installers/rpm/RpmInstallerCommand.java
Sun Mar 23 23:45:27 2008
@@ -112,7 +112,7 @@
 
         if ( target.getRpmTopDir() == null )
         {
-            target.setRpmTopDir( new File( System.getProperty( "user.home" ) + "/rpmbuild"
) );
+            target.setRpmTopDir( new File( "target/rpmbuild" ) );
         }
 
         if ( !target.getRpmTopDir().exists() )
@@ -233,8 +233,8 @@
         String[] cmd = new String[]
             { rpmBuilder.getAbsolutePath(), "-ba", "--define", "_topdir " + target.getRpmTopDir().getAbsolutePath(),
rpmConfigurationFile.getAbsolutePath() };
         MojoHelperUtils.exec( cmd, target.getLayout().getBaseDirectory().getParentFile(),
target.isDoSudo() );
-        String rpmName = target.getApplication().getName() + "-" + version + "-0.i386.rpm";
-        File srcFile = new File( target.getRpmTopDir(), "RPMS/i386/" + rpmName );
+        String rpmName = target.getApplication().getName() + "-" + version + "-0." + target.getOsArch()
+ ".rpm";
+        File srcFile = new File( target.getRpmTopDir(), "RPMS/" + target.getOsArch() + "/"
+ rpmName );
         File dstFile = null;
 
         if ( target.getFinalName() == null )



Mime
View raw message