The issue you have here is that clang is trying to build c++14 software against 
the standard headers for the old libstdc++ that comes with Leopard. That can't 
work.

Leopard Intel would usually default to gcc7, which will use it's newer 
libstdc++ by default.

You're trying it with clang-7.0, so it needs to be told to use newer headers by 
setting "-stdlib=" to either libc++ (which you are not using) or 
macports-libstdc++, which we added to clang to allow it to use the newer gcc 
headers.

All this is done in base, but it makes certain assumptions in so doing. There 
should be a setting in the Portfile "compiler.cxx_standard 2014" that forces 
base to add the proper flags if clang is the compiler, but here things are 
relatively less tested on < 10.6 on Intel.

So try gcc7, short answer. If gcc7 doesn't work, then we'll need to see why 
base isn't setting the proper flags. Make sure base is current, of course.

Best, Ken

On Oct 6, 2020, at 05:05, Riccardo Mottola via macports-users 
<macports-users@lists.macports.org> wrote:

> Hi,
> 
> I am updateing ports on my 10.5 i386-64 MacBook (that first, then i386 and 
> last PPC will follow, given the increasing difficulties).
> I fail on poppler, while using clang.
> 
> [  1%] Building CXX object CMakeFiles/poppler.dir/goo/GooString.cc.o
> /opt/local/bin/clang++-mp-7.0 -Dpoppler_EXPORTS 
> -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_graphics_poppler/poppler/work/poppler-20.09.0
>  
> -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_graphics_poppler/poppler/work/poppler-20.09.0/fofi
>  
> -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_graphics_poppler/poppler/work/poppler-20.09.0/goo
>  
> -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_graphics_poppler/poppler/work/poppler-20.09.0/poppler
>  
> -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_graphics_poppler/poppler/work/build
>  
> -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_graphics_poppler/poppler/work/build/poppler
>  -isystem /opt/local/include -isystem /opt/local/include/freetype2 -isystem 
> /opt/local/include/openjpeg-2.3 -isystem /opt/local/include/nss -isystem 
> /opt/local/include/nspr -Wall -Wextra -Wpedantic -Wno-unused-parameter 
> -Wcast-align -Wformat-security -Wframe-larger-than=65536 
> -Wmissing-format-attribute -Wnon-virtual-dtor -Woverloaded-virtual 
> -Wmissing-declarations -Wundef -Wzero-as-null-pointer-constant -Wshadow 
> -fno-exceptions -fno-check-new -fno-common -D_DEFAULT_SOURCE -arch x86_64 
> -mmacosx-version-min=10.5 -fPIC -std=c++14 -o 
> CMakeFiles/poppler.dir/goo/GooString.cc.o -c 
> /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_graphics_poppler/poppler/work/poppler-20.09.0/goo/GooString.cc
> In file included from 
> /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_graphics_poppler/poppler/work/poppler-20.09.0/goo/GooString.cc:48:
> In file included from 
> /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_graphics_poppler/poppler/work/poppler-20.09.0/goo/gmem.h:33:
> /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_graphics_poppler/poppler/work/poppler-20.09.0/goo/GooCheckedOps.h:17:10:
>  fatal error: 'type_traits' file not found
> #include <type_traits>
>         ^~~~~~~~~~~~~
> 1 error generated.
> 
> 
> at a first glance, this does not seem like a platform-specific or compiler 
> error issue, what do you think?
> 
> Riccardo
> 

Reply via email to