diff --git a/lang/perl5/Portfile b/lang/perl5/Portfile
index 04525a969d9..f704d381ebd 100644
a
|
b
|
foreach {perl5.v perl5.subversion perl5.revision perl5.rmd160 perl5.sha256 perl5 |
140 | 140 | ${perl5.major}/dont-write-invalid-write_buildcustomize.pl.patch \ |
141 | 141 | ${perl5.major}/fallback-to-built-in-getcwd.patch \ |
142 | 142 | } |
| 143 | if {${perl5.major} >= 5.28 && ${perl5.major} <= 5.30} { |
| 144 | ## backport the fix for "macOS 11.x" that went into 5.32.1 |
| 145 | ## see https://github.com/Perl/perl5/pull/17946 |
| 146 | patchfiles-append \ |
| 147 | ${perl5.major}/patch-hints-darwin_sh.diff \ |
| 148 | } |
143 | 149 | |
144 | 150 | post-patch { |
145 | 151 | reinplace -W ${worksrcpath} "s|__PREFIX__|${prefix}|g" \ |
… |
… |
foreach {perl5.v perl5.subversion perl5.revision perl5.rmd160 perl5.sha256 perl5 |
180 | 186 | {-Alddlflags="$LDFLAGS"} \ |
181 | 187 | {-Aldflags="$LDFLAGS"} |
182 | 188 | |
183 | | # Workaround buggy configure scripts that expect 10.x |
184 | | if {[vercmp ${macosx_deployment_target} 11.0] >= 0} { |
185 | | macosx_deployment_target 10.16 |
186 | | } |
187 | | if {${os.major} >= 20} { |
188 | | configure.env-append SYSTEM_VERSION_COMPAT=1 |
| 189 | ## perl5.28 and 5.30 will compile on macOS 11.3 / Xcode 12.5 with |
| 190 | ## the above patch-hints-darwin_sh.diff, and perl5.32(.1) has |
| 191 | ## the fix in that patch included. So only use the below |
| 192 | ## work-around for "bugging configure scripts" for perl < 5.28 |
| 193 | if {${perl5.major} < 5.28} { |
| 194 | # Workaround buggy configure scripts that expect 10.x |
| 195 | if {[vercmp ${macosx_deployment_target} 11.0] >= 0} { |
| 196 | macosx_deployment_target 10.16 |
| 197 | } |
| 198 | if {${os.major} >= 20} { |
| 199 | configure.env-append SYSTEM_VERSION_COMPAT=1 |
| 200 | } |
189 | 201 | } |
190 | 202 | |
191 | 203 | post-configure { |