Boost logo

Boost-Commit :

From: kbelco_at_[hidden]
Date: 2007-09-25 16:34:37


Author: noel_belcourt
Date: 2007-09-25 16:34:36 EDT (Tue, 25 Sep 2007)
New Revision: 39531
URL: http://svn.boost.org/trac/boost/changeset/39531

Log:
Add pgi.hpp configuration file for the Portland Group.

Fixed problems with threading, pic code, missing math
library, etc. to get mipspro toolset working better.

Updated pgi toolset to fix various problems with the
link line.

Added:
   trunk/boost/config/compiler/pgi.hpp (contents, props changed)
Text files modified:
   trunk/boost/config/select_compiler_config.hpp | 5 +++++
   trunk/tools/build/v2/tools/mipspro.jam | 6 +++---
   trunk/tools/build/v2/tools/pgi.jam | 5 +++--
   3 files changed, 11 insertions(+), 5 deletions(-)

Added: trunk/boost/config/compiler/pgi.hpp
==============================================================================
--- (empty file)
+++ trunk/boost/config/compiler/pgi.hpp 2007-09-25 16:34:36 EDT (Tue, 25 Sep 2007)
@@ -0,0 +1,25 @@
+// (C) Copyright Noel Belcourt 2007.
+// Use, modification and distribution are subject to the
+// Boost Software License, Version 1.0. (See accompanying file
+// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
+
+// See http://www.boost.org for most recent version.
+
+// PGI C++ compiler setup:
+
+#define BOOST_COMPILER "PGI compiler version " BOOST_STRINGIZE(_COMPILER_VERSION)
+
+//
+// Threading support:
+// Turn this on unconditionally here, it will get turned off again later
+// if no threading API is detected.
+//
+
+#define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL
+#define BOOST_NO_TWO_PHASE_NAME_LOOKUP
+#define BOOST_NO_SWPRINTF
+
+//
+// version check:
+// probably nothing to do here?
+

Modified: trunk/boost/config/select_compiler_config.hpp
==============================================================================
--- trunk/boost/config/select_compiler_config.hpp (original)
+++ trunk/boost/config/select_compiler_config.hpp 2007-09-25 16:34:36 EDT (Tue, 25 Sep 2007)
@@ -30,6 +30,7 @@
 # define BOOST_CXX_MPW 0
 # define BOOST_CXX_IBMCPP 0
 # define BOOST_CXX_MSVC 0
+# define BOOST_CXX_PGI 0
 
 
 // locate which compiler we are using and define
@@ -95,6 +96,10 @@
 // IBM Visual Age
 # define BOOST_COMPILER_CONFIG "boost/config/compiler/vacpp.hpp"
 
+#elif defined(__PGI)
+// Portland Group Inc.
+# define BOOST_COMPILER_CONFIG "boost/config/compiler/pgi.hpp"
+
 #elif defined _MSC_VER
 // Microsoft Visual C++
 //

Modified: trunk/tools/build/v2/tools/mipspro.jam
==============================================================================
--- trunk/tools/build/v2/tools/mipspro.jam (original)
+++ trunk/tools/build/v2/tools/mipspro.jam 2007-09-25 16:34:36 EDT (Tue, 25 Sep 2007)
@@ -67,11 +67,10 @@
 flags mipspro.compile OPTIONS <debug-symbols>on : -g ;
 # flags mipspro.compile OPTIONS <profiling>on : -xprofile=tcov ;
 flags mipspro.compile OPTIONS <warnings>off : -w ;
-flags mipspro.compile OPTIONS <warnings>on : -ansiW ;
+flags mipspro.compile OPTIONS <warnings>on : -ansiW -diag_suppress 1429 ; # suppress long long is nonstandard warning
 flags mipspro.compile OPTIONS <warnings>all : -fullwarn ;
 flags mipspro.compile OPTIONS <optimization>speed : -Ofast ;
 flags mipspro.compile OPTIONS <optimization>space : -O2 ;
-# flags mipspro.compile OPTIONS <threading>multi : -mt ;
 flags mipspro.compile OPTIONS <cflags> : -LANG:std ;
 flags mipspro.compile.c++ OPTIONS <inlining>off : -INLINE:none ;
 flags mipspro.compile.c++ OPTIONS <cxxflags> ;
@@ -112,6 +111,7 @@
 flags mipspro.link LINKPATH <library-path> ;
 flags mipspro.link FINDLIBS-ST <find-static-library> ;
 flags mipspro.link FINDLIBS-SA <find-shared-library> ;
+flags mipspro.link FINDLIBS-SA <threading>multi : pthread ;
 flags mipspro.link LIBRARIES <library-file> ;
 flags mipspro.link LINK-RUNTIME <runtime-link>static : static ;
 flags mipspro.link LINK-RUNTIME <runtime-link>shared : dynamic ;
@@ -124,7 +124,7 @@
 
 actions link bind LIBRARIES
 {
- "$(CONFIG_COMMAND)" -FE:template_in_elf_section -ptused $(OPTIONS) -L"$(LINKPATH)" -R"$(RPATH)" -o "$(<)" "$(>)" "$(LIBRARIES)" -Bdynamic -l$(FINDLIBS-SA) -Bstatic -l$(FINDLIBS-ST) -B$(LINK-RUNTIME)
+ "$(CONFIG_COMMAND)" -FE:template_in_elf_section -ptused $(OPTIONS) -L"$(LINKPATH)" -R"$(RPATH)" -o "$(<)" "$(>)" "$(LIBRARIES)" -Bdynamic -l$(FINDLIBS-SA) -Bstatic -l$(FINDLIBS-ST) -B$(LINK-RUNTIME) -lm
 }
 
 # Slight mods for dlls

Modified: trunk/tools/build/v2/tools/pgi.jam
==============================================================================
--- trunk/tools/build/v2/tools/pgi.jam (original)
+++ trunk/tools/build/v2/tools/pgi.jam 2007-09-25 16:34:36 EDT (Tue, 25 Sep 2007)
@@ -88,11 +88,12 @@
 # Strip the binary when no debugging is needed
 flags pgi.link OPTIONS <debug-symbols>off : -s ;
 flags pgi.link OPTIONS <profiling>on : -xprofile=tcov ;
-# flags pgi.link OPTIONS <threading>multi : -mt ;
 flags pgi.link OPTIONS <linkflags> ;
+flags pgi.link OPTIONS <link>shared : -fpic ;
 flags pgi.link LINKPATH <library-path> ;
 flags pgi.link FINDLIBS-ST <find-static-library> ;
 flags pgi.link FINDLIBS-SA <find-shared-library> ;
+flags pgi.link FINDLIBS-SA <threading>multi : pthread ;
 flags pgi.link LIBRARIES <library-file> ;
 flags pgi.link LINK-RUNTIME <runtime-link>static : static ;
 flags pgi.link LINK-RUNTIME <runtime-link>shared : dynamic ;
@@ -115,7 +116,7 @@
 # "$(CONFIG_COMMAND)" $(OPTIONS) -L"$(LINKPATH)" -R"$(RPATH)" -o "$(<)" "$(>)" "$(LIBRARIES)" -Bdynamic -l$(FINDLIBS-SA) -Bstatic -l$(FINDLIBS-ST) -B$(LINK-RUNTIME)
 actions link bind LIBRARIES
 {
- "$(CONFIG_COMMAND)" $(OPTIONS) -L"$(LINKPATH)" -R"$(RPATH)" -o "$(<)" "$(>)" "$(LIBRARIES)" -Bstatic -l$(FINDLIBS-ST)
+ "$(CONFIG_COMMAND)" $(OPTIONS) -L"$(LINKPATH)" -R"$(RPATH)" -o "$(<)" "$(>)" "$(LIBRARIES)" -Bstatic -l$(FINDLIBS-ST) -Bdynamic -l$(FINDLIBS-SA) -B$(LINK-RUNTIME)
 }
 
 # Slight mods for dlls


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk