Boost logo

Boost-Commit :

From: kbelco_at_[hidden]
Date: 2007-12-04 18:18:38


Author: noel_belcourt
Date: 2007-12-04 18:18:38 EST (Tue, 04 Dec 2007)
New Revision: 41707
URL: http://svn.boost.org/trac/boost/changeset/41707

Log:
Fixes to get pgi shared libraries working, executables
that don't core, and limiting the number of error
messages emitted by the compiler so as to reduce the
size of the log file.

Text files modified:
   trunk/tools/build/v2/tools/pgi.jam | 13 +++++++++++--
   1 files changed, 11 insertions(+), 2 deletions(-)

Modified: trunk/tools/build/v2/tools/pgi.jam
==============================================================================
--- trunk/tools/build/v2/tools/pgi.jam (original)
+++ trunk/tools/build/v2/tools/pgi.jam 2007-12-04 18:18:38 EST (Tue, 04 Dec 2007)
@@ -11,6 +11,7 @@
 import fortran ;
 import type ;
 import common ;
+import gcc ;
 
 feature.extend toolset : pgi ;
 toolset.inherit pgi : unix ;
@@ -41,6 +42,8 @@
 
   flags pgi.link FINDLIBS-SA : [
     feature.get-values <find-shared-library> : $(options) ] : unchecked ;
+
+ gcc.init-link-flags pgi gnu $(condition) ;
 }
 
 # Declare generators
@@ -50,7 +53,7 @@
 
 # Declare flags and actions for compilation
 flags pgi.compile OPTIONS : -Kieee ;
-flags pgi.compile OPTIONS <link>shared : -shared -fpic ;
+flags pgi.compile OPTIONS <link>shared : -fpic ;
 flags pgi.compile OPTIONS <debug-symbols>on : -g ;
 flags pgi.compile OPTIONS <profiling>on : -xprofile=tcov ;
 flags pgi.compile OPTIONS <optimization>speed : -fast -Mx,8,0x10000000 ;
@@ -124,13 +127,19 @@
 rule link.dll ( targets * : sources * : properties * )
 {
     SPACE on $(targets) = " " ;
+ # pgi can't link with lib*-d-1_35.so.1.35.0
+ # requires a library file name suffix that it recognizes (.so, .a)
+ # give them what they want (library ending in .so)
+ local grist = $(targets:G) ;
+ local lt = [ MATCH "$(grist)(.*.so).*" : $(targets) ] ;
+ targets = $(grist)$(lt) ;
 }
 
 # "$(CONFIG_COMMAND)" $(OPTIONS) -L"$(LINKPATH)" -R"$(RPATH)" -o "$(<)" -h$(<[1]:D=) -G "$(>)" "$(LIBRARIES)" -Bdynamic -l$(FINDLIBS-SA) -Bstatic -l$(FINDLIBS-ST) -B$(LINK-RUNTIME)
 
 actions link.dll bind LIBRARIES
 {
- "$(CONFIG_COMMAND)" -shared -fpic $(OPTIONS) -L"$(LINKPATH)" -R"$(RPATH)" -o "$(<)" "$(>)" "$(LIBRARIES)" -Bdynamic -l$(FINDLIBS-SA) -Bstatic -l$(FINDLIBS-ST) -B$(LINK-RUNTIME)
+ "$(CONFIG_COMMAND)" $(OPTIONS) -shared -L"$(LINKPATH)" -R"$(RPATH)" -o "$(<)" -Wl,-h -Wl,$(<[1]:D=) "$(LIBRARIES)" -Bdynamic -l$(FINDLIBS-SA) -Bstatic -l$(FINDLIBS-ST) -B$(LINK-RUNTIME)
 }
 
 actions updated together piecemeal pgi.archive


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