# ChangeLog for dev-java/swt
# Copyright 2002-2006 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/dev-java/swt/ChangeLog,v 1.56 2006/12/07 11:40:09 caster Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-java/swt/ChangeLog,v 1.57 2006/12/07 22:18:45 betelgeuse Exp $
+
+ 07 Dec 2006; Petteri Räty <betelgeuse@gentoo.org>
+ +files/swt-3.2.1-fbsd.patch, swt-3.2.1.ebuild:
+ Added patches to build swt on Gentoo/FreeBSD. Fixes bug #157465. Thanks to
+ Diego Pettenò <flameeyes@gentoo.org>.
07 Dec 2006; Vlastimil Babka <caster@gentoo.org> swt-3.2.1.ebuild:
Fix unpacking, thanks to Flameeyes for noticing.
+-----BEGIN PGP SIGNED MESSAGE-----
+Hash: SHA1
+
AUX build.xml 458 RMD160 a8eb69b723bdd8e5e25df8df26d28f4ea134fa87 SHA1 3d5befea18ba4c5bc20da80ed067488a16be6585 SHA256 bbac0fb3bf9454b81e6d27dae4ebb9538cf62f2be17adcf169538749230dc8e7
MD5 f5e548bc26a0f1f3c18131be76face40 files/build.xml 458
RMD160 a8eb69b723bdd8e5e25df8df26d28f4ea134fa87 files/build.xml 458
MD5 4afd88780d3b774d9a5bbdc374981840 files/swt-3.2-remove-stripping.patch 896
RMD160 71172237544b61942784b91c30a917b0d12586e3 files/swt-3.2-remove-stripping.patch 896
SHA256 72c26a580a835103d7801018295cb6390473c804a7114796f464ddf5bc9f1983 files/swt-3.2-remove-stripping.patch 896
+AUX swt-3.2.1-fbsd.patch 2545 RMD160 c9dd690a2e5f892d7614bf7efc461ab3a4549e57 SHA1 3d1521a564fc9131190cbd73da4ea77cbfb343c8 SHA256 4a89bfb108a231997b65bf6b6eb3ad393d41801692e5586f60aa79e25385fe9f
+MD5 984379c24b33ef9a5acd963254a14fc0 files/swt-3.2.1-fbsd.patch 2545
+RMD160 c9dd690a2e5f892d7614bf7efc461ab3a4549e57 files/swt-3.2.1-fbsd.patch 2545
+SHA256 4a89bfb108a231997b65bf6b6eb3ad393d41801692e5586f60aa79e25385fe9f files/swt-3.2.1-fbsd.patch 2545
DIST swt-3.2-gtk-linux-ppc.zip 2913359 RMD160 558cddfbd3fb32091908c23a26db4f153bf36510 SHA1 b0fb2ce02983be18d6d9d7df033a168a1c92d2a3 SHA256 13cda631e4ec522c9d10aa2edb5a38f104e40ad1f67f94513f932a9193167062
DIST swt-3.2-gtk-linux-x86.zip 2935209 RMD160 d9560445852020e7d755594c60ba01c7904b9924 SHA1 1d6d0cd4624c93ae005053681731cbaf3d4a2e52 SHA256 05701ceb02a4099e035571abb0d005947758de48c47b49cd38a5b3fd5670a13c
DIST swt-3.2-gtk-linux-x86_64.zip 2841135 RMD160 8764b1357a23a530c9e523b6f1364a7b7abfea01 SHA1 afd11534a90b2f547fb87c5cf6edea205c0a7d92 SHA256 fb00c97c488353a10d7842a50b9184851e90870c3ec1b0ee3bfa838e6ac9a665
MD5 d3342ff6d0af3a1ac9c7aa29166167aa swt-3.2-r2.ebuild 5223
RMD160 da996efcac704b5fda4fd71c6974d9252dd38fcf swt-3.2-r2.ebuild 5223
SHA256 3515363ece683ebe30dfeac298ef951e9039b5ca93dcd1c2f23aee53696da65f swt-3.2-r2.ebuild 5223
-EBUILD swt-3.2.1.ebuild 4942 RMD160 d3ca15106ba49b93e9b76aa180808fabacfa70f3 SHA1 c6ba2d70995ae5c60dbf1d7d4ae7206456453153 SHA256 d5dc824c32705c2f46ffffdff73e8d1c92ee5b32af0bba7263577b61197f83d6
-MD5 7cc8aa35c7bee9829a3a54074a6c4df8 swt-3.2.1.ebuild 4942
-RMD160 d3ca15106ba49b93e9b76aa180808fabacfa70f3 swt-3.2.1.ebuild 4942
-SHA256 d5dc824c32705c2f46ffffdff73e8d1c92ee5b32af0bba7263577b61197f83d6 swt-3.2.1.ebuild 4942
-MISC ChangeLog 10174 RMD160 09cf27182489c0766cb702f91f7723f40d8da99d SHA1 66fa79126482f49b4eef30c125782f5f95ebd192 SHA256 3bb369bff4db455d7969eec8a8557d49bae9e35a270b50b1f5740cd3625a33d9
-MD5 2b5e5c4892e1f4447637f7462880894a ChangeLog 10174
-RMD160 09cf27182489c0766cb702f91f7723f40d8da99d ChangeLog 10174
-SHA256 3bb369bff4db455d7969eec8a8557d49bae9e35a270b50b1f5740cd3625a33d9 ChangeLog 10174
+EBUILD swt-3.2.1.ebuild 5267 RMD160 417b51ba49b26324de21d90e450b9703d38000b7 SHA1 583e828cbd93c6792e8f39226f57d4df889f4cc6 SHA256 2c9a7df3be613714eb6452382e88a28962a55e6b06e5b368d382c2deff81a3dd
+MD5 0b1e6c89d71e25139b7530f755461b04 swt-3.2.1.ebuild 5267
+RMD160 417b51ba49b26324de21d90e450b9703d38000b7 swt-3.2.1.ebuild 5267
+SHA256 2c9a7df3be613714eb6452382e88a28962a55e6b06e5b368d382c2deff81a3dd swt-3.2.1.ebuild 5267
+MISC ChangeLog 10399 RMD160 1bc34fbd3a834d5caa7353e26b022864bf1c4053 SHA1 e45d8e0e638f824c3a72fe13c852772561b75949 SHA256 bb367b31898f67b06f58452aa261048792392fc559c45ed40939c96b2ec3ad5b
+MD5 b7ef4bd26563be5ad13d2fa451064bf3 ChangeLog 10399
+RMD160 1bc34fbd3a834d5caa7353e26b022864bf1c4053 ChangeLog 10399
+SHA256 bb367b31898f67b06f58452aa261048792392fc559c45ed40939c96b2ec3ad5b ChangeLog 10399
MISC metadata.xml 440 RMD160 36ab97c0b5fbe32d4e636e3edb8c4d9e77b2ce34 SHA1 4d2c6b9b3c860ebd97f431ebae1a73773569c0fa SHA256 c09c2804231b54df222f2380cc75d96db4febd9cc5d838e7fb1eb27dc75a53b8
MD5 8a0e1d1eedbd5a4bdd34889f6fbbf9da metadata.xml 440
RMD160 36ab97c0b5fbe32d4e636e3edb8c4d9e77b2ce34 metadata.xml 440
MD5 b1b92585d08574017b21246e5bee6c45 files/digest-swt-3.2.1 1075
RMD160 f11b1c0e8775d8a9f96918fd2b632f276b0f577e files/digest-swt-3.2.1 1075
SHA256 8a4fdc86dcf1d19555dbec690d191b180265908405983e1396a311132d3975e5 files/digest-swt-3.2.1 1075
+-----BEGIN PGP SIGNATURE-----
+Version: GnuPG v1.4.5 (GNU/Linux)
+
+iD8DBQFFeJNOcxLzpIGCsLQRAluCAJsEzKm1s2MkO6eW6969DMFRrb7SJQCeKoCi
+pJUY2TIPYhxPWWRFTBnYCE4=
+=HfLs
+-----END PGP SIGNATURE-----
--- /dev/null
+Index: work/build.sh
+===================================================================
+--- work.orig/build.sh
++++ work/build.sh
+@@ -31,6 +31,10 @@ case $OS in
+ SWT_OS=solaris
+ MAKEFILE=make_solaris.mak
+ ;;
++ "FreeBSD")
++ SWT_OS=freebsd
++ MAKEFILE=make_freebsd.mak
++ ;;
+ *)
+ SWT_OS=`uname -s | tr -s '[:upper:]' '[:lower:]'`
+ MAKEFILE=make_linux.mak
+Index: work/make_freebsd.mak
+===================================================================
+--- work.orig/make_freebsd.mak
++++ work/make_freebsd.mak
+@@ -78,7 +78,7 @@ MOZILLACFLAGS = -march=athlon64 -O2 -ftr
+ -fPIC \
+ -I. \
+ -I$(JAVA_HOME)/include \
+- -I$(JAVA_HOME)/include/linux \
++ -I$(JAVA_HOME)/include/freebsd \
+ ${SWT_PTR_CFLAGS}
+ MOZILLALIBS = -shared -Wl,--version-script=mozilla_exports -Bsymbolic
+
+@@ -98,9 +98,9 @@ GLX_OBJECTS = swt.o glx.o glx_structs.o
+ CFLAGS = -march=athlon64 -O2 -ftracer -pipe -ftree-vectorize -Wformat=2 -Wno-error -Wno-pointer-sign -g -ggdb -Wstrict-aliasing=2 -Wno-format-zero-length -Wall \
+ -DSWT_VERSION=$(SWT_VERSION) \
+ $(NATIVE_STATS) \
+- -DLINUX -DGTK \
++ -DFREEBSD -DGTK \
+ -I$(JAVA_HOME)/include \
+- -I$(JAVA_HOME)/include/linux \
++ -I$(JAVA_HOME)/include/freebsd \
+ -fPIC \
+ ${SWT_PTR_CFLAGS}
+ LIBS = -shared -fPIC
+Index: work/src/org/eclipse/swt/internal/gtk/OS.java
+===================================================================
+--- work.orig/src/org/eclipse/swt/internal/gtk/OS.java
++++ work/src/org/eclipse/swt/internal/gtk/OS.java
+@@ -23,18 +23,20 @@ public class OS extends Platform {
+ }
+
+ /** OS Constants */
+- public static final boolean IsAIX, IsSunOS, IsLinux, IsHPUX;
++ public static final boolean IsAIX, IsSunOS, IsLinux, IsHPUX, IsFreeBSD;
+ static {
+
+ /* Initialize the OS flags and locale constants */
++ /* make bootstrap compatible with `uname -s` for FreeBSD */
+ String osName = System.getProperty ("os.name");
+- boolean isAIX = false, isSunOS = false, isLinux = false, isHPUX = false;
++ boolean isAIX = false, isSunOS = false, isLinux = false, isHPUX = false, isFreeBSD = false;
+ if (osName.equals ("Linux")) isLinux = true;
++ if (osName.equals ("FreeBSD")) isFreeBSD = true;
+ if (osName.equals ("AIX")) isAIX = true;
+ if (osName.equals ("Solaris")) isSunOS = true;
+ if (osName.equals ("SunOS")) isSunOS = true;
+ if (osName.equals ("HP-UX")) isHPUX = true;
+- IsAIX = isAIX; IsSunOS = isSunOS; IsLinux = isLinux; IsHPUX = isHPUX;
++ IsAIX = isAIX; IsSunOS = isSunOS; IsLinux = isLinux; IsFreeBSD = isFreeBSD; IsHPUX = isHPUX;
+ }
+
+ /** Constants */
# Copyright 1999-2006 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-java/swt/swt-3.2.1.ebuild,v 1.6 2006/12/07 11:40:09 caster Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-java/swt/swt-3.2.1.ebuild,v 1.7 2006/12/07 22:18:45 betelgeuse Exp $
-inherit eutils java-pkg-2 java-ant-2
+inherit eutils java-pkg-2 java-ant-2 toolchain-funcs
MY_DMF="R-${PV}-200609210945"
PATCHSET="${P}-gentoo-patches"
DESCRIPTION="GTK based SWT Library"
HOMEPAGE="http://www.eclipse.org/"
SRC_URI="x86? ( http://download.eclipse.org/downloads/drops/${MY_DMF}/${P}-gtk-linux-x86.zip )
+ x86-fbsd? ( http://download.eclipse.org/downloads/drops/${MY_DMF}/${P}-gtk-linux-x86.zip )
amd64? ( http://download.eclipse.org/downloads/drops/${MY_DMF}/${P}-gtk-linux-x86_64.zip )
ppc? ( http://download.eclipse.org/downloads/drops/${MY_DMF}/${P}-gtk-linux-ppc.zip )
mirror://gentoo/${PATCHSET}.tar.bz2"
sed -i "s/MOZILLACFLAGS = -O/MOZILLACFLAGS = ${CXXFLAGS}/" \
make_linux.mak \
|| die "Failed to tweak make_linux.mak"
+
+ cp make_linux.mak make_freebsd.mak
+
+ # https://bugs.eclipse.org/bugs/show_bug.cgi?id=167173
+ epatch "${FILESDIR}/${P}-fbsd.patch"
}
src_compile() {
elif [[ ! -z "$(java-config --java-version | grep 'GNU libgcj')" ]] ; then
export AWT_LIB_PATH=$JAVA_HOME/$(get_libdir)
else
- if [[ ${ARCH} == 'x86' ]] ; then
+ if [[ $(tc-arch) == 'x86' ]] ; then
export AWT_LIB_PATH=$JAVA_HOME/jre/lib/i386
- elif [[ ${ARCH} == 'ppc' ]] ; then
+ elif [[ $(tc-arch) == 'ppc' ]] ; then
export AWT_LIB_PATH=$JAVA_HOME/jre/lib/ppc
else
export AWT_LIB_PATH=$JAVA_HOME/jre/lib/amd64
# Fix the pointer size for AMD64
[[ ${ARCH} == 'amd64' ]] && export SWT_PTR_CFLAGS=-DSWT_PTR_SIZE_64
- local make="emake -f make_linux.mak NO_STRIP=y"
+ local platform="linux"
+
+ use elibc_FreeBSD && platform="freebsd"
+
+ local make="emake -f make_${platform}.mak NO_STRIP=y"
einfo "Building AWT library"
${make} make_awt || die "Failed to build AWT support"