summaryrefslogtreecommitdiffstats
path: root/Tests/CMakeTests
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2011-01-24 16:18:18 (GMT)
committerBrad King <brad.king@kitware.com>2011-05-20 12:57:51 (GMT)
commitd7b376b3a734c2356a1e5138cf0ae52112612e0c (patch)
treea08fdcb430533b4263e1474dae937e447e3ee529 /Tests/CMakeTests
parentac5b999fffc88a1db3d4558e2dd6fd104cf2258a (diff)
downloadCMake-d7b376b3a734c2356a1e5138cf0ae52112612e0c.zip
CMake-d7b376b3a734c2356a1e5138cf0ae52112612e0c.tar.gz
CMake-d7b376b3a734c2356a1e5138cf0ae52112612e0c.tar.bz2
Absoft: Detect implicit link libraries on Linux and Mac
Use the "-X -v" flag to the Absoft front-end to pass "-v" to the gcc it invokes under the hood. Teach CMakeParseImplicitLinkInfo to exclude linker version lines from consideration as link lines. Fix parsing of Sun's linker search path option "-Y..." to avoid conflict with the Mac linker option "-Y<num>".
Diffstat (limited to 'Tests/CMakeTests')
-rw-r--r--Tests/CMakeTests/ImplicitLinkInfoTest.cmake.in15
1 files changed, 15 insertions, 0 deletions
diff --git a/Tests/CMakeTests/ImplicitLinkInfoTest.cmake.in b/Tests/CMakeTests/ImplicitLinkInfoTest.cmake.in
index 3fb4652..dbe9500 100644
--- a/Tests/CMakeTests/ImplicitLinkInfoTest.cmake.in
+++ b/Tests/CMakeTests/ImplicitLinkInfoTest.cmake.in
@@ -84,6 +84,13 @@ set(linux64_nagfor_dirs "/usr/lib/gcc/x86_64-redhat-linux/4.4.5;/usr/lib64;/lib6
set(linux64_nagfor_obj_regex "^/usr/local/NAG/lib")
list(APPEND platforms linux64_nagfor)
+# absoft dummy.f -X -v
+set(linux64_absoft_text "collect2 version 4.4.5 (x86-64 Linux/ELF)
+/usr/bin/ld --build-id --eh-frame-hdr -m elf_x86_64 --hash-style=both -dynamic-linker /lib64/ld-linux-x86-64.so.2 /usr/lib/gcc/x86_64-linux-gnu/4.4.5/../../../../lib/crt1.o /usr/lib/gcc/x86_64-linux-gnu/4.4.5/../../../../lib/crti.o /usr/lib/gcc/x86_64-linux-gnu/4.4.5/crtbegin.o -L/opt/absoft11.1/lib64 -L/usr/lib/gcc/x86_64-linux-gnu/4.4.5 -L/usr/lib/gcc/x86_64-linux-gnu/4.4.5 -L/usr/lib/gcc/x86_64-linux-gnu/4.4.5/../../../../lib -L/lib/../lib -L/usr/lib/../lib -L/usr/lib/gcc/x86_64-linux-gnu/4.4.5/../../.. /tmp/E3Bii1/dummy.o -v -laf90math -lafio -lamisc -labsoftmain -laf77math -lm -lmv -lpthread -lgcc --as-needed -lgcc_s --no-as-needed -lc -lgcc --as-needed -lgcc_s --no-as-needed /usr/lib/gcc/x86_64-linux-gnu/4.4.5/crtend.o /usr/lib/gcc/x86_64-linux-gnu/4.4.5/../../../../lib/crtn.o")
+set(linux64_absoft_libs "af90math;afio;amisc;absoftmain;af77math;m;mv;pthread;c")
+set(linux64_absoft_dirs "/opt/absoft11.1/lib64;/usr/lib/gcc/x86_64-linux-gnu/4.4.5;/usr/lib;/lib")
+list(APPEND platforms linux64_absoft)
+
# gcc dummy.c -v # in strange path
set(linux64_test1_text "
/this/might/match/as/a/linker/ld/but/it/is/not because the ld is not the last path component
@@ -125,6 +132,14 @@ set(mac_ppc_g++_libs "stdc++")
set(mac_ppc_g++_dirs "/usr/lib/powerpc-apple-darwin10/4.2.1;/usr/lib/gcc/powerpc-apple-darwin10/4.2.1;/usr/lib")
list(APPEND platforms mac_ppc_g++)
+# absoft dummy.f -X -v
+set(mac_absoft_text "collect2 version 4.2.1 (Apple Inc. build 5664) (i686 Darwin)
+/usr/libexec/gcc/i686-apple-darwin10/4.2.1/ld -dynamic -arch i386 -macosx_version_min 10.6.6 -weak_reference_mismatches non-weak -o a.out -lcrt1.10.6.o -L/Applications/Absoft11.1/lib -L/usr/lib/i686-apple-darwin10/4.2.1 -L/usr/lib/gcc/i686-apple-darwin10/4.2.1 -L/usr/lib/gcc/i686-apple-darwin10/4.2.1 -L/usr/lib/gcc/i686-apple-darwin10/4.2.1/../../../i686-apple-darwin10/4.2.1 -L/usr/lib/gcc/i686-apple-darwin10/4.2.1/../../.. /var/folders/04/04+Djjm8GZWBmuEdp2Gsw++++TM/-Tmp-//bTAoJc/dummy.o -v -Y 10 -laf90math -lafio -lamisc -labsoftmain -laf77math -lm -lmv -lSystem -lgcc -lSystem
+")
+set(mac_absoft_libs "af90math;afio;amisc;absoftmain;af77math;m;mv")
+set(mac_absoft_dirs "/Applications/Absoft11.1/lib;/usr/lib/i686-apple-darwin10/4.2.1;/usr/lib/gcc/i686-apple-darwin10/4.2.1;/usr/lib")
+list(APPEND platforms mac_absoft)
+
#-----------------------------------------------------------------------------
# Sun