[Libreoffice-commits] core.git: configure.ac external/firebird external/nss

2022-02-25 Thread Stephan Bergmann (via logerrit)
 configure.ac  |   16 
 external/firebird/ExternalProject_firebird.mk |1 -
 external/nss/ExternalProject_nss.mk   |3 +--
 3 files changed, 5 insertions(+), 15 deletions(-)

New commits:
commit b1d500e8a4eadb72d0e574f77ebf33fbc5701900
Author: Stephan Bergmann 
AuthorDate: Thu Feb 24 17:37:26 2022 +0100
Commit: Stephan Bergmann 
CommitDate: Fri Feb 25 13:45:38 2022 +0100

Drop support for $host_os = 'macos*', in addition to 'darwin*'

...which had originally been added with 
baab4f890c8ac99d1b8dab5790fbb7ab949100ab
"Initial WIP steps for building for macOS on Apple Silicon" for unclear 
reasons
(just stating "use 'darwin' (or 'macos')" in the commit message), and then
further improved with 5a0991c9cd60b6ab10fe0665511e7749a0c0ecc2 "mac: allow 
cross
compiling with host/build x86_64-apple-macos".

But it turns out that manually specifying --host or --build =...-macos 
rather
than =...-darwin has issues as discussed in the comments at
 "icu: override platform 
flags
for MacOS build", and which can hopefully be avoided by not allowing 
=...-macos
in the first place, and rather forcing people to specify =...-darwin.

Change-Id: Ib100b7270250083eba4146430e967073a8cbca46
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130505
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann 

diff --git a/configure.ac b/configure.ac
index f7ba69d78d9e..accb60493657 100644
--- a/configure.ac
+++ b/configure.ac
@@ -956,7 +956,7 @@ cygwin*|wsl*)
 fi
 ;;
 
-darwin*|macos*) # macOS
+darwin*) # macOS
 using_freetype_fontconfig=no
 using_x11=no
 build_skia=yes
@@ -982,14 +982,6 @@ darwin*|macos*) # macOS
 LINKFLAGSNOUNDEFS=""
 case "$host_cpu" in
 aarch64|arm64)
-case "$host_os" in
-macos*)
-# HOST_PLATFORM is used for external projects and their configury 
occasionally doesn't like
-# the "macos" part so be sure to use aarch64-apple-darwin for now.
-HOST_PLATFORM=aarch64-apple-darwin
-;;
-esac
-
 # Apple's Clang uses "arm64"
 host_cpu_for_clang=arm64
 esac
@@ -4933,7 +4925,7 @@ cygwin*|wsl*)
 # Already handled
 ;;
 
-darwin*|macos*)
+darwin*)
 COM=GCC
 OS=MACOSX
 RTL_OS=MacOSX
@@ -8844,7 +8836,7 @@ if test -n "$ENABLE_JAVA" -a -z "$JAVAINC"; then
 JAVAINC="$JAVAINC -I$JAVA_HOME/include"
 ;;
 
-darwin*|macos*)
+darwin*)
 if test -d "$JAVA_HOME/include/darwin"; then
 JAVAINC="-I$JAVA_HOME/include  -I$JAVA_HOME/include/darwin"
 else
@@ -11536,7 +11528,7 @@ elif $GNUCP --version 2>/dev/null | grep "GNU 
fileutils" >/dev/null 2>/dev/null;
 AC_MSG_RESULT([yes])
 else
 case "$build_os" in
-darwin*|macos*|netbsd*|openbsd*|freebsd*|dragonfly*|aix*)
+darwin*|netbsd*|openbsd*|freebsd*|dragonfly*|aix*)
 x_GNUCP=[\#]
 GNUCP=''
 AC_MSG_RESULT([no gnucp found - using the system's cp command])
diff --git a/external/firebird/ExternalProject_firebird.mk 
b/external/firebird/ExternalProject_firebird.mk
index 0d5534aeccbb..9c28d5641ef0 100644
--- a/external/firebird/ExternalProject_firebird.mk
+++ b/external/firebird/ExternalProject_firebird.mk
@@ -77,7 +77,6 @@ $(call gb_ExternalProject_get_state_target,firebird,build):
--enable-shared --disable-static \
) \
$(if $(filter MACOSX,$(OS)), \
-   --build=$(subst macos,darwin,$(BUILD_PLATFORM)) 
--host=$(subst macos,darwin,$(HOST_PLATFORM)) \
$(if $(filter 1, \
$(shell expr 
'$(MAC_OS_X_VERSION_MIN_REQUIRED)' \
'<' 101200)), \
diff --git a/external/nss/ExternalProject_nss.mk 
b/external/nss/ExternalProject_nss.mk
index 9213d76b713f..b9f953f3649b 100644
--- a/external/nss/ExternalProject_nss.mk
+++ b/external/nss/ExternalProject_nss.mk
@@ -62,8 +62,7 @@ $(call gb_ExternalProject_get_state_target,nss,build): \
NSPR_CONFIGURE_OPTS="$(gb_CONFIGURE_PLATFORMS)" \
$(if $(CROSS_COMPILING),CROSS_COMPILE=1) \
$(if $(filter MACOSX-X86_64-arm64,$(OS)-$(CPUNAME)-$(shell 
uname -m)), \
-   CPU_ARCH=x86_64 \
-   NSPR_CONFIGURE_OPTS="--build=$(subst 
macos,darwin,$(BUILD_PLATFORM)) --host=$(subst macos,darwin,$(HOST_PLATFORM))") 
\
+   CPU_ARCH=x86_64) \
NSDISTMODE=copy \
$(MAKE) \
AR="$(AR)" \


[Libreoffice-commits] core.git: configure.ac external/firebird external/nss

2021-01-28 Thread Christian Lohmaier (via logerrit)
 configure.ac  |4 ++--
 external/firebird/ExternalProject_firebird.mk |1 +
 external/nss/ExternalProject_nss.mk   |2 +-
 3 files changed, 4 insertions(+), 3 deletions(-)

New commits:
commit 5a0991c9cd60b6ab10fe0665511e7749a0c0ecc2
Author: Christian Lohmaier 
AuthorDate: Thu Jan 28 21:15:02 2021 +0100
Commit: Christian Lohmaier 
CommitDate: Thu Jan 28 23:11:59 2021 +0100

mac: allow cross compiling with host/build x86_64-apple-macos

apple silicon supports to cross compile without special build-tools/full
cross-compiling setup, so just always pass the build/host for firebird.
firebird and nss don't recognize the -macos specifier, so substitute it
by -darwin to make those happy…

Change-Id: I953317fc87da2a20dc91acd88c8528796c3b2a69
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110093
Tested-by: Jenkins
Reviewed-by: Christian Lohmaier 

diff --git a/configure.ac b/configure.ac
index aad842d03768..75f5543703f2 100644
--- a/configure.ac
+++ b/configure.ac
@@ -8332,7 +8332,7 @@ if test -n "$ENABLE_JAVA" -a -z "$JAVAINC"; then
 JAVAINC="$JAVAINC -I$JAVA_HOME/include"
 ;;
 
-darwin*)
+darwin*|macos*)
 if test -d "$JAVA_HOME/include/darwin"; then
 JAVAINC="-I$JAVA_HOME/include  -I$JAVA_HOME/include/darwin"
 else
@@ -11123,7 +11123,7 @@ elif $GNUCP --version 2>/dev/null | grep "GNU 
fileutils" >/dev/null 2>/dev/null;
 AC_MSG_RESULT([yes])
 else
 case "$build_os" in
-darwin*|netbsd*|openbsd*|freebsd*|dragonfly*|aix*)
+darwin*|macos*|netbsd*|openbsd*|freebsd*|dragonfly*|aix*)
 x_GNUCP=[\#]
 GNUCP=''
 AC_MSG_RESULT([no gnucp found - using the system's cp command])
diff --git a/external/firebird/ExternalProject_firebird.mk 
b/external/firebird/ExternalProject_firebird.mk
index 0a1706031746..2a491d965699 100644
--- a/external/firebird/ExternalProject_firebird.mk
+++ b/external/firebird/ExternalProject_firebird.mk
@@ -76,6 +76,7 @@ $(call gb_ExternalProject_get_state_target,firebird,build):
--enable-shared --disable-static \
) \
$(if $(filter MACOSX,$(OS)), \
+   --build=$(subst macos,darwin,$(BUILD_PLATFORM)) 
--host=$(subst macos,darwin,$(HOST_PLATFORM)) \
$(if $(filter 1, \
$(shell expr 
'$(MAC_OS_X_VERSION_MIN_REQUIRED)' \
'<' 101200)), \
diff --git a/external/nss/ExternalProject_nss.mk 
b/external/nss/ExternalProject_nss.mk
index ef2ae95d7a5f..fb68da65adff 100644
--- a/external/nss/ExternalProject_nss.mk
+++ b/external/nss/ExternalProject_nss.mk
@@ -63,7 +63,7 @@ $(call gb_ExternalProject_get_state_target,nss,build): \
NSPR_CONFIGURE_OPTS="--build=$(BUILD_PLATFORM) 
--host=$(HOST_PLATFORM)") \
$(if $(filter MACOSX-X86_64-arm64,$(OS)-$(CPUNAME)-$(shell 
uname -m)), \
CPU_ARCH=x86_64 \
-   NSPR_CONFIGURE_OPTS="--build=$(BUILD_PLATFORM) 
--host=$(HOST_PLATFORM)") \
+   NSPR_CONFIGURE_OPTS="--build=$(subst 
macos,darwin,$(BUILD_PLATFORM)) --host=$(subst macos,darwin,$(HOST_PLATFORM))") 
\
NSDISTMODE=copy \
$(MAKE) \
AR="$(AR)" \
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits