- Use equinox initializer instead of old patch to core.runtime.

- Run initializer *after* splitting install into arch-specific and
    arch-independent locations.
This commit is contained in:
Andrew Overholt 2006-11-02 00:55:15 +00:00
parent 922cad0593
commit 32f425fade
3 changed files with 78 additions and 29 deletions

View File

@ -1,3 +1,4 @@
icu4jsrc_3_4_5.jar
eclipse-sourceBuild-srcIncluded-3.2.1.zip
eclipse-fedora-splash-3.2.1.png
eclipse-fileinitializerapp.tar.bz2

View File

@ -6,7 +6,7 @@
Epoch: 1
%define gcj_support 1
%define gcj_support 0
%define tomcatsharedir %{_datadir}/tomcat5
%define tomcatlibdir %{_var}/lib/tomcat5
%define section free
@ -39,7 +39,12 @@ Source11: %{name}-fedora-splash-3.2.1.png
Source16: %{name}-copy-platform.sh
Source17: efj.sh.in
Source18: ecj.sh.in
# https://bugs.eclipse.org/bugs/show_bug.cgi?id=90535
Source19: %{name}-filenamepatterns.txt
# cvs -d :pserver:anonymous@dev.eclipse.org:/cvsroot/eclipse co equinox-incubator/org.eclipse.equinox.initializer
# tar cjf eclipse-fileinitializerapp.tar.bz2 equinox-incubator/
# (generated 2006-11-01 18:48 UTC)
Source20: %{name}-fileinitializerapp.tar.bz2
# Build libswt-mozilla and libswt-cairo and use O2
@ -88,8 +93,6 @@ Patch31: %{name}-webapp-tomcat55.patch
# https://bugs.eclipse.org/bugs/show_bug.cgi?id=98707
# https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=178726
Patch33: %{name}-compare-create-api.patch
# https://bugs.eclipse.org/bugs/show_bug.cgi?id=90535
Patch24: %{name}-fileinitializer.patch
# https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=191536
# https://bugs.eclipse.org/bugs/show_bug.cgi?id=142861
Patch54: %{name}-swt-rm-ON_TOP.patch
@ -384,9 +387,6 @@ pushd plugins/org.eclipse.swt.gtk.linux.x86_64
%patch18 -p0
popd
%patch22 -p0
pushd plugins/org.eclipse.core.runtime
%patch24 -p0
popd
# tomcat patches
pushd plugins/org.eclipse.tomcat
@ -762,6 +762,8 @@ if [ ! -z "$JARS" ]; then
#FIXME: enable exit 1
fi
tar jxf %{SOURCE20}
%build
env
ORIGCLASSPATH=$CLASSPATH
@ -901,6 +903,35 @@ ant \
#./copyallsrc $src_root/org.eclipse.swt/Eclipse\ SWT/gtk/org
#popd
# Build the FileInitializer application
SDK=$(cd eclipse && pwd)
PDEPLUGINVERSION=$(ls $SDK/plugins | grep pde.build | sed 's/org.eclipse.pde.build_//')
pushd equinox-incubator
mkdir -p build
mkdir -p home
homedir=$(cd home && pwd)
echo "<project default=\"main\"><target name=\"main\"></target></project>" > build/assemble.org.eclipse.equinox.initializer.all.xml
echo "<project default=\"main\"><target name=\"main\"></target></project>" > build/package.org.eclipse.equinox.initializer.all.xml
$SDK/eclipse \
-Duser.home=$homedir \
-application org.eclipse.ant.core.antRunner \
-Dtype=plugin \
-Did=org.eclipse.equinox.initializer \
-DsourceDirectory=$(pwd) \
-DbaseLocation=$SDK \
-Dbuilder=$SDK/plugins/org.eclipse.pde.build_$PDEPLUGINVERSION/templates/package-build \
-f $SDK/plugins/org.eclipse.pde.build_$PDEPLUGINVERSION/scripts/build.xml
pushd build/plugins/org.eclipse.equinox.initializer
$SDK/eclipse \
-Duser.home=$homedir \
-application org.eclipse.ant.core.antRunner \
-f build.xml build.update.jar
popd
popd
%install
rm -rf $RPM_BUILD_ROOT
@ -913,40 +944,51 @@ SWT_VERSION=$SWT_MAJ_VER$SWT_MIN_VER
install -d -m 755 $RPM_BUILD_ROOT%{_datadir}/%{name}
tar -C $RPM_BUILD_ROOT%{_datadir} -zxf result/linux-gtk-%{eclipse_arch}-sdk.tar.gz
# FIXME: investigate why it doesn't work to set this -- configuration data is
# always written to /usr/share/eclipse/configuration
# -Dosgi.sharedConfiguration.area=$RPM_BUILD_ROOT%{_libdir}/%{name}/configuration \
# Extract .so files
# https://bugs.eclipse.org/bugs/show_bug.cgi?id=90535
pushd $RPM_BUILD_ROOT%{_datadir}/%{name}
java -cp startup.jar \
org.eclipse.core.launcher.Main \
-consolelog \
-application org.eclipse.core.runtime.initializer \
-fileInitializer %{SOURCE19}
popd
cp equinox-incubator/org.eclipse.equinox.initializer/org.eclipse.equinox.initializer_*.jar \
$RPM_BUILD_ROOT%{_datadir}/%{name}/plugins
# Install config.ini to an arch dependant location and remomve the unnecessary
# configuration data
install -d -m 755 $RPM_BUILD_ROOT%{_libdir}/%{name}
mv $RPM_BUILD_ROOT%{_datadir}/%{name}/configuration $RPM_BUILD_ROOT%{_libdir}/%{name}
rm -r $RPM_BUILD_ROOT%{_libdir}/%{name}/configuration/org.eclipse.update
rm -r $RPM_BUILD_ROOT%{_libdir}/%{name}/configuration/org.eclipse.core.runtime
rm -r $RPM_BUILD_ROOT%{_libdir}/%{name}/configuration/*.log
# Set config.ini for the rcp package, the lowest package in the dependancy chain.
sed --in-place "s/eclipse.product=org.eclipse.sdk.ide/#eclipse.product=/" \
$RPM_BUILD_ROOT%{_libdir}/%{name}/configuration/config.ini
# Install the platform specific fragments in an arch specific dir
install -d -m 755 $RPM_BUILD_ROOT%{_datadir}/%{name}/links
echo "path:%{_libdir}" > $RPM_BUILD_ROOT%{_datadir}/%{name}/links/fragments.link
echo "path:$RPM_BUILD_ROOT%{_libdir}" > $RPM_BUILD_ROOT%{_datadir}/%{name}/links/fragments.link
echo "name=Eclipse Platform" > $RPM_BUILD_ROOT%{_libdir}/%{name}/.eclipseextension
echo "id=org.eclipse.platform" >> $RPM_BUILD_ROOT%{_libdir}/%{name}/.eclipseextension
echo "version=%{eclipse_majmin}.%{eclipse_micro}" >> $RPM_BUILD_ROOT%{_libdir}/%{name}/.eclipseextension
install -d -m 755 $RPM_BUILD_ROOT%{_libdir}/%{name}/plugins
mv $RPM_BUILD_ROOT%{_datadir}/%{name}/plugins/*%{eclipse_arch}* $RPM_BUILD_ROOT%{_libdir}/%{name}/plugins
mkdir -p home
homedir=$(cd home && pwd)
# FIXME: investigate why it doesn't work to set this -- configuration data is
# always written to /usr/share/eclipse/configuration
# -Dosgi.sharedConfiguration.area=$RPM_BUILD_ROOT%{_libdir}/%{name}/configuration \
# Extract .so files
# https://bugs.eclipse.org/bugs/show_bug.cgi?id=90535
pushd $RPM_BUILD_ROOT
datadir_path=$(echo %{_datadir}/%{name} | sed -e 's/^\///')
libdir_path=$(echo %{_libdir}/%{name} | sed -e 's/^\///')
java -Dosgi.sharedConfiguration.area=$libdir_path/configuration \
-cp $datadir_path/startup.jar \
org.eclipse.core.launcher.Main \
-consolelog \
-application org.eclipse.equinox.initializer.configInitializer \
-fileInitializer %{SOURCE19}
popd
# Install config.ini to an arch dependent location and remove the unnecessary
# configuration data
mv $RPM_BUILD_ROOT%{_datadir}/%{name}/configuration $RPM_BUILD_ROOT%{_libdir}/%{name}
rm -r $RPM_BUILD_ROOT%{_libdir}/%{name}/configuration/org.eclipse.update
rm -r $RPM_BUILD_ROOT%{_libdir}/%{name}/configuration/org.eclipse.core.runtime
# Where did these go?
#rm -r $RPM_BUILD_ROOT%{_libdir}/%{name}/configuration/*.log
# Set config.ini for the rcp package, the lowest package in the dependancy chain.
sed --in-place "s/eclipse.product=org.eclipse.sdk.ide/#eclipse.product=/" \
$RPM_BUILD_ROOT%{_libdir}/%{name}/configuration/config.ini
# Install the Eclipse binary
install -d -m 755 $RPM_BUILD_ROOT%{_bindir}
mv $RPM_BUILD_ROOT%{_datadir}/%{name}/eclipse $RPM_BUILD_ROOT%{_bindir}/%{name}
@ -1618,6 +1660,11 @@ rm -f %{_datadir}/%{name}/configuration/org.eclipse.update/platform.xml*
%{_datadir}/%{name}/plugins/org.eclipse.sdk_*
%changelog
* Wed Nov 01 2006 Andrew Overholt <overholt@redhat.com> 3.2.1-12
- Use equinox initializer instead of old patch to core.runtime.
- Run initializer *after* splitting install into arch-specific and
arch-independent locations.
* Tue Oct 31 2006 Andrew Overholt <overholt@redhat.com> 3.2.1-11
- Fix copy-platform to work with split install.

View File

@ -1,3 +1,4 @@
c3be75d8af3c31b7a1748247ab3fee95 icu4jsrc_3_4_5.jar
0fe89e9c7cf07a56c4fe8e2d7f5a394b eclipse-sourceBuild-srcIncluded-3.2.1.zip
627db0c5033547a48370a5e45a89d2f1 eclipse-fedora-splash-3.2.1.png
e1313563c7e36aa46e33789a1386b815 eclipse-fileinitializerapp.tar.bz2