aboutsummaryrefslogtreecommitdiff
path: root/gdbstub.ld.in
diff options
context:
space:
mode:
authorMatt Borgerson <mborgerson@gmail.com>2016-04-20 01:08:26 -0700
committerMatt Borgerson <mborgerson@gmail.com>2016-04-20 01:30:35 -0700
commitbceb2a5ae67e661b7ef00c07b14db425ca14453d (patch)
tree6f79ff4903ec0213e676e4c2f7b97ce24d667d91 /gdbstub.ld.in
parente677c14dc715da62ad5749a4ab740803e58b0a7f (diff)
downloadgdbstub-bceb2a5ae67e661b7ef00c07b14db425ca14453d.tar.gz
Add GDB stub code
Diffstat (limited to 'gdbstub.ld.in')
-rw-r--r--gdbstub.ld.in48
1 files changed, 48 insertions, 0 deletions
diff --git a/gdbstub.ld.in b/gdbstub.ld.in
new file mode 100644
index 0000000..4c15643
--- /dev/null
+++ b/gdbstub.ld.in
@@ -0,0 +1,48 @@
+/*
+ * Copyright (C) 2016 Matt Borgerson
+ *
+ * This program 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.
+ */
+
+ENTRY(dbg_start)
+
+MEMORY
+{
+ RAM (WX) : ORIGIN = $BASE_ADDRESS, LENGTH = 0x10000
+}
+
+SECTIONS
+{
+ .text : {
+ *(.text.dbg_start)
+ *(.text)
+ *(.rodata)
+ } > RAM
+
+ .data : {
+ *(.data)
+ *(.bss)
+ } > RAM
+
+ /DISCARD/ : {
+ *(.comment)
+ *(.note.GNU-stack)
+ *(.eh_frame)
+ *(.rela.eh_frame)
+ *(.shstrtab)
+ *(.symtab)
+ *(.strtab)
+ }
+} \ No newline at end of file