Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBorislav Kapukaranov2011-06-06 00:36:50 -0400
committerBorislav Kapukaranov2011-06-06 00:36:50 -0400
commit28b2d8aa58fd4ed6778de60d6be7ea6f0cc2358d (patch)
tree152775d7bbf84ad5d87eb0e2ca51b8ef36c8bd02
parentd2841e4f98d4443687d83e59a5848ace5802e7f6 (diff)
downloadorg.eclipse.virgo.kernel-28b2d8aa58fd4ed6778de60d6be7ea6f0cc2358d.tar.gz
org.eclipse.virgo.kernel-28b2d8aa58fd4ed6778de60d6be7ea6f0cc2358d.tar.xz
org.eclipse.virgo.kernel-28b2d8aa58fd4ed6778de60d6be7ea6f0cc2358d.zip
bug343543 - Mac OS X startup script fixes
-rwxr-xr-xbuild-kernel/bin/dmk.sh27
-rwxr-xr-xbuild-kernel/bin/setupClasspath.sh16
-rw-r--r--build-kernel/build.xml49
-rw-r--r--org.eclipse.virgo.kernel.build.p2/src/main/java/org/eclipse/virgo/kernel/p2/build/VirgoBuildP2RepoPublisher.java5
4 files changed, 47 insertions, 50 deletions
diff --git a/build-kernel/bin/dmk.sh b/build-kernel/bin/dmk.sh
index 5f8112b1..e8ada5a1 100755
--- a/build-kernel/bin/dmk.sh
+++ b/build-kernel/bin/dmk.sh
@@ -170,19 +170,22 @@ then
$DEBUG_OPTS \
$JMX_OPTS \
-XX:+HeapDumpOnOutOfMemoryError \
- -XX:ErrorFile=$KERNEL_HOME/serviceability/error.log \
- -XX:HeapDumpPath=$KERNEL_HOME/serviceability/heap_dump.hprof \
- -Djava.security.auth.login.config=$CONFIG_DIR/org.eclipse.virgo.kernel.authentication.config \
- -Dorg.eclipse.virgo.kernel.authentication.file=$CONFIG_DIR/org.eclipse.virgo.kernel.users.properties \
- -Djava.io.tmpdir=$TMP_DIR \
- -Dorg.eclipse.virgo.kernel.home=$KERNEL_HOME \
+ -XX:ErrorFile=$KERNEL_HOME/serviceability/error.log \
+ -XX:HeapDumpPath=$KERNEL_HOME/serviceability/heap_dump.hprof \
+ -Djava.security.auth.login.config=$CONFIG_DIR/org.eclipse.virgo.kernel.authentication.config \
+ -Dorg.eclipse.virgo.kernel.authentication.file=$CONFIG_DIR/org.eclipse.virgo.kernel.users.properties \
+ -Djava.io.tmpdir=$TMP_DIR \
+ -Dorg.eclipse.virgo.kernel.home=$KERNEL_HOME \
+ -Declipse.ignoreApp=true \
+ -Dorg.eclipse.virgo.kernel.config=$CONFIG_DIR \
+ -Dosgi.configuration.area=$KERNEL_HOME/work/osgi/configuration \
+ -Dosgi.instance.area=$KERNEL_HOME/work \
+ -Dosgi.install.area=$KERNEL_HOME/lib/kernel \
+ -Dosgi.frameworkClassPath=$FWCLASSPATH \
+ -Dosgi.java.profile="file:$KERNEL_HOME/lib/java6-server.profile" \
-classpath $CLASSPATH \
- org.eclipse.virgo.osgi.launcher.Launcher \
- -config $KERNEL_HOME/lib/org.eclipse.virgo.kernel.launch.properties \
- -Forg.eclipse.virgo.kernel.home=$KERNEL_HOME \
- -Forg.eclipse.virgo.kernel.config=$CONFIG_DIR \
- -Fosgi.configuration.area=$KERNEL_HOME/work/osgi/configuration \
- -Fosgi.java.profile="file:$KERNEL_HOME/lib/java6-server.profile" \
+ org.eclipse.equinox.launcher.Main \
+ -noExit \
$LAUNCH_OPTS \
$ADDITIONAL_ARGS
fi
diff --git a/build-kernel/bin/setupClasspath.sh b/build-kernel/bin/setupClasspath.sh
index 3398df9e..952bf23f 100755
--- a/build-kernel/bin/setupClasspath.sh
+++ b/build-kernel/bin/setupClasspath.sh
@@ -8,6 +8,7 @@ then
fi
CLASSPATH=
+FWCLASSPATH=
# Create the classpath for bootstrapping the Server from all the JARs in lib
for file in $KERNEL_HOME/lib/*
@@ -15,12 +16,27 @@ do
if [[ $file == *.jar ]]
then
CLASSPATH=$CLASSPATH:$KERNEL_HOME/lib/${file##*/}
+ FWCLASSPATH=$FWCLASSPATH,file:$KERNEL_HOME/lib/${file##*/}
fi
done
+# Append the osgi jar to the classpath
+for file in $KERNEL_HOME/lib/kernel/plugins/org.eclipse.osgi_*.jar
+do
+ CLASSPATH=$CLASSPATH:$KERNEL_HOME/lib/kernel/plugins/${file##*/}
+ FWCLASSPATH=$FWCLASSPATH,file:$KERNEL_HOME/lib/kernel/plugins/${file##*/}
+done
+
# make sure we have CLASSPATH set
if [ -z "$CLASSPATH" ]
then
echo No JAR files found in $KERNEL_HOME/lib
exit 1
fi
+
+# make sure we have FWCLASSPATH set
+if [ -z "$FWCLASSPATH" ]
+then
+ echo No JAR files found in $KERNEL_HOME/lib
+ exit 1
+fi
diff --git a/build-kernel/build.xml b/build-kernel/build.xml
index 8590509f..f65df767 100644
--- a/build-kernel/build.xml
+++ b/build-kernel/build.xml
@@ -178,18 +178,6 @@
<copy file="${basedir}/config/keystore" todir="${package.output.dir}/config" failonerror="false"/>
- <chmod perm="600">
- <fileset dir="${package.dir}/zip/config">
- <include name="org.eclipse.virgo.kernel.jmxremote.access.properties"/>
- </fileset>
- </chmod>
-
- <chmod perm="755">
- <fileset dir="${package.dir}/zip/bin">
- <include name="*.sh"/>
- </fileset>
- </chmod>
-
<!-- zip the published Virgo repositories and configuration data -->
<zip destfile="${target.dir}/p2repo/virgo_resources.zip">
<zipfileset dir="${package.dir}/zip"/>
@@ -214,6 +202,18 @@
<sysproperty key="installIU" value="virgo.product"/>
<sysproperty key="profile" value="VIRGO.kernel"/>
</java>
+
+ <chmod perm="600">
+ <fileset dir="${package.output.dir}/config">
+ <include name="org.eclipse.virgo.kernel.jmxremote.access.properties"/>
+ </fileset>
+ </chmod>
+
+ <chmod perm="755">
+ <fileset dir="${package.output.dir}/bin">
+ <include name="*.sh"/>
+ </fileset>
+ </chmod>
<mkdir dir="${artifacts.dir}"/>
<zip destfile="${package.output.file}">
@@ -257,29 +257,4 @@
</zip>
</target>
- <target name="p2.publish" depends="package.resources, p2.extract-publisher"
- description="Publishes bundles, features and product">
- <java jar="${p2.launcher.jar}" fork="true" taskname="p2bundles" failonerror="true" maxmemory="256m">
- <arg line="-application org.eclipse.equinox.p2.publisher.FeaturesAndBundlesPublisher"/>
- <arg line="-metadataRepository ${p2.repo.url}"/>
- <arg line="-artifactRepository ${p2.repo.url}"/>
- <arg line="-bundles ${package.output.dir}/lib,${package.output.dir}/repository/ext"/>
- <arg line="-publishArtifacts"/>
- <arg line="-configs all"/>
- </java>
-
- <sshexec host="build.eclipse.org"
- username="${eclipse.buildId}"
- keyfile="${key.file}"
- passphrase="${passphrase}"
- command="mkdir -pv /opt/public/rt/virgo/update-site/${release.type}/${build.stamp}"/>
-
- <scp todir="${eclipse.buildId}@build.eclipse.org:/opt/public/rt/virgo/update-site/${release.type}/${build.stamp}/"
- keyfile="${key.file}"
- passphrase="${passphrase}">
- <fileset dir="${publishing.dir}"/>
- </scp>
-
- </target>
-
</project>
diff --git a/org.eclipse.virgo.kernel.build.p2/src/main/java/org/eclipse/virgo/kernel/p2/build/VirgoBuildP2RepoPublisher.java b/org.eclipse.virgo.kernel.build.p2/src/main/java/org/eclipse/virgo/kernel/p2/build/VirgoBuildP2RepoPublisher.java
index c2521bd2..500e22dd 100644
--- a/org.eclipse.virgo.kernel.build.p2/src/main/java/org/eclipse/virgo/kernel/p2/build/VirgoBuildP2RepoPublisher.java
+++ b/org.eclipse.virgo.kernel.build.p2/src/main/java/org/eclipse/virgo/kernel/p2/build/VirgoBuildP2RepoPublisher.java
@@ -180,7 +180,10 @@ public class VirgoBuildP2RepoPublisher {
private String createAgentInstallLocation(String installLocation) {
// this is done to avoid 'URI not hierarchical' issue as the ProvisioningAgentProvider accepts hierarchical URIs
- String agentInstallLocation = "file:/" + installLocation;
+ if (!installLocation.startsWith("/")) {
+ installLocation = "/" + installLocation;
+ }
+ String agentInstallLocation = "file:" + installLocation;
agentInstallLocation = agentInstallLocation + TARGET_LOCATION_OFFSET + P2_FOLDER;
return agentInstallLocation;
}

Back to the top