directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From akaras...@apache.org
Subject svn commit: r372701 - in /directory/trunks/apacheds/standalone/installers/plugin/src/main: java/org/apache/directory/server/standalone/installers/inno/InnoInstallerCommand.java resources/org/apache/directory/server/standalone/installers/inno/install.iss
Date Fri, 27 Jan 2006 02:02:02 GMT
Author: akarasulu
Date: Thu Jan 26 18:01:53 2006
New Revision: 372701

URL: http://svn.apache.org/viewcvs?rev=372701&view=rev
Log:
fixing bugs in install file and mojo

Modified:
    directory/trunks/apacheds/standalone/installers/plugin/src/main/java/org/apache/directory/server/standalone/installers/inno/InnoInstallerCommand.java
    directory/trunks/apacheds/standalone/installers/plugin/src/main/resources/org/apache/directory/server/standalone/installers/inno/install.iss

Modified: directory/trunks/apacheds/standalone/installers/plugin/src/main/java/org/apache/directory/server/standalone/installers/inno/InnoInstallerCommand.java
URL: http://svn.apache.org/viewcvs/directory/trunks/apacheds/standalone/installers/plugin/src/main/java/org/apache/directory/server/standalone/installers/inno/InnoInstallerCommand.java?rev=372701&r1=372700&r2=372701&view=diff
==============================================================================
--- directory/trunks/apacheds/standalone/installers/plugin/src/main/java/org/apache/directory/server/standalone/installers/inno/InnoInstallerCommand.java
(original)
+++ directory/trunks/apacheds/standalone/installers/plugin/src/main/java/org/apache/directory/server/standalone/installers/inno/InnoInstallerCommand.java
Thu Jan 26 18:01:53 2006
@@ -97,17 +97,23 @@
             return;
         }
         
+        // @todo this should really be a parameter taken from the user's settings
+        // because the compiler may be installed in different places and is specific
         if ( ! target.getInnoCompiler().exists() )
         {
             throw new MojoFailureException( "Cannot find Inno compiler: " + target.getInnoCompiler()
);
         }
+        else
+        {
+        	this.innoCompiler = target.getInnoCompiler();
+        }
         
         // -------------------------------------------------------------------
         // Step 2 & 3: copy inno file and filter 
         // -------------------------------------------------------------------
         
         // check first to see if the default install.iss file is present in src/main/installers
-        File defaultInnoConfigurationFile = new File( mymojo.getSourceDirectory(), "install.iss"
);
+        File projectInnoFile = new File( mymojo.getSourceDirectory(), "install.iss" );
         if ( target.getInnoConfigurationFile() != null && target.getInnoConfigurationFile().exists()
)
         {
             try
@@ -121,17 +127,17 @@
                     + target.getInnoConfigurationFile() + " to " + innoConfigurationFile
);
             }
         }
-        else if ( defaultInnoConfigurationFile.exists() )
+        else if ( projectInnoFile.exists() )
         {
             try
             {
-                MojoHelperUtils.copyAsciiFile( mymojo, filterProperties, defaultInnoConfigurationFile,

+                MojoHelperUtils.copyAsciiFile( mymojo, filterProperties, projectInnoFile,

                     innoConfigurationFile, true );
             }
             catch ( IOException e )
             {
                 throw new MojoFailureException( "Failed to filter and copy project provided
" 
-                    + defaultInnoConfigurationFile + " to " + innoConfigurationFile );
+                    + projectInnoFile + " to " + innoConfigurationFile );
             }
         }
         else
@@ -150,6 +156,8 @@
         }
 
         Execute task = new Execute();
+        System.out.println( "innoCompiler = " + innoCompiler );
+        System.out.println( "innoConfigurationFile = " + innoConfigurationFile );
         String[] cmd = new String[] {
             innoCompiler.getAbsolutePath(), innoConfigurationFile.getAbsolutePath()
         };
@@ -211,10 +219,12 @@
             touchFile( target.getLayout().getReadmeFile() );
         }
         filterProperties.put( "app.readme" , target.getLayout().getReadmeFile().getPath()
);
+        filterProperties.put( "app.readme.name" , target.getLayout().getReadmeFile().getName()
);
         filterProperties.put( "app.icon" , target.getLayout().getLogoIconFile().getPath()
);
         filterProperties.put( "app.icon.name" , target.getLayout().getLogoIconFile().getName()
);
         filterProperties.put( "image.basedir", target.getLayout().getBaseDirectory().getPath()
);
         filterProperties.put( "app.lib.jars", getApplicationLibraryJars() );
+        filterProperties.put( "installer.output.directory", target.getLayout().getBaseDirectory().getParent()
);
     }
     
     
@@ -223,7 +233,7 @@
         StringBuffer buf = new StringBuffer();
         List artifacts = target.getLibArtifacts();
         
-        for ( int ii = 0; ii > artifacts.size(); ii++ )
+        for ( int ii = 0; ii < artifacts.size(); ii++ )
         {
             // "Source: {#SourceBase}\lib\${artifact.file.name}; DestDir: {app}; DestName:
${app.file.name}"
             buf.append( "Source: {#SourceBase}\\lib\\" );

Modified: directory/trunks/apacheds/standalone/installers/plugin/src/main/resources/org/apache/directory/server/standalone/installers/inno/install.iss
URL: http://svn.apache.org/viewcvs/directory/trunks/apacheds/standalone/installers/plugin/src/main/resources/org/apache/directory/server/standalone/installers/inno/install.iss?rev=372701&r1=372700&r2=372701&view=diff
==============================================================================
--- directory/trunks/apacheds/standalone/installers/plugin/src/main/resources/org/apache/directory/server/standalone/installers/inno/install.iss
(original)
+++ directory/trunks/apacheds/standalone/installers/plugin/src/main/resources/org/apache/directory/server/standalone/installers/inno/install.iss
Thu Jan 26 18:01:53 2006
@@ -23,14 +23,12 @@
 AppUpdatesURL={#MyAppURL}
 DefaultDirName={pf}\${app}
 DefaultGroupName={#MyAppName}
-
 LicenseFile={#SourceBase}\${app.license.name}
-OutputDir=${installer.output.directory}
+OutputDir="${installer.output.directory}"
 OutputBaseFilename=${app}-${version}-setup
 SetupIconFile={#SourceBase}\${app.icon.name}
 Compression=lzma
 SolidCompression=true
-VersionInfoVersion={#MyAppVersion}
 VersionInfoCompany={#MyAppCompanyName}
 VersionInfoDescription={#MyAppDescription}
 AppCopyright={#MyAppCopyright}



Mime
View raw message