From 1a5e8d816de76f7ebcdc29e755448a4836190249 Mon Sep 17 00:00:00 2001 From: André Draszik Date: Mon, 5 Mar 2018 09:30:56 +0000 Subject: openjdk-8: rework do_patch (pt 1 - X11 wrappers) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X11 wrappers are currently being deleted using a custom do_patch[postfuncs]. This is confusing to say the least, as e.g. naming implies this is done after ./configure has run. At the moment, this also happens halfway through patches have been applied, i.e. some patches are being applied, then the X11 wrappers are deleted, then more patches are being applied. Streamline this so that the unneeded wrappers are removed as part of do_unpack[postfuncs]. Signed-off-by: André Draszik Signed-off-by: Maxin B. John --- recipes-core/openjdk/openjdk-8-common.inc | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/recipes-core/openjdk/openjdk-8-common.inc b/recipes-core/openjdk/openjdk-8-common.inc index ab4c870..cf14be9 100644 --- a/recipes-core/openjdk/openjdk-8-common.inc +++ b/recipes-core/openjdk/openjdk-8-common.inc @@ -39,6 +39,10 @@ do_unpack_extract_submodules () { tar xjf ${WORKDIR}/${NASHORN_FILE} --transform "s,-${NASHORN_CHANGESET},,g" } +do_unpack_remove_X11_wrappers() { + find ${S}/jdk/src/solaris/classes/sun/awt/X11 -maxdepth 1 -name '*.java' -delete +} + def package_config_option_cleanup(d): distro_x11 = bb.utils.contains('DISTRO_FEATURES', 'x11', True, False, d) distro_alsa = bb.utils.contains('DISTRO_FEATURES', 'alsa', True, False, d) @@ -149,13 +153,11 @@ def jdk_configure_options(d): return options[3] do_unpack[postfuncs] += "do_unpack_extract_submodules" - -POST_CONFIGURE_CLEAN_X11 = "${@bb.utils.contains('PACKAGECONFIG', 'x11', '', 'rm -f jdk/src/solaris/classes/sun/awt/X11/*.java', d)}" +do_unpack[postfuncs] += "${@bb.utils.contains('PACKAGECONFIG', 'x11', '', 'do_unpack_remove_X11_wrappers', d)}" do_patch_openjdk8() { olddir=`pwd` cd "${S}" - ${POST_CONFIGURE_CLEAN_X11} for OJ8P in ${WORKDIR}/openjdk8-*.patch; do patch -p0 < ${OJ8P} done -- cgit v1.2.3-54-g00ecf