Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[linuxtools-dev] [patch] add architecture support for arm and ia64

please find attached patches to add architecture support for arm and ia64. builds were done on Ubuntu 9.10 (karmic koala). Build logs at
https://launchpad.net/ubuntu/+source/eclipse/3.5.1+repack~1-0ubuntu1
All builds done with OpenJDK 6 (IcedTea 1.6.1).

 - arm: eclipse starts and doesn't crash immediately, started doing
   a tutorial, which seems to work ok.
 - ia64: Builds, but the build failed with a packaging error.
 - sparc: Tested with hotspot, which crashes.

By removing the not needed configs in eclipse-build-config/build.properties, the build time gets much shorter (on a dual PowerMac G4, it saved 3h). Just building the one config needed for the build would reduce the build time further. Why not having a eclipse-build-config/build.properties.in, which has a place-holder for the current arch and generate a eclipse-build-config/build.properties for the current build? This way additional archs can be added without a build penalty.

  Matthias

2009-10-26  Matthias Klose  <doko@xxxxxxxxxx>

	* build.sh: Fix architecture for arm machines.
	* additionalArchs/rename.sh: Remove bashism.
	* eclipse-build-config/build.properties: Add linux configs
	for arm and ia64.
	* eclipse-build-config/productFiles/rcpConfig/build.properties: Add
	properties for arm and ia64.
	* generateAdditionalPlatforms.xml: Add arm and ia64.
	* patches/eclipse-add-archs-executable.patch: Likewise.
	* patches/eclipse-add-archs-filesystem.patch: Likewise.
	* patches/eclipse-add-archs-swt.patch: Likewise.
	* patches/eclipse-add-ppc64-sparc64-s390-s390x.patch: Likewise.

diff --git a/additionalArchs/rename.sh b/additionalArchs/rename.sh
index 5ca0915..46e99d9 100644
--- a/additionalArchs/rename.sh
+++ b/additionalArchs/rename.sh
@@ -2,7 +2,7 @@
 
 newArch=$1
 
-function moves(){
+moves(){
 for f in $(find -type d); do
       tofile=$(echo $f | sed "s/ppc/$newArch/")
       if [ $tofile != $f ]; then
diff --git a/build.sh b/build.sh
index 9802cbd..191822e 100755
--- a/build.sh
+++ b/build.sh
@@ -8,6 +8,8 @@ fi
 
 # Massage arch for Eclipse-uname differences
 case ${arch} in
+	arm*)
+		arch=arm ;;
 	i[0-9]*86)
 		arch=x86 ;;
 	ia64)
diff --git a/eclipse-build-config/build.properties b/eclipse-build-config/build.properties
index e7f8009..b18768b 100755
--- a/eclipse-build-config/build.properties
+++ b/eclipse-build-config/build.properties
@@ -48,7 +48,9 @@ configs=\
 	linux, gtk, sparcv9 &\
 	linux, gtk, sparc64 &\
 	linux, gtk, alpha &\
+	linux, gtk, arm &\
+	linux, gtk, ia64 &\
 	linux, motif, x86 & \
 	solaris, gtk, sparc & \
 	solaris, gtk, x86 & \

diff --git a/eclipse-build-config/productFiles/rcpConfig/build.properties b/eclipse-build-config/productFiles/rcpConfig/build.properties
index 77fdd9f..9e20f1a 100644
--- a/eclipse-build-config/productFiles/rcpConfig/build.properties
+++ b/eclipse-build-config/productFiles/rcpConfig/build.properties
@@ -29,6 +29,10 @@ root.linux.gtk.sparc=absolute:${buildDirectory}/features/org.eclipse.platform/ab
 root.linux.gtk.sparc.permissions.755=*.so*
 root.linux.gtk.sparc64=absolute:${buildDirectory}/features/org.eclipse.platform/about_files/linux.gtk.sparc64,absolute:${buildDirectory}/features/org.eclipse.equinox.executable/bin/gtk/linux/sparc64
 root.linux.gtk.sparc64.permissions.755=*.so*
+root.linux.gtk.arm=absolute:${buildDirectory}/features/org.eclipse.platform/about_files/linux.gtk.arm,absolute:${buildDirectory}/features/org.eclipse.equinox.executable/bin/gtk/linux/arm
+root.linux.gtk.arm.permissions.755=*.so*
+root.linux.gtk.ia64=absolute:${buildDirectory}/features/org.eclipse.platform/about_files/linux.gtk.ia64,absolute:${buildDirectory}/features/org.eclipse.equinox.executable/bin/gtk/linux/ia64
+root.linux.gtk.ia64.permissions.755=*.so*
 root.linux.gtk.s390=absolute:${buildDirectory}/features/org.eclipse.platform/about_files/linux.gtk.s390,absolute:${buildDirectory}/features/org.eclipse.equinox.executable/contributed/gtk/linux/s390
 root.linux.gtk.s390.permissions.755=*.so*
 root.linux.gtk.s390x=absolute:${buildDirectory}/features/org.eclipse.platform/about_files/linux.gtk.s390x,absolute:${buildDirectory}/features/org.eclipse.equinox.executable/contributed/gtk/linux/s390x
diff --git a/generateAdditionalPlatforms.xml b/generateAdditionalPlatforms.xml
index 99724a3..28c9111 100644
--- a/generateAdditionalPlatforms.xml
+++ b/generateAdditionalPlatforms.xml
@@ -50,7 +50,9 @@
 	<target name="generate" depends="init">
 		<generateArch newArch="ppc64" />
 		<generateArch newArch="sparc" />
-	    <generateArch newArch="sparc64" />
+		<generateArch newArch="sparc64" />
+		<generateArch newArch="arm" />
+		<generateArch newArch="ia64" />
 	</target>
 
 	<target name="createTarball" depends="generate">
diff --git a/patches/eclipse-add-archs-executable.patch b/patches/eclipse-add-archs-executable.patch
index fbc0880..f4f15d6 100644
--- a/patches/eclipse-add-archs-executable.patch
+++ b/patches/eclipse-add-archs-executable.patch
@@ -1,6 +1,6 @@
---- features/org.eclipse.equinox.executable/target.build.properties.real	2009-10-21 14:21:08.843594049 +0300
-+++ features/org.eclipse.equinox.executable/target.build.properties	2009-10-21 14:22:18.142845083 +0300
-@@ -25,6 +25,15 @@ root.linux.gtk.x86.permissions.755=libca
+--- features/org.eclipse.equinox.executable/target.build.properties.orig	2009-10-24 20:15:01.959944458 +0200
++++ features/org.eclipse.equinox.executable/target.build.properties	2009-10-24 20:16:45.819945970 +0200
+@@ -25,6 +25,21 @@
  root.linux.gtk.ppc=bin/gtk/linux/ppc,gtk_root
  root.linux.gtk.ppc.permissions.755=libcairo-swt.so
  
@@ -13,12 +13,18 @@
 +root.linux.gtk.sparc64=bin/gtk/linux/sparc64,gtk_root
 +root.linux.gtk.sparc64.permissions.755=libcairo-swt.so
 +
++root.linux.gtk.arm=bin/gtk/linux/arm,gtk_root
++root.linux.gtk.arm.permissions.755=libcairo-swt.so
++
++root.linux.gtk.ia64=bin/gtk/linux/ia64,gtk_root
++root.linux.gtk.ia64.permissions.755=libcairo-swt.so
++
  root.macosx.carbon.ppc=bin/carbon/macosx/ppc
  root.macosx.carbon.ppc.permissions.755=${launcherName}.app/Contents/MacOS/${launcherName}
  
---- features/org.eclipse.equinox.executable/feature.xml.real	2009-10-21 14:35:44.818598403 +0300
-+++ features/org.eclipse.equinox.executable/feature.xml	2009-10-21 14:37:07.063593607 +0300
-@@ -97,6 +97,36 @@
+--- features/org.eclipse.equinox.executable/feature.xml.orig	2009-10-24 20:15:01.969956083 +0200
++++ features/org.eclipse.equinox.executable/feature.xml	2009-10-24 20:17:49.449952083 +0200
+@@ -97,6 +97,56 @@
           install-size="0"
           version="0.0.0"
           fragment="true"/>
@@ -52,6 +58,26 @@
 +         install-size="0"
 +         version="0.0.0"
 +         fragment="true"/>
++
++   <plugin
++         id="org.eclipse.equinox.launcher.gtk.linux.arm"
++         os="linux"
++         ws="gtk"
++         arch="arm"
++         download-size="0"
++         install-size="0"
++         version="0.0.0"
++         fragment="true"/>
++   
++   <plugin
++         id="org.eclipse.equinox.launcher.gtk.linux.ia64"
++         os="linux"
++         ws="gtk"
++         arch="ia64"
++         download-size="0"
++         install-size="0"
++         version="0.0.0"
++         fragment="true"/>
  
     <plugin
           id="org.eclipse.equinox.launcher.gtk.linux.x86"
diff --git a/patches/eclipse-add-archs-filesystem.patch b/patches/eclipse-add-archs-filesystem.patch
index 7d5b8f2..f161c63 100644
--- a/patches/eclipse-add-archs-filesystem.patch
+++ b/patches/eclipse-add-archs-filesystem.patch
@@ -1,6 +1,6 @@
---- ./features/org.eclipse.platform/feature.xml	2009-08-07 18:30:54.000000000 +0300
-+++ ./features/org.eclipse.platform/feature.xml	2009-08-07 18:50:29.043863537 +0300
-@@ -440,6 +440,36 @@
+--- ./features/org.eclipse.platform/feature.xml.orig	2009-10-24 13:13:29.000000000 +0200
++++ ./features/org.eclipse.platform/feature.xml	2009-10-24 20:25:05.159943595 +0200
+@@ -440,6 +440,56 @@
           version="0.0.0"
           fragment="true"
           unpack="false"/>
@@ -34,6 +34,26 @@
 +         version="0.0.0"
 +         fragment="true"
 +         unpack="false"/>
++
++   <plugin
++         id="org.eclipse.core.filesystem.linux.arm"
++         os="linux"
++         arch="arm"
++         download-size="0"
++         install-size="0"
++         version="0.0.0"
++         fragment="true"
++         unpack="false"/>
++	 
++   <plugin
++         id="org.eclipse.core.filesystem.linux.ia64"
++         os="linux"
++         arch="ia64"
++         download-size="0"
++         install-size="0"
++         version="0.0.0"
++         fragment="true"
++         unpack="false"/>
  
     <plugin
           id="org.eclipse.core.filesystem.linux.x86"
diff --git a/patches/eclipse-add-archs-swt.patch b/patches/eclipse-add-archs-swt.patch
index e232030..ff85e38 100644
--- a/patches/eclipse-add-archs-swt.patch
+++ b/patches/eclipse-add-archs-swt.patch
@@ -1,7 +1,6 @@
-diff -up ./features/org.eclipse.rcp/feature.xml.arches ./features/org.eclipse.rcp/feature.xml
---- ./features/org.eclipse.rcp/feature.xml.arches	2008-10-03 09:05:02.000000000 -0400
-+++ ./features/org.eclipse.rcp/feature.xml	2008-10-03 09:06:45.000000000 -0400
-@@ -229,6 +229,48 @@
+--- ./features/org.eclipse.rcp/feature.xml.orig	2009-10-24 13:13:29.000000000 +0200
++++ ./features/org.eclipse.rcp/feature.xml	2009-10-24 20:28:26.699941959 +0200
+@@ -250,6 +250,67 @@
           unpack="false"/>
  
     <plugin
@@ -43,8 +42,27 @@ diff -up ./features/org.eclipse.rcp/feature.xml.arches ./features/org.eclipse.rc
 +         fragment="true"
 +         unpack="false"/>
 +
++   <plugin
++         id="org.eclipse.swt.gtk.linux.arm"
++         os="linux"
++         ws="gtk"
++         arch="arm"
++         download-size="0"
++         install-size="0"
++         version="0.0.0"
++         fragment="true"
++         unpack="false"/>
 +
-+
++   <plugin
++         id="org.eclipse.swt.gtk.linux.ia64"
++         os="linux"
++         ws="gtk"
++         arch="ia64"
++         download-size="0"
++         install-size="0"
++         version="0.0.0"
++         fragment="true"
++         unpack="false"/>
 +
 +   <plugin
           id="org.eclipse.swt.gtk.solaris.sparc"
diff --git a/patches/eclipse-add-ppc64-sparc64-s390-s390x.patch b/patches/eclipse-add-ppc64-sparc64-s390-s390x.patch
index 3a2c701..dad668f 100644
--- a/patches/eclipse-add-ppc64-sparc64-s390-s390x.patch
+++ b/patches/eclipse-add-ppc64-sparc64-s390-s390x.patch
@@ -1,7 +1,33 @@
-diff -ru eclipse-3.3-src.orig/plugins/org.eclipse.core.runtime/src/org/eclipse/core/internal/runtime/InternalPlatform.java eclipse-3.3-src/plugins/org.eclipse.core.runtime/src/org/eclipse/core/internal/runtime/InternalPlatform.java
---- eclipse-3.3-src.orig/plugins/org.eclipse.core.runtime/src/org/eclipse/core/internal/runtime/InternalPlatform.java	2007-06-25 15:57:02.000000000 -0400
-+++ eclipse-3.3-src/plugins/org.eclipse.core.runtime/src/org/eclipse/core/internal/runtime/InternalPlatform.java	2007-07-16 16:08:02.000000000 -0400
-@@ -47,6 +47,11 @@
+--- ./plugins/org.eclipse.osgi/eclipseAdaptor/src/org/eclipse/core/runtime/internal/adaptor/PluginConverterImpl.java.orig	2009-10-24 13:13:29.000000000 +0200
++++ ./plugins/org.eclipse.osgi/eclipseAdaptor/src/org/eclipse/core/runtime/internal/adaptor/PluginConverterImpl.java	2009-10-24 20:35:48.719942584 +0200
+@@ -64,7 +64,7 @@
+ 	private static final String MANIFEST_VERSION = "Manifest-Version"; //$NON-NLS-1$
+ 	private static final String PLUGIN_PROPERTIES_FILENAME = "plugin"; //$NON-NLS-1$
+ 	private static PluginConverterImpl instance;
+-	private static final String[] ARCH_LIST = {org.eclipse.osgi.service.environment.Constants.ARCH_PA_RISC, org.eclipse.osgi.service.environment.Constants.ARCH_PPC, org.eclipse.osgi.service.environment.Constants.ARCH_SPARC, org.eclipse.osgi.service.environment.Constants.ARCH_X86, org.eclipse.osgi.service.environment.Constants.ARCH_AMD64, org.eclipse.osgi.service.environment.Constants.ARCH_IA64};
++	private static final String[] ARCH_LIST = {org.eclipse.osgi.service.environment.Constants.ARCH_PA_RISC, org.eclipse.osgi.service.environment.Constants.ARCH_PPC, org.eclipse.osgi.service.environment.Constants.ARCH_SPARC, org.eclipse.osgi.service.environment.Constants.ARCH_X86, org.eclipse.osgi.service.environment.Constants.ARCH_AMD64, org.eclipse.osgi.service.environment.Constants.ARCH_IA64, org.eclipse.osgi.service.environment.Constants.ARCH_PPC64, org.eclipse.osgi.service.environment.Constants.ARCH_SPARC64, org.eclipse.osgi.service.environment.Constants.ARCH_S390, org.eclipse.osgi.service.environment.Constants.ARCH_S390X, org.eclipse.osgi.service.environment.Constants.ARCH_ALPHA, org.eclipse.osgi.service.environment.Constants.ARCH_ARM};
+ 	static public final String FRAGMENT_MANIFEST = "fragment.xml"; //$NON-NLS-1$
+ 	static public final String GENERATED_FROM = "Generated-from"; //$NON-NLS-1$
+ 	static public final String MANIFEST_TYPE_ATTRIBUTE = "type"; //$NON-NLS-1$
+--- ./plugins/org.eclipse.osgi/supplement/src/org/eclipse/osgi/service/environment/Constants.java.orig	2009-10-24 13:13:29.000000000 +0200
++++ ./plugins/org.eclipse.osgi/supplement/src/org/eclipse/osgi/service/environment/Constants.java	2009-10-24 20:34:51.329942209 +0200
+@@ -153,6 +153,13 @@
+ 	 */
+ 	public static final String ARCH_IA64_32 = "ia64_32";//$NON-NLS-1$
+ 
++	public static final String ARCH_PPC64 = "ppc64";//$NON-NLS-1$
++	public static final String ARCH_SPARC64 = "sparc64";//$NON-NLS-1$
++	public static final String ARCH_S390 = "s390";//$NON-NLS-1$
++	public static final String ARCH_S390X = "s390x";//$NON-NLS-1$
++	public static final String ARCH_ALPHA = "alpha";//$NON-NLS-1$
++	public static final String ARCH_ARM = "arm";//$NON-NLS-1$
++
+ 	/**
+ 	 * Constant string (value "win32") indicating the platform is running on a
+ 	 * machine using the Windows windowing system.
+--- ./plugins/org.eclipse.core.runtime/src/org/eclipse/core/internal/runtime/InternalPlatform.java.orig	2009-10-24 13:13:29.000000000 +0200
++++ ./plugins/org.eclipse.core.runtime/src/org/eclipse/core/internal/runtime/InternalPlatform.java	2009-10-24 20:38:32.159942833 +0200
+@@ -48,6 +48,12 @@
  			Platform.ARCH_X86, //
  			Platform.ARCH_AMD64, // 
  			Platform.ARCH_IA64, //
@@ -10,14 +36,13 @@ diff -ru eclipse-3.3-src.orig/plugins/org.eclipse.core.runtime/src/org/eclipse/c
 +			Platform.ARCH_S390, //
 +			Platform.ARCH_S390X, //
 +			Platform.ARCH_ALPHA, //
++			Platform.ARCH_ARM, //
  			Platform.ARCH_IA64_32};
  
  	// debug support:  set in loadOptions()
-Only in eclipse-3.3-src/plugins/org.eclipse.core.runtime/src/org/eclipse/core/internal/runtime: InternalPlatform.java.orig
-diff -ru eclipse-3.3-src.orig/plugins/org.eclipse.core.runtime/src/org/eclipse/core/runtime/Platform.java eclipse-3.3-src/plugins/org.eclipse.core.runtime/src/org/eclipse/core/runtime/Platform.java
---- eclipse-3.3-src.orig/plugins/org.eclipse.core.runtime/src/org/eclipse/core/runtime/Platform.java	2007-06-25 15:57:18.000000000 -0400
-+++ eclipse-3.3-src/plugins/org.eclipse.core.runtime/src/org/eclipse/core/runtime/Platform.java	2007-07-16 16:08:02.000000000 -0400
-@@ -346,6 +346,12 @@
+--- ./plugins/org.eclipse.core.runtime/src/org/eclipse/core/runtime/Platform.java.orig	2009-10-24 13:13:29.000000000 +0200
++++ ./plugins/org.eclipse.core.runtime/src/org/eclipse/core/runtime/Platform.java	2009-10-24 20:37:39.169942835 +0200
+@@ -349,6 +349,13 @@
  	 * @since 3.1
  	 */
  	public static final String ARCH_IA64_32 = "ia64_32";//$NON-NLS-1$
@@ -27,35 +52,7 @@ diff -ru eclipse-3.3-src.orig/plugins/org.eclipse.core.runtime/src/org/eclipse/c
 +	public static final String ARCH_S390 = "s390";//$NON-NLS-1$
 +	public static final String ARCH_S390X = "s390x";//$NON-NLS-1$
 +	public static final String ARCH_ALPHA = "alpha";//$NON-NLS-1$
++	public static final String ARCH_ARM = "arm";//$NON-NLS-1$
  
  	/**
  	 * Constant string (value "win32") indicating the platform is running on a
-Only in eclipse-3.3-src/plugins/org.eclipse.core.runtime/src/org/eclipse/core/runtime: Platform.java.orig
-diff -ru eclipse-3.3-src.orig/plugins/org.eclipse.osgi/eclipseAdaptor/src/org/eclipse/core/runtime/internal/adaptor/PluginConverterImpl.java eclipse-3.3-src/plugins/org.eclipse.osgi/eclipseAdaptor/src/org/eclipse/core/runtime/internal/adaptor/PluginConverterImpl.java
---- eclipse-3.3-src.orig/plugins/org.eclipse.osgi/eclipseAdaptor/src/org/eclipse/core/runtime/internal/adaptor/PluginConverterImpl.java	2007-06-25 15:57:06.000000000 -0400
-+++ eclipse-3.3-src/plugins/org.eclipse.osgi/eclipseAdaptor/src/org/eclipse/core/runtime/internal/adaptor/PluginConverterImpl.java	2007-07-16 16:08:02.000000000 -0400
-@@ -64,7 +64,7 @@
- 	private static final String MANIFEST_VERSION = "Manifest-Version"; //$NON-NLS-1$
- 	private static final String PLUGIN_PROPERTIES_FILENAME = "plugin"; //$NON-NLS-1$
- 	private static PluginConverterImpl instance;
--	private static final String[] ARCH_LIST = {org.eclipse.osgi.service.environment.Constants.ARCH_PA_RISC, org.eclipse.osgi.service.environment.Constants.ARCH_PPC, org.eclipse.osgi.service.environment.Constants.ARCH_SPARC, org.eclipse.osgi.service.environment.Constants.ARCH_X86, org.eclipse.osgi.service.environment.Constants.ARCH_AMD64, org.eclipse.osgi.service.environment.Constants.ARCH_IA64};
-+	private static final String[] ARCH_LIST = {org.eclipse.osgi.service.environment.Constants.ARCH_PA_RISC, org.eclipse.osgi.service.environment.Constants.ARCH_PPC, org.eclipse.osgi.service.environment.Constants.ARCH_SPARC, org.eclipse.osgi.service.environment.Constants.ARCH_X86, org.eclipse.osgi.service.environment.Constants.ARCH_AMD64, org.eclipse.osgi.service.environment.Constants.ARCH_IA64, org.eclipse.osgi.service.environment.Constants.ARCH_PPC64, org.eclipse.osgi.service.environment.Constants.ARCH_SPARC64, org.eclipse.osgi.service.environment.Constants.ARCH_S390, org.eclipse.osgi.service.environment.Constants.ARCH_S390X, org.eclipse.osgi.service.environment.Constants.ARCH_ALPHA};
- 	static public final String FRAGMENT_MANIFEST = "fragment.xml"; //$NON-NLS-1$
- 	static public final String GENERATED_FROM = "Generated-from"; //$NON-NLS-1$
- 	static public final String MANIFEST_TYPE_ATTRIBUTE = "type"; //$NON-NLS-1$
-diff -ru eclipse-3.4-src.orig/plugins/org.eclipse.osgi/supplement/src/org/eclipse/osgi/service/environment/Constants.java eclipse-3.4-src/plugins/org.eclipse.osgi/supplement/src/org/eclipse/osgi/service/environment/Constants.java
---- eclipse-3.4-src.orig/plugins/org.eclipse.osgi/supplement/src/org/eclipse/osgi/service/environment/Constants.java.orig	2008-07-22 08:37:14.000000000 -0400
-+++ eclipse-3.4-src/plugins/org.eclipse.osgi/supplement/src/org/eclipse/osgi/service/environment/Constants.java	2008-07-22 08:38:02.000000000 -0400
-@@ -131,6 +131,12 @@
- 	 */
- 	public static final String ARCH_IA64_32 = "ia64_32";//$NON-NLS-1$
- 
-+	public static final String ARCH_PPC64 = "ppc64";//$NON-NLS-1$
-+	public static final String ARCH_SPARC64 = "sparc64";//$NON-NLS-1$
-+	public static final String ARCH_S390 = "s390";//$NON-NLS-1$
-+	public static final String ARCH_S390X = "s390x";//$NON-NLS-1$
-+	public static final String ARCH_ALPHA = "alpha";//$NON-NLS-1$
-+
- 	/**
- 	 * Constant string (value "win32") indicating the platform is running on a
- 	 * machine using the Windows windowing system.

Back to the top