felix-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mccu...@apache.org
Subject svn commit: r616677 - /felix/trunk/bundleplugin/src/main/java/org/apache/felix/bundleplugin/ManifestPlugin.java
Date Wed, 30 Jan 2008 08:03:58 GMT
Author: mcculls
Date: Wed Jan 30 00:03:57 2008
New Revision: 616677

URL: http://svn.apache.org/viewvc?rev=616677&view=rev
Log:
FELIX-461: Ensure bundle:manifest goal creates same manifest when project packaging is bundle

Modified:
    felix/trunk/bundleplugin/src/main/java/org/apache/felix/bundleplugin/ManifestPlugin.java

Modified: felix/trunk/bundleplugin/src/main/java/org/apache/felix/bundleplugin/ManifestPlugin.java
URL: http://svn.apache.org/viewvc/felix/trunk/bundleplugin/src/main/java/org/apache/felix/bundleplugin/ManifestPlugin.java?rev=616677&r1=616676&r2=616677&view=diff
==============================================================================
--- felix/trunk/bundleplugin/src/main/java/org/apache/felix/bundleplugin/ManifestPlugin.java
(original)
+++ felix/trunk/bundleplugin/src/main/java/org/apache/felix/bundleplugin/ManifestPlugin.java
Wed Jan 30 00:03:57 2008
@@ -50,7 +50,14 @@
         Manifest manifest;
         try
         {
-            manifest = getManifest( project, instructions, properties, classpath );
+            if ( "bundle".equals( project.getPackaging() ) )
+            {
+                manifest = buildOSGiBundle( project, instructions, properties, classpath
).getJar().getManifest();
+            }
+            else
+            {
+                manifest = getManifest( project, instructions, properties, classpath );
+            }
         }
         catch ( FileNotFoundException e )
         {
@@ -60,6 +67,11 @@
         catch ( IOException e )
         {
             throw new MojoExecutionException( "Error trying to generate Manifest", e );
+        }
+        catch ( Exception e )
+        {
+            getLog().error( "An internal error occurred", e );
+            throw new MojoExecutionException( "Internal error in maven-bundle-plugin", e
);
         }
 
         File outputFile = new File( manifestLocation, "MANIFEST.MF" );



Mime
View raw message