summaryrefslogtreecommitdiff
path: root/dev-java/swt
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2023-12-04 10:56:18 +0000
committerV3n3RiX <venerix@koprulu.sector>2023-12-04 10:56:18 +0000
commit4ead5818a5d230bcc875202c487761a9b786e945 (patch)
tree63238d1977f2788cb5b7074037f15810af25bb88 /dev-java/swt
parentd074d0ba59e3121dba0c27c4a18f1e481f67b62a (diff)
gentoo auto-resync : 04:12:2023 - 10:56:18
Diffstat (limited to 'dev-java/swt')
-rw-r--r--dev-java/swt/Manifest4
-rw-r--r--dev-java/swt/swt-4.30.ebuild148
2 files changed, 152 insertions, 0 deletions
diff --git a/dev-java/swt/Manifest b/dev-java/swt/Manifest
index ea3aa2c02a94..1f84b11e00ab 100644
--- a/dev-java/swt/Manifest
+++ b/dev-java/swt/Manifest
@@ -14,7 +14,11 @@ DIST swt-4.10-gtk-linux-x86_64.zip 3844306 BLAKE2B 0e0ed21708acce347fd025920ee63
DIST swt-4.29-gtk-linux-aarch64.zip 3836724 BLAKE2B 8c905df298688686ee22c9f2021560856f7ac7b6a92dad744b27cd30530c6ff76470fdcbb79b91ada01f28c43b8f694c334ff1337d692366ae9dc0319f7e46e2 SHA512 44ff572b57631b1b6a98192f60624758d90f54a2b2272c6bbb140ece39e65bb4086cf08fbc50c5f2e388e7b410b28fc014b87a8560062053b4c131970fa38b17
DIST swt-4.29-gtk-linux-ppc64le.zip 3860955 BLAKE2B f24f8224581425dc86926a147f2f4c644f086cb7907e03bfca64df93ef5ce8341f519acc91e90c0af4eede65797ac019c17a410ff0312306714fa26ddb4234b4 SHA512 09326b5204970d9db2cede4aebf11c7f24a47c30b6bc49764dda1d0a33fa83c7c4755797cac387d1814a29ad2574e45244b994e5df0c7ef2fd1375fc7877814b
DIST swt-4.29-gtk-linux-x86_64.zip 3857122 BLAKE2B ac4416044f93eaed396ac10edb74eb5ebcbb967797109f57580bd0ac7c1e3752e8895c5ff1b315aa32b5d5b5ce8e1440badb8b9c3138a0eaeb4df63098919a8c SHA512 c92381e4d1479c219e174c027e54af781e674b266334a5e087f5821935e0a87696f40afbc9fe6f9ffaa00b5204165d9ff6476031b5e4e2df8aea1a54aeb2e65e
+DIST swt-4.30-gtk-linux-aarch64.zip 3836637 BLAKE2B 4cedb6eae73e03c32f6c226560f8e7bcbde5b6fc57579255e793fd5d01a5ff80f8b673dd7035eb7f2693abadd98bd0cfdb2eec632c05995552a9a1f1b673b8cc SHA512 dfdddd12ba30373d3ee7f0337b42d3a4f55a55dc898be9c97fbcc3d841c082d00190a75513272076c5709ee626e8af3f77c7c2dc518aa9289e80e33f4b134907
+DIST swt-4.30-gtk-linux-ppc64le.zip 3860636 BLAKE2B a535c1bcc6c668905f4d4aaa8c5ae7f3b8f48fc95004522d09924ae54d5172b18f80169d78633e960ce0c5141e5b34492d1dd05188a0b1f48d9f79d286bd2982 SHA512 5a17bd7752343da638466ac28de460d9fa9f0e777d1e48625ddb6c5538704e36cd97439d1bf8f07ad34a32b7d5f27f19d8877e8a9bb9094b4a74bdbb1dc126f7
+DIST swt-4.30-gtk-linux-x86_64.zip 3856990 BLAKE2B 0ea29a5f286fb4bb362758629226bcd6f27716afae7abb80cb37e7d4b72f0c835d63a196384465d3bc74135c42454a74c75455c094204e6329229ad8ca1fda78 SHA512 3802bd1dc84c7d684dac6b0b21de6b4958dd0c736a6b42176cf734806f04ae9dfdb18515ec5249eeff5f6bb716bf327a7a10e79d68cc487a1ad02267394507a1
EBUILD swt-3.7.2-r3.ebuild 4286 BLAKE2B 40e4b69caa7d503bbe4a832a7b3d685fc88c6469a10bad3321b33f97959e46f4af4677afaac824526c97f683a43644e4f0fd7c45b47ba360a3e9c5f18c01edc6 SHA512 517cd181329938b7bf6108713827c29825410e3053b38c3971cfbdeacc7012c3385717e130d244f7e02d96dc18d7349d52656df552c26a452d903d2be1bee995
EBUILD swt-4.10-r2.ebuild 4528 BLAKE2B 71b929a9ca02b5918314b5bf2631aa374c089d3a749e645c84865266f1cc5eebc2de5cea17471834fc329012276722c6a922c9d9266d9c9f24c45362af3b5b9b SHA512 5d7bf83a2c1b664e5e2b76336b35100eed8eef45986dc896ef5751b50431b34cfe99d9084ecae547e54dc5b250fc793fe7dd5f8c52294c442f193c2acabec480
EBUILD swt-4.29.ebuild 3440 BLAKE2B ac5dabbbcace7d28eb352a8851a0f1dd1ed72f3285215b639221c99db118c831524f563162876be9cca02ce21bd8b2d8a0b90f2983a68000cdbca562ce2c6d73 SHA512 7b1eacbda33353ab91d7deeb73889e9245664862c6c279def64a60a351f91b0b917223a4da9af2279416d1a2992383587a1427f15188b7ef6ecd1e62b7f465c5
+EBUILD swt-4.30.ebuild 3513 BLAKE2B fd3677e88d54a3c7f3ca1118b92d6d4523de2d11f39892d8e4eaa95b7872bd410ac4ebf82969d38ac506a9d4d482c5937a1565af078c738cc309eab75a6ce16e SHA512 7f13480cf0144ee7db6ada0321089b016d85af346c14eff2decae2e96816f5611583469ef8645fba59809d5dd5894653c8f1a6f99d0b1c0b7436a5c475d4b311
MISC metadata.xml 761 BLAKE2B f70a4d3ff5fcfad5705772396957664e700bd3ffe9580ac141c5faa11e24562b0cbc199a2f49d61d6a2a08058374dc1b7bfd9ae258e4a692e5b3c340f478da25 SHA512 1e8b8ceb30071c8271365a2d515e094c11ab569c4fee7b7f905d5de0a7613518320a1912b2b958d816e04d9876ed75425e16de9a35e1d6be6466888e08a420b3
diff --git a/dev-java/swt/swt-4.30.ebuild b/dev-java/swt/swt-4.30.ebuild
new file mode 100644
index 000000000000..ca3db3c7eb76
--- /dev/null
+++ b/dev-java/swt/swt-4.30.ebuild
@@ -0,0 +1,148 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+JAVA_PKG_IUSE="doc source"
+
+inherit flag-o-matic java-pkg-2 java-pkg-simple toolchain-funcs
+
+MY_PV="${PV/_rc/RC}"
+MY_DMF="https://download.eclipse.org/eclipse/downloads/drops4/R-${MY_PV}-202312010110"
+MY_P="${PN}-${MY_PV}"
+
+DESCRIPTION="GTK based SWT Library"
+HOMEPAGE="https://www.eclipse.org/swt/"
+SRC_URI="
+ amd64? ( ${MY_DMF}/${MY_P}-gtk-linux-x86_64.zip )
+ arm64? ( ${MY_DMF}/${MY_P}-gtk-linux-aarch64.zip )
+ ppc64? ( ${MY_DMF}/${MY_P}-gtk-linux-ppc64le.zip )"
+
+LICENSE="CPL-1.0 LGPL-2.1 MPL-1.1"
+SLOT="4.27"
+KEYWORDS="~amd64 ~arm64 ~ppc64"
+IUSE="cairo opengl webkit"
+
+COMMON_DEP="
+ app-accessibility/at-spi2-core:2
+ dev-libs/glib
+ x11-libs/gtk+:3
+ x11-libs/libXtst
+ cairo? ( x11-libs/cairo )
+ opengl? (
+ virtual/glu
+ virtual/opengl
+ )
+ webkit? (
+ net-libs/webkit-gtk:4.1
+ )"
+DEPEND="${COMMON_DEP}
+ >=virtual/jdk-17:*[-headless-awt]
+ x11-base/xorg-proto
+ x11-libs/libX11
+ x11-libs/libXrender
+ x11-libs/libXt
+ x11-libs/libXtst"
+# error: pattern matching in instanceof is not supported in -source 11
+RDEPEND="${COMMON_DEP}
+ >=virtual/jre-17:*"
+BDEPEND="
+ app-arch/unzip
+ virtual/pkgconfig
+"
+
+HTML_DOCS=( about.html )
+
+JAVA_RESOURCE_DIRS="resources"
+JAVA_SRC_DIR="src"
+
+PATCHES=(
+ "${FILESDIR}/swt-4.27-as-needed-and-flag-fixes.patch"
+)
+
+src_unpack() {
+ default
+ unpack "./src.zip"
+}
+
+src_prepare() {
+ default
+ java-pkg-2_src_prepare
+ # .css stuff is essential at least for running net-p2p/biglybt
+ unzip swt.jar 'org/eclipse/swt/internal/gtk/*.css' -d resources || die
+ java-pkg_clean
+ mkdir src || die "mkdir failed"
+ mv org src || die "moving java sources failed"
+ pushd src > /dev/null || die
+ find -type f ! -name '*.java' \
+ | xargs \
+ cp --parent -t ../resources -v \
+ || die "copying resources failed"
+ popd > /dev/null || die
+ cp version.txt resources || die "adding version.txt failed"
+}
+
+src_compile() {
+ append-cflags -fcommon # https://bugs.gentoo.org/707838
+
+ local JAWTSO="libjawt.so"
+ IFS=":" read -r -a ldpaths <<< $(java-config -g LDPATH)
+
+ for libpath in "${ldpaths[@]}"; do
+ if [[ -f "${libpath}/${JAWTSO}" ]]; then
+ export AWT_LIB_PATH="${libpath}"
+ break
+ # this is a workaround for broken LDPATH in <=openjdk-8.292_p10 and <=dev-java/openjdk-bin-8.292_p10
+ elif [[ -f "${libpath}/$(tc-arch)/${JAWTSO}" ]]; then
+ export AWT_LIB_PATH="${libpath}/$(tc-arch)"
+ break
+ fi
+ done
+
+ if [[ -z "${AWT_LIB_PATH}" ]]; then
+ eerror "${JAWTSO} not found in the JDK being used for compilation!"
+ die "cannot build AWT library"
+ fi
+
+ # Fix the pointer size for AMD64
+ export SWT_PTR_CFLAGS=-DJNI64
+
+ # Bug #461784, g_thread_init is deprecated since glib-2.32.
+ append-cflags -DNO__1g_1thread_1init
+
+ local make="emake -f make_linux.mak NO_STRIP=y CC=$(tc-getCC) CXX=$(tc-getCXX)"
+
+ einfo "Building AWT library"
+ export SWT_JAVA_HOME="$(java-config -g JAVA_HOME)"
+ ${make} make_awt AWT_LIBS="-L\$(AWT_LIB_PATH) -Wl,-rpath,\$(AWT_LIB_PATH) -ljawt \`pkg-config --libs x11\`"
+
+ einfo "Building SWT library"
+ ${make} make_swt
+
+ einfo "Building JAVA-AT-SPI bridge"
+ ${make} make_atk
+
+ if use cairo ; then
+ einfo "Building CAIRO support"
+ ${make} make_cairo
+ fi
+
+ if use opengl ; then
+ einfo "Building OpenGL component"
+ ${make} make_glx
+ fi
+
+ if use webkit ; then
+ einfo "Building WebKit component"
+ ${make} make_webkit
+ fi
+
+ java-pkg-simple_src_compile
+}
+
+src_install() {
+ java-pkg-simple_src_install
+
+ java-pkg_sointo "/usr/$(get_libdir)/swt"
+ java-pkg_doso *.so
+}