- Enable s390 and s390x.

- Add small snippet to check for jars at the end of prep.
This commit is contained in:
Ben Konrath 2006-06-08 18:47:33 +00:00
parent 3321426573
commit 55460d965c

View File

@ -16,8 +16,6 @@ Epoch: 1
%define eclipse_majmin %{eclipse_major}.%{eclipse_minor}
%define eclipse_micro 0
%define libname libswt3
# FIXME do we need this?
%define build_id I20051206-0800
# All arches line up except i386 -> x86
%ifarch %{ix86}
@ -38,7 +36,7 @@ Epoch: 1
Summary: %{pkg_summary}
Name: eclipse
Version: %{eclipse_majmin}.%{eclipse_micro}
Release: 0jpp_0fc.3.2RC7.2
Release: 0jpp_0fc.3.2RC7.3
License: EPL
Group: Text Editors/Integrated Development Environments (IDE)
URL: http://www.eclipse.org/
@ -73,12 +71,6 @@ Patch0: %{name}-libswt-enableallandO2.patch
Patch2: %{name}-build.patch
Patch4: %{name}-libupdatebuild.patch
Patch5: %{name}-libupdatebuild2.patch
# We can't really commit to doing builds for these arches upstream, but we
# need at least eclipse-ecj to run on them as it's our bytecode compiler for
# Fedora.
Patch13: %{name}-s390ands390x.patch
# Stupid spaces in directories ...
Patch14: %{name}-s390ands390x2.patch
# Build swttools.jar
# https://bugs.eclipse.org/bugs/show_bug.cgi?id=90364
Patch18: %{name}-swttools.patch
@ -142,7 +134,6 @@ Patch101: org.eclipse.platform.doc.isv-rm-org.eclipse.ui.workbench-Eclipse-UI-Co
%if %{gcj_support}
ExcludeArch: s390 s390x ppc64
%else
ExclusiveArch: %{ix86} x86_64 ppc ia64
%endif
@ -173,16 +164,20 @@ BuildRequires: dos2unix
BuildRequires: java-devel >= 1.4.2
%endif
BuildRequires: ant-antlr ant-apache-bcel ant-apache-bsf ant-apache-log4j ant-apache-oro ant-apache-regexp ant-apache-resolver ant-commons-logging
#BuildRequires: ant-antlr ant-apache-bcel ant-apache-bsf ant-apache-log4j ant-apache-oro ant-apache-regexp ant-apache-resolver ant-commons-logging
BuildRequires: ant-antlr ant-apache-bcel ant-apache-log4j ant-apache-oro ant-apache-regexp ant-apache-resolver ant-commons-logging
# https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=180642
#BuildRequires: ant-commons-net
BuildRequires: ant-javamail ant-jdepend ant-junit ant-nodeps ant-swing ant-trax ant-jsch
BuildRequires: jsch >= 0:0.1.28-1jpp
#FIXME
%ifnarch ppc64 s390 s390x
BuildRequires: jakarta-commons-beanutils jakarta-commons-collections jakarta-commons-digester jakarta-commons-dbcp jakarta-commons-el jakarta-commons-fileupload jakarta-commons-launcher jakarta-commons-logging jakarta-commons-modeler jakarta-commons-pool
BuildRequires: mx4j >= 2.1
BuildRequires: tomcat5 >= 5.5.15
BuildRequires: tomcat5-jasper >= 5.5.15
BuildRequires: tomcat5-servlet-2.4-api >= 5.5.15
%endif
BuildRequires: lucene
BuildRequires: regexp
BuildRequires: junit >= 3.8.1-3jpp
@ -238,15 +233,19 @@ Requires: /usr/bin/mozilla
BuildRequires: gtk2 >= 2.6
Requires: gtk2 >= 2.6
Requires: ant-antlr ant-apache-bcel ant-apache-bsf ant-apache-log4j ant-apache-oro ant-apache-regexp ant-apache-resolver ant-commons-logging
Requires: ant-antlr ant-apache-bcel ant-apache-log4j ant-apache-oro ant-apache-regexp ant-apache-resolver ant-commons-logging
#Requires: ant-antlr ant-apache-bcel ant-apache-bsf ant-apache-log4j ant-apache-oro ant-apache-regexp ant-apache-resolver ant-commons-logging
# https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=180642
#Requires: ant-commons-net
Requires: ant-javamail ant-jdepend ant-junit ant-nodeps ant-swing ant-trax ant-jsch
#FIXME
%ifnarch ppc64 s390 s390x
Requires: jakarta-commons-beanutils jakarta-commons-collections jakarta-commons-digester jakarta-commons-dbcp jakarta-commons-el jakarta-commons-fileupload jakarta-commons-launcher jakarta-commons-logging jakarta-commons-modeler jakarta-commons-pool
Requires: mx4j >= 2.1
Requires: tomcat5 >= 5.5.15
Requires: tomcat5-jasper >= 5.5.15
Requires: tomcat5-servlet-2.4-api >= 5.5.15
%endif
Requires: lucene
Requires: regexp
@ -489,8 +488,8 @@ rm plugins/org.apache.ant/lib/ant-antlr.jar
rm plugins/org.apache.ant/lib/ant-antlrsrc.zip
rm plugins/org.apache.ant/lib/ant-apache-bcel.jar
rm plugins/org.apache.ant/lib/ant-apache-bcelsrc.zip
rm plugins/org.apache.ant/lib/ant-apache-bsf.jar
rm plugins/org.apache.ant/lib/ant-apache-bsfsrc.zip
#rm plugins/org.apache.ant/lib/ant-apache-bsf.jar
#rm plugins/org.apache.ant/lib/ant-apache-bsfsrc.zip
rm plugins/org.apache.ant/lib/ant-apache-log4j.jar
rm plugins/org.apache.ant/lib/ant-apache-log4jsrc.zip
rm plugins/org.apache.ant/lib/ant-apache-oro.jar
@ -544,7 +543,7 @@ rm plugins/org.apache.ant/lib/ant-xslpsrc.zip
# FIXME use build-jar-repository
ln -s %{_javadir}/ant/ant-antlr.jar plugins/org.apache.ant/lib/ant-antlr.jar
ln -s %{_javadir}/ant/ant-apache-bcel.jar plugins/org.apache.ant/lib/ant-apache-bcel.jar
ln -s %{_javadir}/ant/ant-apache-bsf.jar plugins/org.apache.ant/lib/ant-apache-bsf.jar
#ln -s %{_javadir}/ant/ant-apache-bsf.jar plugins/org.apache.ant/lib/ant-apache-bsf.jar
ln -s %{_javadir}/ant/ant-apache-log4j.jar plugins/org.apache.ant/lib/ant-apache-log4j.jar
ln -s %{_javadir}/ant/ant-apache-oro.jar plugins/org.apache.ant/lib/ant-apache-oro.jar
ln -s %{_javadir}/ant/ant-apache-regexp.jar plugins/org.apache.ant/lib/ant-apache-regexp.jar
@ -580,18 +579,15 @@ rm plugins/org.apache.lucene/lucene-1.4.3.jar
rm plugins/org.apache.lucene/lucene-1.4.3-src.zip
ln -s %{_javadir}/lucene.jar plugins/org.apache.lucene/lucene-1.4.3.jar
# END LUCENE ##
# setup the jsch plugin build
rm plugins/org.eclipse.team.cvs.ssh2/com.jcraft.jsch_*.jar
# FIXME remove version number
pushd baseLocation/plugins
unzip -qq -d tmp %{_javadir}/jsch.jar
unzip -qq -o -d tmp com.jcraft.jsch_*.jar -x com\*
unzip -qq -o -d com.jcraft.jsch_0.1.28.jar-build com.jcraft.jsch_*.jar -x com\*
rm com.jcraft.jsch_*.jar
pushd tmp
sed --in-place "s/$(grep Created-By: META-INF/MANIFEST.MF)/Created-By: $(jar -V | head -1)/" META-INF/MANIFEST.MF
jar -cf ../com.jcraft.jsch_0.1.28.jar *
popd
rm -r tmp
popd
#ln -s %{_javadir}/jsch.jar plugins/org.eclipse.team.cvs.ssh2/com.jcraft.jsch_0.1.28.jar
## BEGIN TOMCAT ##
#rm plugins/org.eclipse.tomcat/commons-beanutils.jar
#rm plugins/org.eclipse.tomcat/commons-collections.jar
@ -644,30 +640,59 @@ pushd plugins/org.eclipse.swt/Eclipse\ SWT\ PI/gtk/library
sed --in-place "s:/usr/lib/:%{_libdir}/:g" build.sh
sed --in-place "s:-L\$(AWT_LIB_PATH):-L%{_jvmdir}/java/jre/lib/%{_arch}:" make_linux.mak
popd
exit 1
# nasty hack to get suppport for pcc64, s390 and s390x
# we're basically just replacing the arch
%ifarch ppc64 s390 s390x
# there is only partial support for ppc64 in 3.2 so we have to remove this
# partial support to get the replacemnt hack to work
# find -name \*ppc64\* | xargs rm -r
# remove remove ppc64 support from features/org.eclipse.platform.source/feature.xml
# replace ppc64 with a fake arch (ppc128) so we don't have duplicate ant targets
# find -name \*.xml -exec sed --in-place "s/rootFileslinux_gtk_ppc64/rootFileslinux_gtk_ppc128/g" "{}" \;
# remove org.eclipse.platform.source.linux.gtk.ppc64,3.2.0.v20060602-0010-gszCh-8eOaU1uKq
# sed --in-place "s/,.\{38\}ppc64.*macosx/,org.eclipse.platform.source.macosx/g" features/org.eclipse.platform.source/build.xml
# replace final occurances with an existing arch
# sed --in-place "s/ppc64/x86_64/g" features/org.eclipse.platform.source/build.xml
# remove remove ppc64 support from features/org.eclipse.platform.source/feature.xml
# mv features/org.eclipse.platform.source/feature.xml features/org.eclipse.platform.source/feature.xml.orig
# grep -v ppc64 features/org.eclipse.platform.source/feature.xml.orig > features/org.eclipse.platform.source/feature.xml
# finally the replacement hack
for f in $(find -name \*ia64\* | grep -v motif | grep -v ia64_32); do
mv $f $(echo $f | sed "s/ia64/%{_arch}/")
done
find -type f -exec sed --in-place "s/ia64_32/@eye-eh-64_32@/g" "{}" \;
find -type f -exec sed --in-place "s/ia64/%{_arch}/g" "{}" \;
find -type f -exec sed --in-place "s/@eye-eh-64_32@/ia64_32/g" "{}" \;
%endif
# FIXME enable
# make sure there are no jars left
#for j in $(find -name \*.jar); do
# if [ ! -L $j ]; then
# echo This jar should be deleted and syslinked to a system jar: $j
# exit 1
# fi
#done
JARS=""
for j in $(find -name \*.jar); do
if [ ! -L $j ]; then
JARS="$JARS $j"
fi
done
if [ ! -z "$JARS" ]; then
echo "These jar should be deleted and syslinked to system jars: $JARS"
#FIXME anable exit 1
fi
%build
env
ORIGCLASSPATH=$CLASSPATH
# nasty hack to get these arches suppport
%ifarch ppc4 s390 s390x
for f in $(find -name \*x86_64\*); do
mv $f $(echo $f | sed "s/x86_64/%{_arch}/")
done
for f in $(find -name \*x86_64\*); do
mv $f $(echo $f | sed "s/x86_64/%{_arch}/")
done
find -type f -exec sed --in-place "s/x86_64/%{_arch}/g" "{}" \;
%endif
# finish the jsch plugin build
#FIXME remove version numbers
pushd baseLocation/plugins/com.jcraft.jsch_0.1.28.jar-build
unzip -qq %{_javadir}/jsch.jar -x META-INF\*
sed --in-place "s/$(grep Created-By: META-INF/MANIFEST.MF)/Created-By: $(jar -V | head -1)/" META-INF/MANIFEST.MF
jar -cf ../com.jcraft.jsch_0.1.28.jar *
popd
rm -r baseLocation/plugins/com.jcraft.jsch_0.1.28.jar-build
# Bootstrapping is 3 parts:
# 1. Build ecj with gcj -C -- only necessary until gcjx/ecj lands in gcc
@ -954,7 +979,7 @@ pushd $RPM_BUILD_ROOT%{_datadir}/%{name}
## BEGIN ANT ##
rm plugins/org.apache.ant_*/lib/ant-antlr.jar
rm plugins/org.apache.ant_*/lib/ant-apache-bcel.jar
rm plugins/org.apache.ant_*/lib/ant-apache-bsf.jar
#rm plugins/org.apache.ant_*/lib/ant-apache-bsf.jar
rm plugins/org.apache.ant_*/lib/ant-apache-log4j.jar
rm plugins/org.apache.ant_*/lib/ant-apache-oro.jar
rm plugins/org.apache.ant_*/lib/ant-apache-regexp.jar
@ -983,7 +1008,7 @@ rm plugins/org.apache.ant_*/lib/ant-trax.jar
# FIXME use build-jar-repository
ln -s %{_javadir}/ant/ant-antlr.jar plugins/org.apache.ant_1.6.5/lib/ant-antlr.jar
ln -s %{_javadir}/ant/ant-apache-bcel.jar plugins/org.apache.ant_1.6.5/lib/ant-apache-bcel.jar
ln -s %{_javadir}/ant/ant-apache-bsf.jar plugins/org.apache.ant_1.6.5/lib/ant-apache-bsf.jar
#ln -s %{_javadir}/ant/ant-apache-bsf.jar plugins/org.apache.ant_1.6.5/lib/ant-apache-bsf.jar
ln -s %{_javadir}/ant/ant-apache-log4j.jar plugins/org.apache.ant_1.6.5/lib/ant-apache-log4j.jar
ln -s %{_javadir}/ant/ant-apache-oro.jar plugins/org.apache.ant_1.6.5/lib/ant-apache-oro.jar
ln -s %{_javadir}/ant/ant-apache-regexp.jar plugins/org.apache.ant_1.6.5/lib/ant-apache-regexp.jar
@ -1569,6 +1594,10 @@ fi
%{_datadir}/%{name}/plugins/org.eclipse.platform.source.linux.gtk.*
%changelog
* Wed Jun 07 2006 Ben Konrath <bkonrath@redhat.com> 3.2.0-0jpp_0fc.3.2RC7.3
- Enable s390 and s390x.
- Add small snippet to check for jars at the end of prep.
* Wed Jun 07 2006 Andrew Overholt <overholt@redhat.com> 3.2.0-0jpp_0fc.3.2RC7.2
- Fix eclipse-ecj.jar symlink to include qualifier.