<pre style='margin:0'>
Ken (kencu) pushed a commit to branch master
in repository macports-ports.
</pre>
<p><a href="https://github.com/macports/macports-ports/commit/863c2072f23b47252a5537d25f2b319a1b27e495">https://github.com/macports/macports-ports/commit/863c2072f23b47252a5537d25f2b319a1b27e495</a></p>
<pre style="white-space: pre; background: #F8F8F8">The following commit(s) were added to refs/heads/master by this push:
<span style='display:block; white-space:pre;color:#404040;'> new 863c2072f23 libreoffice: switch to accepted patch
</span>863c2072f23 is described below
<span style='display:block; white-space:pre;color:#808000;'>commit 863c2072f23b47252a5537d25f2b319a1b27e495
</span>Author: Andrew Udvare <audvare@gmail.com>
AuthorDate: Wed Feb 10 01:48:34 2021 -0500
<span style='display:block; white-space:pre;color:#404040;'> libreoffice: switch to accepted patch
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> Correctly set PYTHON/etc environment variables to force system
</span><span style='display:block; white-space:pre;color:#404040;'> Python
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> See: https://gerrit.libreoffice.org/c/core/+/108486
</span>---
office/libreoffice/Portfile | 18 +++++++++++--
office/libreoffice/files/patch-configure.diff | 37 ++++++++++++++++++---------
2 files changed, 41 insertions(+), 14 deletions(-)
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/office/libreoffice/Portfile b/office/libreoffice/Portfile
</span><span style='display:block; white-space:pre;color:#808080;'>index d5de5a045e7..b95040e348d 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/office/libreoffice/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/office/libreoffice/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -137,7 +137,8 @@ depends_lib-append \
</span> port:xz \
port:zlib
# Try to keep this in sync with the Python portgroup.
<span style='display:block; white-space:pre;background:#ffe0e0;'>-set python_version 38
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+set pyver 3.8
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+set python_version [string index ${pyver} 0][string index ${pyver} end]
</span> depends_run-append \
port:python${python_version} \
port:py${python_version}-lxml
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -163,7 +164,20 @@ pre-configure {
</span> use_xcode yes
# CMS_NO_REGISTER_KEYWORD required for C++17 or newer compiler.
configure.env-append \
<span style='display:block; white-space:pre;background:#ffe0e0;'>- "LCMS2_CFLAGS=-I${prefix}/include -DCMS_NO_REGISTER_KEYWORD=1"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ "LCMS2_CFLAGS=-I${prefix}/include -DCMS_NO_REGISTER_KEYWORD=1" \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ PYTHON=${prefix}/bin/python${pyver}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# PYTHON_CFLAGS and PYTHON_LIBS have to be non-empty
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+set python_cflags [exec pkg-config --cflags python-${pyver}]
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+set python_libs [exec pkg-config --libs python-${pyver}]
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+if {${python_cflags} == ""} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set python_cflags "-I${prefix}/include"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+if {${python_libs} == ""} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set python_libs "-L${prefix}/lib"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+configure.env-append \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ PYTHON_CFLAGS=${python_cflags} \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ PYTHON_LIBS=${python_libs}
</span> # Most arguments are from
# https://wiki.documentfoundation.org/LibreOffice_Vanilla_for_Mac#LibreOffice_Vanilla
configure.args-append \
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/office/libreoffice/files/patch-configure.diff b/office/libreoffice/files/patch-configure.diff
</span><span style='display:block; white-space:pre;color:#808080;'>index d79bac5295e..c6520ddbe9d 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/office/libreoffice/files/patch-configure.diff
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/office/libreoffice/files/patch-configure.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1,25 +1,38 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+From d1dc51f95f9e831aa6adbbeff549c2017d2dfd82 Mon Sep 17 00:00:00 2001
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+From: Andrew Udvare <audvare@gmail.com>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+Date: Tue, 29 Dec 2020 15:18:06 -0500
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+Subject: [PATCH] configure.ac: allow --enable-python=system on macOS if PYTHON is non-empty
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+This will work as long as a valid Python is in PATH, such as /usr/bin/python3
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+from Xcode or another version in some prefix like /opt/local.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+Change-Id: Ic967c3ce2f9949d94c11c3449363841a1565cfa9
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108486
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+Tested-by: Jenkins
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+---
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span> diff --git configure.ac configure.ac
<span style='display:block; white-space:pre;background:#ffe0e0;'>-index e4ef8bec2b3e..402979d77ffe 100644
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+index e660733..78bb799 100644
</span> --- configure.ac
+++ configure.ac
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -8845,10 +8845,6 @@ AC_SUBST(XMLLINT)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -9238,8 +9238,9 @@
</span> # Optionally user can pass an option to configure, i. e.
# ./configure PYTHON=/usr/bin/python
# =====================================================================
-if test $_os = Darwin -a "$enable_python" != no -a "$enable_python" != fully-internal -a "$enable_python" != internal; then
<span style='display:block; white-space:pre;background:#ffe0e0;'>-- # Only allowed choices for macOS are 'no', 'internal' (default), and 'fully-internal'
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-- enable_python=internal
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--fi
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++if test $_os = Darwin -a "$enable_python" != no -a "$enable_python" != fully-internal -a "$enable_python" != internal -a "$enable_python" != system; then
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # Only allowed choices for macOS are 'no', 'internal' (default), and 'fully-internal'
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ # unless PYTHON is defined as above which allows 'system'
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ enable_python=internal
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ fi
</span> if test "$build_os" != "cygwin" -a "$enable_python" != fully-internal; then
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if test -n "$PYTHON"; then
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- PYTHON_FOR_BUILD=$PYTHON
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -8918,9 +8914,6 @@ fully-internal)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -9311,7 +9312,7 @@
</span> ;;
system)
AC_MSG_RESULT([system])
- if test "$_os" = Darwin; then
<span style='display:block; white-space:pre;background:#ffe0e0;'>-- AC_MSG_ERROR([--enable-python=system doesn't work on macOS because the version provided is obsolete])
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-- fi
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ if test "$_os" = Darwin -a -z "$PYTHON"; then
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ AC_MSG_ERROR([--enable-python=system doesn't work on macOS because the version provided is obsolete])
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ fi
</span> ;;
<span style='display:block; white-space:pre;background:#ffe0e0;'>- *)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- AC_MSG_ERROR([Incorrect --enable-python option])
</span></pre><pre style='margin:0'>
</pre>