[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
FYI: Patches for Portland Group (aka "pgi") compiler support
From: |
Ralf Wildenhues |
Subject: |
FYI: Patches for Portland Group (aka "pgi") compiler support |
Date: |
Wed, 24 Nov 2004 18:22:28 +0100 |
User-agent: |
Mutt/1.4.1i |
* Jeff Squyres wrote on Wed, Nov 24, 2004 at 02:31:26PM CET:
> (I figured I'd start this in a different thread so that it would be
> easy to find when searching; the patches are identical to what I
> submitted before, but in the interest of tying this all up in one
> thread...)
Good idea.
> I've attached 2 patches to libtool.m4 -- one for branch-1-5 and one for
> branch-2-0 -- that add support for the Portland Group pgcc, pgCC, and
> pgf77 compilers to Libtool. Both pass their respective test suites.
> The 2-0 patch ended its test suite with:
>
> ====================
> All 115 tests passed
> ====================
Thank you very much for testing.
I've checked in the following, slightly different patch (the C++ and F77
drivers don't name-collide with `pentium gcc', those were named pg++ and
pg77 respectively), adding ChangeLog, THANKS and NEWS entries.
The patch below is against branch-2-0, the ones against HEAD and
branch-1-5 are analogously derived from Jeff's patches.
Cheers,
Ralf
2004-11-24 Jeff Squyres <address@hidden>
* m4/libtool.m4 [linux] (_LT_COMPILER_PIC, _LT_LINKER_SHLIBS,
_LT_LANG_CXX_CONFIG), NEWS, THANKS: Support for Portland Group
(aka "pgi") compilers.
Index: NEWS
===================================================================
RCS file: /cvsroot/libtool/libtool/NEWS,v
retrieving revision 1.168.2.9
diff -u -r1.168.2.9 NEWS
--- NEWS 22 Nov 2004 21:22:12 -0000 1.168.2.9
+++ NEWS 24 Nov 2004 14:43:35 -0000
@@ -1,6 +1,7 @@
NEWS - list of user-visible changes between releases of GNU Libtool
New in 1.9h: 2004-??-??; CVS version 1.9g, Libtool team:
+* Support for Portland Group compiler on Linux.
New in 1.9f: 2004-10-23; CVS version 1.9e, Libtool team:
* Calculate dllsearchpath correctly for wrapper scripts on cygwin.
Index: THANKS
===================================================================
RCS file: /cvsroot/libtool/libtool/THANKS,v
retrieving revision 1.36.2.1
diff -u -r1.36.2.1 THANKS
--- THANKS 22 Oct 2004 07:15:30 -0000 1.36.2.1
+++ THANKS 24 Nov 2004 14:43:35 -0000
@@ -75,6 +75,7 @@
Frank Ch. Eigler address@hidden
H.J. Lu address@hidden
Ian Lance Taylor address@hidden
+ Jeff Squyres address@hidden
Joel N. Weber II address@hidden
Joseph Beckenbach III address@hidden
Kenneth Albanowski address@hidden
Index: m4/libtool.m4
===================================================================
RCS file: /cvsroot/libtool/libtool/m4/libtool.m4,v
retrieving revision 1.125.2.13
diff -u -r1.125.2.13 libtool.m4
--- m4/libtool.m4 22 Nov 2004 15:53:04 -0000 1.125.2.13
+++ m4/libtool.m4 24 Nov 2004 14:43:35 -0000
@@ -3082,6 +3082,12 @@
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
;;
+ pgCC)
+ # Portland Group C++ compiler
+ _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
+ _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
+ _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
+ ;;
cxx)
# Compaq C++
# Make sure the PIC flag is empty. It appears that all Alpha
@@ -3329,6 +3335,13 @@
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
;;
+ pgcc | pgf77 | pgf90)
+ # Portland Group compilers (*not* the Pentium gcc compiler,
+ # which looks to be a dead project)
+ _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
+ _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
+ _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
+ ;;
ccc*)
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
# All Alpha code is PIC.
@@ -3599,7 +3612,12 @@
linux*|tpf*)
if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null;
then
- _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs
$compiler_flags ${wl}-soname $wl$soname -o $lib'
+ tmp_archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags
${wl}-soname $wl$soname -o $lib'
+ # Portland Group f77 and f90 compilers require an additonal -fpic
+ if test "$CC" = "pgf77" -o "$CC" = "pgf90"; then
+ tmp_archive_cmds="$tmp_archive_cmds -fpic"
+ fi
+ _LT_TAGVAR(archive_cmds, $1)="$tmp_archive_cmds"
case `$LD -v 2>&1` in
*\ [01].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
*\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
@@ -5100,6 +5118,14 @@
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
_LT_TAGVAR(whole_archive_flag_spec,
$1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
;;
+ pgCC)
+ # Portland Group C++ compiler
+ _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs
$deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
+ _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects
$libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname
${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
+
+ _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath
${wl}$libdir'
+ _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
+ ;;
cxx)
# Compaq C++
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs
$deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'