From 3cda3c1ed52c5e44f6e2a0e6a1e2174793c31b95 Mon Sep 17 00:00:00 2001 From: Eva Isabella Luna Date: Wed, 2 Jul 2025 22:17:07 -0600 Subject: [PATCH] [FIX] xattr command failing for JDK 8 iOS Some versions of macOS on some machines might fail the build when xattr is invoked without sudo. Since the reason xattr is invoked is to help with testing, and the attribute it is removing is not relevant for iOS, this line can be safely removed from the build. --- buildjdk.sh | 1 + patches/jdk8u_ios_xattr.diff | 12 ++++++++++++ 2 files changed, 13 insertions(+) create mode 100644 patches/jdk8u_ios_xattr.diff diff --git a/buildjdk.sh b/buildjdk.sh index c18acca..8e303dd 100755 --- a/buildjdk.sh +++ b/buildjdk.sh @@ -75,6 +75,7 @@ if [[ "$BUILD_IOS" != "1" ]]; then fi else git apply --reject --whitespace=fix ../patches/jdk8u_ios.diff || echo "git apply failed (ios patch set)" + git apply --reject --whitespace=fix ../patches/jdk8u_ios_xattr.diff || echo "git apply failed (ios xattr patch set)" git apply --reject --whitespace=fix ../patches/jdk8u_ios_fix_clang.diff || echo "git apply failed (ios clang fix patch set)" fi diff --git a/patches/jdk8u_ios_xattr.diff b/patches/jdk8u_ios_xattr.diff new file mode 100644 index 0000000..d05fba0 --- /dev/null +++ b/patches/jdk8u_ios_xattr.diff @@ -0,0 +1,12 @@ +diff --git a/make/common/MakeBase.gmk b/make/common/MakeBase.gmk +index f31da150..710db352 100644 +--- a/make/common/MakeBase.gmk ++++ b/make/common/MakeBase.gmk +@@ -375,7 +375,6 @@ else ifeq ($(OPENJDK_TARGET_OS),macosx) + define install-file + $(MKDIR) -p $(@D) + $(CP) -fRP '$<' '$@' +- if [ -n "`$(XATTR) -l '$@'`" ]; then $(XATTR) -c '$@'; fi + endef + else + define install-file