bfd/
[binutils.git] / ld / testsuite / ld-pe / pe.exp
blob2aa4d20f2460ff4b27fc119cca062fb7b3434364
1 # Expect script for export table in executables tests\r
2 #   Copyright 2004, 2006, 2007\r
3 #   Free Software Foundation, Inc.\r
4 #\r
5 # This file is part of the GNU Binutils.\r
6 #\r
7 # This program is free software; you can redistribute it and/or modify\r
8 # it under the terms of the GNU General Public License as published by\r
9 # the Free Software Foundation; either version 3 of the License, or\r
10 # (at your option) any later version.\r
11 #\r
12 # This program is distributed in the hope that it will be useful,\r
13 # but WITHOUT ANY WARRANTY; without even the implied warranty of\r
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\r
15 # GNU General Public License for more details.\r
16 #\r
17 # You should have received a copy of the GNU General Public License\r
18 # along with this program; if not, write to the Free Software\r
19 # Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,\r
20 # MA 02110-1301, USA.\r
21 #\r
22  \r
23 # This test can only be run on PE/COFF platforms that support .secrel32.\r
24 if {    ![istarget i*86-*-cygwin*]\r
25      && ![istarget i*86-*-pe]\r
26      && ![istarget i*86-*-mingw*]\r
27      && ![istarget x86_64-*-mingw*]\r
28      && ![istarget arm-wince-pe] } {\r
29     return\r
30 }\r
32 if {[istarget x86_64-*-mingw*] } {\r
33   set pe_tests {\r
34     {".secrel32" "" "" {secrel1.s secrel2.s}\r
35     {{objdump -s secrel_64.d}} "secrel.x"}\r
36   }\r
37 } elseif {[istarget i*86-*-cygwin*] } {\r
38   set pe_tests {\r
39     {".secrel32" "--disable-auto-import" "" {secrel1.s secrel2.s}\r
40      {{objdump -s secrel.d}} "secrel.x"}\r
41   }\r
42 } else {\r
43   set pe_tests {\r
44     {".secrel32" "" "" {secrel1.s secrel2.s}\r
45      {{objdump -s secrel.d}} "secrel.x"}\r
46   }\r
47 }\r
49 run_ld_link_tests $pe_tests\r
51 run_dump_test "image_size"\r
52 run_dump_test "export_dynamic_warning"\r