[MacPorts] #57615: p5-wx uses libc++ when it shouldn't, resulting in fatal error: 'tr1/type_traits' file not found

MacPorts noreply at macports.org
Fri Nov 16 12:18:13 UTC 2018


#57615: p5-wx uses libc++ when it shouldn't, resulting in fatal error:
'tr1/type_traits' file not found
-------------------------+----------------------
  Reporter:  ryandesign  |      Owner:  mojca
      Type:  defect      |     Status:  assigned
  Priority:  Normal      |  Milestone:
 Component:  ports       |    Version:
Resolution:              |   Keywords:
      Port:  p5-wx       |
-------------------------+----------------------

Comment (by mojca):

 OK, the file `build/Wx/build/MakeMaker/MacOSX_GCC.pm` contains a lot of
 strange stuff:
 {{{
 if ($ENV{MACOSX_DEPLOYMENT_TARGET}) {
   my ($dt0, $dt1, @discard) =
 split(/[^0-9]+/,$ENV{MACOSX_DEPLOYMENT_TARGET} );
   if (($dt0 <= 10) && ( $dt1 < 3 )) {
         die "Please set MACOSX_DEPLOYMENT_TARGET to 10.3 or above";
   }
 }

 my $tools43 = '/Applications/Xcode.app/Contents/Developer/Tools';
 my $restoolpath = ( -d $tools43 ) ? $tools43 : '/Developer/Tools';

 sub get_flags {
   my $this = shift;
   my %config = $this->SUPER::get_flags;

   if ($config{CC} =~ /clang\+\+/ || $config{LD} =~ /clang\+\+/) {
         my $sdkrepl = '';
     # Get ahead with the xcode versions. It'll be wrong, but better than
 not
     # finding at all.
         for my $sdkversion ( qw( 10.14 10.13 10.12 10.11 10.10 10.9 10.8
 10.7 10.6 ) ) {
           my $macossdk =
 qq(/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX${sdkversion}.sdk);
           if( -d $macossdk ) {
                 $sdkrepl = 'clang++ -isysroot ' . $macossdk . '
 -stdlib=libc++';
                 last;
           }
         }
         if ( $sdkrepl ) {
           $config{CC} =~ s/clang\+\+/$sdkrepl/g;
           $config{LD} =~ s/clang\+\+/$sdkrepl/g;
         }
   }
   return %config;
 }
 }}}

 This definitely needs fixing.

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


More information about the macports-tickets mailing list