Integrate OSGi boot
authorMathieu Baudier <mbaudier@argeo.org>
Mon, 14 Sep 2009 08:09:25 +0000 (08:09 +0000)
committerMathieu Baudier <mbaudier@argeo.org>
Mon, 14 Sep 2009 08:09:25 +0000 (08:09 +0000)
git-svn-id: https://svn.argeo.org/commons/trunk@2900 4cfe0d0a-d680-48aa-b62c-e0a02a3f76cc

osgi/pom.xml [new file with mode: 0644]
osgi/runtime/org.argeo.osgi.boot/.project
osgi/runtime/org.argeo.osgi.boot/pom.xml
osgi/runtime/org.argeo.osgi.boot/src/assembly/osgiboot.xml [deleted file]
osgi/runtime/org.argeo.osgi.boot/src/main/ant/osgiboot.xml [deleted file]
osgi/runtime/pom.xml [new file with mode: 0644]

diff --git a/osgi/pom.xml b/osgi/pom.xml
new file mode 100644 (file)
index 0000000..caaed4d
--- /dev/null
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+       xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+       <modelVersion>4.0.0</modelVersion>
+       <parent>
+               <groupId>org.argeo.commons</groupId>
+               <version>0.1.1-SNAPSHOT</version>
+               <artifactId>argeo-commons</artifactId>
+               <relativePath>..</relativePath>
+       </parent>
+       <artifactId>osgi</artifactId>
+       <name>Commons OSGi</name>
+       <packaging>pom</packaging>
+       <modules>
+               <module>runtime</module>
+       </modules>
+</project>
\ No newline at end of file
index 5a646e1b0276ea3553dd6021fd534ffd6271230b..16a9c13f03a8453ab698c2369c410921fa095908 100644 (file)
@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <projectDescription>
-       <name>org.argeo.slc.osgiboot</name>
+       <name>org.argeo.osgi.boot</name>
        <comment></comment>
        <projects>
        </projects>
index 95b18640a81e2ff936f96c372463539398425971..a4e4b9cdab2b779ddc05ef512d8197a80b239301 100644 (file)
@@ -1,15 +1,14 @@
 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
        <modelVersion>4.0.0</modelVersion>
        <parent>
-               <groupId>org.argeo.slc</groupId>
+               <groupId>org.argeo.commons.osgi</groupId>
+               <version>0.1.1-SNAPSHOT</version>
                <artifactId>runtime</artifactId>
-               <version>0.12.1-SNAPSHOT</version>
                <relativePath>..</relativePath>
        </parent>
-       <groupId>org.argeo.slc.runtime</groupId>
-       <artifactId>org.argeo.slc.osgiboot</artifactId>
+       <artifactId>org.argeo.osgi.boot</artifactId>
        <packaging>jar</packaging>
-       <name>SLC OSGi Boot</name>
+       <name>Commons OSGi Boot</name>
        <build>
                <plugins>
                        <plugin>
                                <groupId>org.apache.maven.plugins</groupId>
                                <artifactId>maven-surefire-plugin</artifactId>
                        </plugin>
-                       <!-- 
-                       <plugin>
-                               <groupId>org.apache.maven.plugins</groupId>
-                               <artifactId>maven-assembly-plugin</artifactId>
-                               <configuration>
-                                       <descriptors>
-                                               <descriptor>src/assembly/osgiboot.xml</descriptor>
-                                       </descriptors>
-                               </configuration>
-                               <executions>
-                                       <execution>
-                                               <id>assembly-osgiboot</id>
-                                               <phase>package</phase>
-                                               <goals>
-                                                       <goal>single</goal>
-                                               </goals>
-                                       </execution>
-                               </executions>
-                       </plugin>
-                        -->
                        <plugin>
                                <groupId>org.apache.felix</groupId>
                                <artifactId>maven-bundle-plugin</artifactId>
                                        </instructions>
                                </configuration>
                        </plugin>
-                       <!-- 
-                       <plugin>
-                               <groupId>org.codehaus.mojo</groupId>
-                               <artifactId>build-helper-maven-plugin</artifactId>
-                               <version>1.1</version>
-                               <executions>
-                                       <execution>
-                                               <id>attach-artifacts</id>
-                                               <phase>package</phase>
-                                               <goals>
-                                                       <goal>attach-artifact</goal>
-                                               </goals>
-                                               <configuration>
-                                                       <artifacts>
-                                                               <artifact>
-                                                                       <file>src/main/ant/osgiboot.xml</file>
-                                                                       <type>xml</type>
-                                                                       <classifier>osgiboot</classifier>
-                                                               </artifact>
-                                                       </artifacts>
-                                               </configuration>
-                                       </execution>
-                               </executions>
-                       </plugin>
- -->
                </plugins>
        </build>
        <dependencies>
diff --git a/osgi/runtime/org.argeo.osgi.boot/src/assembly/osgiboot.xml b/osgi/runtime/org.argeo.osgi.boot/src/assembly/osgiboot.xml
deleted file mode 100644 (file)
index f7df1eb..0000000
+++ /dev/null
@@ -1,35 +0,0 @@
-<assembly xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-       xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/assembly-1.1.0-SNAPSHOT.xsd">
-       <id>osgiboot</id>
-       <includeBaseDirectory>false</includeBaseDirectory>
-       <formats>
-               <format>tar.gz</format>
-       </formats>
-       <files>
-               <file>
-                       <source>target/${project.artifactId}-${project.version}.jar
-                       </source>
-                       <outputDirectory></outputDirectory>
-                       <destName>${project.artifactId}.jar
-                       </destName>
-               </file>
-       </files>
-       <fileSets>
-               <fileSet>
-                       <directory>src/main/ant</directory>
-                       <outputDirectory></outputDirectory>
-               </fileSet>
-       </fileSets>
-       <dependencySets>
-               <dependencySet>
-                       <unpack>false</unpack>
-                       <outputDirectory></outputDirectory>
-                       <outputFileNameMapping>org.eclipse.osgi.jar
-                       </outputFileNameMapping>
-                       <includes>
-                               <include>org.eclipse.osgi:org.eclipse.osgi:jar
-                               </include>
-                       </includes>
-               </dependencySet>
-       </dependencySets>
-</assembly>
\ No newline at end of file
diff --git a/osgi/runtime/org.argeo.osgi.boot/src/main/ant/osgiboot.xml b/osgi/runtime/org.argeo.osgi.boot/src/main/ant/osgiboot.xml
deleted file mode 100644 (file)
index 0abc7bf..0000000
+++ /dev/null
@@ -1,99 +0,0 @@
-<project default="launch">
-       <dirname property="baseDir" file="${ant.file}" />
-       <dirname property="equinoxDir" file="${ant.file}" />
-       <property name="equinoxJar" location="${equinoxDir}/org.eclipse.osgi.jar" />
-       <property name="equinoxArgs" value="-console -clean -noExit" />
-       <property name="osgiBootBundle" value="org.argeo.slc.osgiboot.jar" />
-       <property name="configurationDir" location="${equinoxDir}/configuration" />
-       <property name="configurationFile" location="${configurationDir}/config.ini" />
-
-       <path id="slc.osgi.locations.raw.default">
-               <fileset dir="${baseDir}/lib">
-                       <include name="*.jar" />
-               </fileset>
-       </path>
-
-       <target name="launch" description="Launch Equinox" depends="prepareDefault,writeConfiguration,start">
-
-       </target>
-
-       <target name="prepareDefault" unless="slc.osgi.locations">
-               <pathconvert dirsep="/" property="slc.osgi.locations" refid="slc.osgi.locations.raw.default" />
-
-               <property name="slc.osgi.start" value="org.springframework.osgi.extender" />
-       </target>
-
-       <target name="writeConfiguration" description="Generate configuration based on properties">
-               <echo message="equinoxJar=${equinoxJar}" />
-               <echo message="configurationDir=${configurationDir}" />
-               <mkdir dir="${configurationDir}" />
-               <echo message="osgiBootBundle=${osgiBootBundle}" />
-               <echo file="${configurationFile}">
-                       <![CDATA[
-osgi.bundles=reference:file:${osgiBootBundle}@start
-]]>
-               </echo>
-
-               <addProperty name="slc.osgi.locations" />
-               <addProperty name="slc.osgi.start" />
-               <addProperty name="slc.osgi.bundles" />
-               <addProperty name="slc.osgi.devBases" />
-               <addProperty name="slc.osgi.devPatterns" />
-               <addProperty name="slc.maven.dependencyFile" />
-       </target>
-
-       <target name="start.java" description="Start Equinox runtime based on generated config">
-               <java classname="org.eclipse.core.runtime.adaptor.EclipseStarter" fork="true" dir="${equinoxDir}" classpath="${equinoxJar}">
-                       <arg value="-console" />
-                       <arg value="-noExit" />
-                       <arg value="-clean" />
-                       <arg value="-debug" />
-                       <arg value="-configuration" />
-                       <arg value="${configurationDir}" />
-               </java>
-       </target>
-
-       <target name="start">
-               <property name="commandArgs" value="-cp ${equinoxJar} org.eclipse.core.runtime.adaptor.EclipseStarter ${equinoxArgs} -configuration ${configurationDir}" />
-
-               <condition property="starter" value="gnome-terminal">
-                       <and>
-                               <os family="unix" />
-                       </and>
-               </condition>
-               <condition property="starterArgs" value="--maximize -x">
-                       <and>
-                               <os family="unix" />
-                       </and>
-               </condition>
-               <condition property="starter" value="start">
-                       <os family="windows" />
-               </condition>
-               <condition property="vmlauncher" value="false">
-                       <os family="windows" />
-               </condition>
-               <property name="starterArgs" value="" />
-               <property name="javaCommand" value="java" />
-               <property name="vmlauncher" value="true" />
-
-               <echo message="commandArgs=${commandArgs}" />
-               <echo message="${javaCommand} ${commandArgs}" file="${equinoxDir}/launch.bat" />
-               <echo message="${javaCommand} ${commandArgs}" file="${equinoxDir}/launch.sh" />
-               <exec executable="${starter}" dir="${equinoxDir}" vmlauncher="${vmlauncher}">
-                       <arg line="${starterArgs}" />
-                       <arg line="${javaCommand}" />
-                       <arg line="${commandArgs}" />
-               </exec>
-       </target>
-
-       <macrodef name="addProperty">
-               <attribute name="name" />
-               <sequential>
-                       <property name="@{name}" value="" />
-                       <echo message="@{name}=${@{name}}" />
-                       <echo file="${configurationFile}" append="true">
-                               <![CDATA[@{name}=${@{name}}]]>
-                       </echo>
-               </sequential>
-       </macrodef>
-</project>
\ No newline at end of file
diff --git a/osgi/runtime/pom.xml b/osgi/runtime/pom.xml
new file mode 100644 (file)
index 0000000..9ef5fa3
--- /dev/null
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+       xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+       <modelVersion>4.0.0</modelVersion>
+       <parent>
+               <groupId>org.argeo.commons</groupId>
+               <version>0.1.1-SNAPSHOT</version>
+               <artifactId>osgi</artifactId>
+               <relativePath>..</relativePath>
+       </parent>
+       <groupId>org.argeo.commons.osgi</groupId>
+       <artifactId>runtime</artifactId>
+       <name>Commons OSGi Runtime</name>
+       <packaging>pom</packaging>
+       <modules>
+               <module>org.argeo.osgi.boot</module>
+       </modules>
+</project>
\ No newline at end of file