From 9dce22ab8acbc19334df167e0f22b80366dc2616 Mon Sep 17 00:00:00 2001 From: John Marino Date: Sat, 4 Feb 2012 11:37:42 +0100 Subject: [PATCH] custom cc script: Use gcc46's c++ library instead of base There will be a slight performance hit with having to make two calls to gnatc++ before every real call in order to use gnat-aux's c++ library rather than the base systems gcc 4.4 c++ library. The alternative is hardcoding these values as a function of arch which is less appealing. --- libexec/customcc/cc.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/libexec/customcc/cc.sh b/libexec/customcc/cc.sh index 2acb4c7c07..55c601a541 100644 --- a/libexec/customcc/cc.sh +++ b/libexec/customcc/cc.sh @@ -35,10 +35,13 @@ elif [ "${CCVER}" = "clangsvn" ]; then -isystem /usr/include/c++/4.4" fi elif [ "${CCVER}" = "gcc46" ]; then + GCC46VER=`gnatc++ -dumpversion` + GCC46MAC=`gnatc++ -dumpmachine` INCOPT="-nostdinc \ -isysroot @@INCPREFIX@@ \ -isystem /usr/include \ - -isystem /usr/include/c++/4.4" + -isystem /usr/pkg/include/c++/${GCC46VER} \ + -isystem /usr/pkg/include/c++/${GCC46VER}/${GCC46MAC}" fi . /etc/defaults/compilers.conf -- 2.41.0