diff options
author | Nathan Sidwell <nathan@codesourcery.com> | 2007-01-06 22:03:46 +0000 |
---|---|---|
committer | Nathan Sidwell <nathan@codesourcery.com> | 2007-01-06 22:03:46 +0000 |
commit | cc3e2771c5def765623e1fb173f8211ddbe5ccb6 (patch) | |
tree | 58c3ada104bb4380a55083caa365178481eee8f5 /ld/testsuite/ld-scripts | |
parent | 2e4dc0578090605ab0c5e5a097bbdf000a4cfc51 (diff) | |
download | gdb-cc3e2771c5def765623e1fb173f8211ddbe5ccb6.zip gdb-cc3e2771c5def765623e1fb173f8211ddbe5ccb6.tar.gz gdb-cc3e2771c5def765623e1fb173f8211ddbe5ccb6.tar.bz2 |
ld/
* ldexp.c (fold_name): Issue error on undefined sections.
ld/testsuite/
* ld-scripts/expr.exp: New.
* ld-scripts/expr1.s: New.
* ld-scripts/expr1.d: New.
* ld-scripts/expr1.t: New.
Diffstat (limited to 'ld/testsuite/ld-scripts')
-rw-r--r-- | ld/testsuite/ld-scripts/expr.exp | 20 | ||||
-rw-r--r-- | ld/testsuite/ld-scripts/expr1.d | 2 | ||||
-rw-r--r-- | ld/testsuite/ld-scripts/expr1.s | 2 | ||||
-rw-r--r-- | ld/testsuite/ld-scripts/expr1.t | 12 |
4 files changed, 36 insertions, 0 deletions
diff --git a/ld/testsuite/ld-scripts/expr.exp b/ld/testsuite/ld-scripts/expr.exp new file mode 100644 index 0000000..43ca1c6 --- /dev/null +++ b/ld/testsuite/ld-scripts/expr.exp @@ -0,0 +1,20 @@ +# Test ALIGN in a linker script. +# By Nathan Sidwell, CodeSourcery LLC +# Copyright 2006 +# Free Software Foundation, Inc. +# +# This file is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA. + +run_dump_test expr1 diff --git a/ld/testsuite/ld-scripts/expr1.d b/ld/testsuite/ld-scripts/expr1.d new file mode 100644 index 0000000..d96dfc1 --- /dev/null +++ b/ld/testsuite/ld-scripts/expr1.d @@ -0,0 +1,2 @@ +# ld: -T expr1.t +# error: undefined section .* in expression diff --git a/ld/testsuite/ld-scripts/expr1.s b/ld/testsuite/ld-scripts/expr1.s new file mode 100644 index 0000000..ec0ce90 --- /dev/null +++ b/ld/testsuite/ld-scripts/expr1.s @@ -0,0 +1,2 @@ + .word 0 + diff --git a/ld/testsuite/ld-scripts/expr1.t b/ld/testsuite/ld-scripts/expr1.t new file mode 100644 index 0000000..e0810ba --- /dev/null +++ b/ld/testsuite/ld-scripts/expr1.t @@ -0,0 +1,12 @@ +ENTRY(RAM) + +MEMORY +{ + ram (rwx) : ORIGIN = 0, LENGTH = 0x1000000 +} + +SECTIONS +{ +.text : { } >ram +} +RAM = ADDR(ram); |