[MacPorts] #62440: perl5: invalid SDK path hardcoded on macOS 11

MacPorts noreply at macports.org
Sat Jun 26 20:29:44 UTC 2021


#62440: perl5: invalid SDK path hardcoded on macOS 11
---------------------------+----------------------
  Reporter:  chrstphrchvz  |      Owner:  mojca
      Type:  defect        |     Status:  assigned
  Priority:  Normal        |  Milestone:
 Component:  ports         |    Version:
Resolution:                |   Keywords:
      Port:  perl5         |
---------------------------+----------------------

Comment (by mojca):

 I have a question for other mac gurus (I haven't been following version 11
 too closely). Perl is currently built in the following way:
 {{{
 CC='/usr/bin/clang'
 CC_PRINT_OPTIONS='YES'
 CC_PRINT_OPTIONS_FILE='/path/to/perl5.32/work/.CC_PRINT_OPTIONS'
 CFLAGS='-pipe -Os
 -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX11.sdk -arch
 arm64'
 CPATH='/opt/local/include'
 CPPFLAGS='-I/opt/local/include
 -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX11.sdk'
 CXX='/usr/bin/clang++'
 CXXFLAGS='-pipe -Os -stdlib=libc++
 -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX11.sdk -arch
 arm64'
 DEVELOPER_DIR='/Library/Developer/CommandLineTools'
 F90FLAGS='-pipe -Os -m64'
 FCFLAGS='-pipe -Os -m64'
 FFLAGS='-pipe -Os -m64'
 INSTALL='/usr/bin/install -c'
 LC_ALL='C'
 LDFLAGS='-L/opt/local/lib -Wl,-headerpad_max_install_names
 -Wl,-syslibroot,/Library/Developer/CommandLineTools/SDKs/MacOSX11.sdk
 -arch arm64'
 LIBRARY_PATH='/opt/local/lib'
 MACOSX_DEPLOYMENT_TARGET='11.0'
 OBJC='/usr/bin/clang'
 OBJCFLAGS='-pipe -Os
 -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX11.sdk -arch
 arm64'
 OBJCXX='/usr/bin/clang++'
 OBJCXXFLAGS='-pipe -Os -stdlib=libc++
 -isysroot/Library/Developer/CommandLineTools/SDKs/MacOSX11.sdk -arch
 arm64'
 SDKROOT='/Library/Developer/CommandLineTools/SDKs/MacOSX11.sdk'
 Executing:  cd "/path/to/perl5.32/work/perl-5.32.1" && sh Configure -des
 -Dprefix='/opt/local' -Dscriptdir='/opt/local/bin'
 -Dvendorprefix='/opt/local' -Dusemultiplicity=y -Dusethreads -Duseshrplib
 -Dcc="$CC" -Dman1ext=1pm -Dman3ext=3pm -Dinstallstyle='lib/perl5'
 -Dman1dir='/opt/local/share/man/man1p'
 -Dman3dir='/opt/local/share/man/man3p'
 -Dsitebin='/opt/local/libexec/perl5.32/sitebin'
 -Dsiteman1dir='/opt/local/share/perl5.32/siteman/man1'
 -Dsiteman3dir='/opt/local/share/perl5.32/siteman/man3'
 -Dvendorbin='/opt/local/libexec/perl5.32'
 -Dvendorman1dir='/opt/local/share/perl5.32/man/man1'
 -Dvendorman3dir='/opt/local/share/perl5.32/man/man3'
 -Dpager='/usr/bin/less -sR' -Dperlpath="/opt/local/bin/perl5.32"
 -Dstartperl="#!/opt/local/bin/perl5.32" -Acppflags="$CPPFLAGS"
 -Accflags="$CFLAGS" -Alddlflags="$LDFLAGS" -Aldflags="$LDFLAGS"
 }}}

 My questions are as follows:
 * Is passing `/Library/Developer/CommandLineTools/SDKs/MacOSX11.sdk` in
 fact needed in order build (any given) software correctly or is it there
 "just in case"?
 * I see that we are now passing `MacOSX11.sdk` to compiler flags (which is
 just a symlink to `MacOSX11.x.sdk`), while this used to be
 `MacOSX11.0.sdk` at the time when perl was built. Wouldn't thus this
 problem be fixed without any further changes if we simply revbumped perl?

 I'm not saying that this doesn't need to be addressed at some point, I'm
 just trying to find some quick solution to overcome the painful problem on
 macOS 11.

 I opened an upstream ticket:
 * https://github.com/Perl/perl5/issues/18939

-- 
Ticket URL: <https://trac.macports.org/ticket/62440#comment:7>
MacPorts <https://www.macports.org/>
Ports system for macOS


More information about the macports-tickets mailing list