Skip to content

Commit 4af982e

Browse files
committed
lang/python3(6|7|8|9|10|11): work around unwanted multiarch detection again
In ports 6bef096 we patched out python's erroneous multiarch detection using sed, but upstream changed the surrounding parts in the configure script to defeat the regex we were using. Update the regex to cope with the change. PR: 259896, 258377 MFH: 2021Q4 Approved by: maintainer timeout (9 days)
1 parent 48c9377 commit 4af982e

6 files changed

Lines changed: 6 additions & 12 deletions

File tree

lang/python310/Makefile

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -127,8 +127,7 @@ post-patch:
127127
@${REINPLACE_CMD} -e '/find_library_file/ s|uuid|ignore_&|' ${WRKSRC}/setup.py
128128
# disable detection of multiarch as it breaks with clang >= 13, which adds a
129129
# major.minor version number in -print-multiarch output, confusing Python
130-
@${REINPLACE_CMD} -e 's|^MULTIARCH=.*|MULTIARCH=|' ${WRKSRC}/configure \
131-
${WRKSRC}/configure.ac
130+
@${REINPLACE_CMD} -e 's|^\( *MULTIARCH=\).*--print-multiarch.*|\1|' ${WRKSRC}/configure
132131
# Apply DISABLED_EXTENSIONS
133132
@${ECHO_CMD} '*disabled*' > ${WRKSRC}/Modules/Setup.local
134133
. for _module in ${DISABLED_EXTENSIONS}

lang/python311/Makefile

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -126,8 +126,7 @@ post-patch:
126126
@${REINPLACE_CMD} -e '/find_library_file/ s|uuid|ignore_&|' ${WRKSRC}/setup.py
127127
# disable detection of multiarch as it breaks with clang >= 13, which adds a
128128
# major.minor version number in -print-multiarch output, confusing Python
129-
@${REINPLACE_CMD} -e 's|^MULTIARCH=.*|MULTIARCH=|' ${WRKSRC}/configure \
130-
${WRKSRC}/configure.ac
129+
@${REINPLACE_CMD} -e 's|^\( *MULTIARCH=\).*--print-multiarch.*|\1|' ${WRKSRC}/configure
131130
# Apply DISABLED_EXTENSIONS
132131
@${ECHO_CMD} '*disabled*' > ${WRKSRC}/Modules/Setup.local
133132
. for _module in ${DISABLED_EXTENSIONS}

lang/python36/Makefile

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -128,8 +128,7 @@ PLIST_SUB+= NO_NIS=""
128128
post-patch:
129129
# disable detection of multiarch as it breaks with clang >= 13, which adds a
130130
# major.minor version number in -print-multiarch output, confusing Python
131-
@${REINPLACE_CMD} -e 's|^MULTIARCH=.*|MULTIARCH=|' ${WRKSRC}/configure \
132-
${WRKSRC}/configure.ac
131+
@${REINPLACE_CMD} -e 's|^\( *MULTIARCH=\).*--print-multiarch.*|\1|' ${WRKSRC}/configure
133132

134133
post-install:
135134
.if ! ${PORT_OPTIONS:MDEBUG}

lang/python37/Makefile

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -114,8 +114,7 @@ post-patch:
114114
@${REINPLACE_CMD} -e '/find_library_file/ s|uuid|ignore_&|' ${WRKSRC}/setup.py
115115
# disable detection of multiarch as it breaks with clang >= 13, which adds a
116116
# major.minor version number in -print-multiarch output, confusing Python
117-
@${REINPLACE_CMD} -e 's|^MULTIARCH=.*|MULTIARCH=|' ${WRKSRC}/configure \
118-
${WRKSRC}/configure.ac
117+
@${REINPLACE_CMD} -e 's|^\( *MULTIARCH=\).*--print-multiarch.*|\1|' ${WRKSRC}/configure
119118
# Apply DISABLED_EXTENSIONS
120119
@${ECHO_CMD} '*disabled*' > ${WRKSRC}/Modules/Setup.local
121120
. for _module in ${DISABLED_EXTENSIONS}

lang/python38/Makefile

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -118,8 +118,7 @@ post-patch:
118118
@${REINPLACE_CMD} -e '/find_library_file/ s|uuid|ignore_&|' ${WRKSRC}/setup.py
119119
# disable detection of multiarch as it breaks with clang >= 13, which adds a
120120
# major.minor version number in -print-multiarch output, confusing Python
121-
@${REINPLACE_CMD} -e 's|^MULTIARCH=.*|MULTIARCH=|' ${WRKSRC}/configure \
122-
${WRKSRC}/configure.ac
121+
@${REINPLACE_CMD} -e 's|^\( *MULTIARCH=\).*--print-multiarch.*|\1|' ${WRKSRC}/configure
123122
# Apply DISABLED_EXTENSIONS
124123
@${ECHO_CMD} '*disabled*' > ${WRKSRC}/Modules/Setup.local
125124
. for _module in ${DISABLED_EXTENSIONS}

lang/python39/Makefile

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -118,8 +118,7 @@ post-patch:
118118
@${REINPLACE_CMD} -e '/find_library_file/ s|uuid|ignore_&|' ${WRKSRC}/setup.py
119119
# disable detection of multiarch as it breaks with clang >= 13, which adds a
120120
# major.minor version number in -print-multiarch output, confusing Python
121-
@${REINPLACE_CMD} -e 's|^MULTIARCH=.*|MULTIARCH=|' ${WRKSRC}/configure \
122-
${WRKSRC}/configure.ac
121+
@${REINPLACE_CMD} -e 's|^\( *MULTIARCH=\).*--print-multiarch.*|\1|' ${WRKSRC}/configure
123122
# Apply DISABLED_EXTENSIONS
124123
@${ECHO_CMD} '*disabled*' > ${WRKSRC}/Modules/Setup.local
125124
. for _module in ${DISABLED_EXTENSIONS}

0 commit comments

Comments
 (0)