FELIX-1111: allow karaf to run on equinox
git-svn-id: https://svn.apache.org/repos/asf/felix/trunk@771836 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/karaf/assembly/src/main/descriptors/unix-bin.xml b/karaf/assembly/src/main/descriptors/unix-bin.xml
index 5363a46..c802940 100644
--- a/karaf/assembly/src/main/descriptors/unix-bin.xml
+++ b/karaf/assembly/src/main/descriptors/unix-bin.xml
@@ -124,6 +124,7 @@
<include>org.apache.felix:org.osgi.compendium</include>
<include>org.apache.felix:org.apache.felix.configadmin</include>
<include>org.apache.felix:org.apache.felix.prefs</include>
+ <include>org.apache.felix:org.apache.felix.framework</include>
</includes>
</dependencySet>
<dependencySet>
@@ -287,6 +288,15 @@
<include>com.oracle.osgi:jmx-impl</include>
</includes>
</dependencySet>
+ <dependencySet>
+ <outputDirectory>/system</outputDirectory>
+ <unpack>false</unpack>
+ <useProjectArtifact>false</useProjectArtifact>
+ <outputFileNameMapping>org/eclipse/${artifact.artifactId}/${artifact.baseVersion}/${artifact.artifactId}-${artifact.baseVersion}${dashClassifier?}.${artifact.extension}</outputFileNameMapping>
+ <includes>
+ <include>org.eclipse:osgi</include>
+ </includes>
+ </dependencySet>
</dependencySets>
diff --git a/karaf/assembly/src/main/descriptors/windows-bin.xml b/karaf/assembly/src/main/descriptors/windows-bin.xml
index 59e1068..d920cb9 100644
--- a/karaf/assembly/src/main/descriptors/windows-bin.xml
+++ b/karaf/assembly/src/main/descriptors/windows-bin.xml
@@ -116,6 +116,7 @@
<include>org.apache.felix:org.osgi.compendium</include>
<include>org.apache.felix:org.apache.felix.configadmin</include>
<include>org.apache.felix:org.apache.felix.prefs</include>
+ <include>org.apache.felix:org.apache.felix.framework</include>
</includes>
</dependencySet>
<dependencySet>
@@ -279,6 +280,15 @@
<include>com.oracle.osgi:jmx-impl</include>
</includes>
</dependencySet>
+ <dependencySet>
+ <outputDirectory>/system</outputDirectory>
+ <unpack>false</unpack>
+ <useProjectArtifact>false</useProjectArtifact>
+ <outputFileNameMapping>org/eclipse/${artifact.artifactId}/${artifact.baseVersion}/${artifact.artifactId}-${artifact.baseVersion}${dashClassifier?}.${artifact.extension}</outputFileNameMapping>
+ <includes>
+ <include>org.eclipse:osgi</include>
+ </includes>
+ </dependencySet>
</dependencySets>
diff --git a/karaf/assembly/src/main/distribution/unix-shell/bin/karaf b/karaf/assembly/src/main/distribution/unix-shell/bin/karaf
index 4016399..e58b22b 100755
--- a/karaf/assembly/src/main/distribution/unix-shell/bin/karaf
+++ b/karaf/assembly/src/main/distribution/unix-shell/bin/karaf
@@ -281,7 +281,7 @@
KARAF_HOME=`cygpath --path --windows "$KARAF_HOME"`
KARAF_BASE=`cygpath --path --windows "$KARAF_BASE"`
fi
- exec $JAVA $JAVA_OPTS -Dkaraf.home="$KARAF_HOME" -Dkaraf.base="$KARAF_BASE" -Djava.util.logging.config.file=$KARAF_BASE/etc/java.util.logging.properties $OPTS -classpath "$CLASSPATH" org.apache.felix.karaf.main.Main $*
+ exec $JAVA $JAVA_OPTS -Dkaraf.home="$KARAF_HOME" -Dkaraf.base="$KARAF_BASE" -Djava.util.logging.config.file=$KARAF_BASE/etc/java.util.logging.properties $OPTS -classpath "$CLASSPATH" org.apache.felix.karaf.main.Bootstrap $*
}
main() {
diff --git a/karaf/assembly/src/main/distribution/windows-text/bin/karaf.bat b/karaf/assembly/src/main/distribution/windows-text/bin/karaf.bat
index 189dd1c..8f62396 100755
--- a/karaf/assembly/src/main/distribution/windows-text/bin/karaf.bat
+++ b/karaf/assembly/src/main/distribution/windows-text/bin/karaf.bat
@@ -152,7 +152,7 @@
if "%SHIFT%" == "true" SET ARGS=%2 %3 %4 %5 %6 %7 %8
if not "%SHIFT%" == "true" SET ARGS=%1 %2 %3 %4 %5 %6 %7 %8
rem Execute the Java Virtual Machine
- "%JAVA%" %JAVA_OPTS% %OPTS% -classpath "%CLASSPATH%" -Dkaraf.home="%KARAF_HOME%" -Dkaraf.base="%KARAF_BASE%" -Djava.util.logging.config.file=%KARAF_BASE%\etc\java.util.logging.properties org.apache.felix.karaf.main.Main %ARGS%
+ "%JAVA%" %JAVA_OPTS% %OPTS% -classpath "%CLASSPATH%" -Dkaraf.home="%KARAF_HOME%" -Dkaraf.base="%KARAF_BASE%" -Djava.util.logging.config.file=%KARAF_BASE%\etc\java.util.logging.properties org.apache.felix.karaf.main.Bootstrap %ARGS%
rem # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
diff --git a/karaf/assembly/src/main/filtered-resources/etc/config.properties b/karaf/assembly/src/main/filtered-resources/etc/config.properties
index dbe5629..89ffff5 100644
--- a/karaf/assembly/src/main/filtered-resources/etc/config.properties
+++ b/karaf/assembly/src/main/filtered-resources/etc/config.properties
@@ -18,6 +18,14 @@
################################################################################
#
+# Framework selection properties
+#
+karaf.framework=equinox
+
+karaf.framework.equinox=system/org/eclipse/osgi/${equinox.version}/osgi-${equinox.version}.jar
+karaf.framework.felix=system/org/apache/felix/org.apache.felix.framework/${felix.framework.version}/org.apache.felix.framework-${felix.framework.version}.jar
+
+#
# Framework config properties.
#
org.osgi.framework.system.packages=org.osgi.framework; version=1.4.0, \
@@ -26,7 +34,6 @@
org.osgi.service.startlevel; version=1.1.0, \
org.osgi.service.url; version=1.0.0, \
org.osgi.util.tracker; version=1.3.3, \
- org.apache.felix.karaf.main.spi; version=${karaf.osgi.version}, \
org.apache.felix.karaf.jaas.boot; version=${karaf.osgi.version}, \
org.apache.felix.karaf.version; version=${karaf.osgi.version}, \
${jre-${java.specification.version}}