aboutsummaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorTravis Geiselbrecht <geist@foobox.com>2015-10-26 16:33:39 -0700
committerTravis Geiselbrecht <geist@foobox.com>2015-10-26 16:47:18 -0700
commit0e1ce411bad4875347befe5184bc2efbd686cdc4 (patch)
treea55f8aff9963d1819ae42e870c8559f312b32024 /app
parentf60375667166d2da1ccb708abf68c736cac60fd6 (diff)
downloadcommon-0e1ce411bad4875347befe5184bc2efbd686cdc4.tar.gz
[make] add ability to set EXTRA_LINKER_SCRIPTS in modules
This allows for individual modules to extend the main linker script, primarily to add their own sections to interate over. Remove the main shared_* linker scripts.
Diffstat (limited to 'app')
-rw-r--r--app/app.ld8
-rw-r--r--app/rules.mk2
2 files changed, 10 insertions, 0 deletions
diff --git a/app/app.ld b/app/app.ld
new file mode 100644
index 00000000..1e50ca92
--- /dev/null
+++ b/app/app.ld
@@ -0,0 +1,8 @@
+SECTIONS {
+ .apps ALIGN(8) : {
+ __apps_start = .;
+ KEEP (*(.apps))
+ __apps_end = .;
+ }
+}
+INSERT AFTER .data;
diff --git a/app/rules.mk b/app/rules.mk
index 7de33dd5..8e24edfd 100644
--- a/app/rules.mk
+++ b/app/rules.mk
@@ -5,4 +5,6 @@ MODULE := $(LOCAL_DIR)
MODULE_SRCS += \
$(LOCAL_DIR)/app.c
+EXTRA_LINKER_SCRIPTS += $(LOCAL_DIR)/app.ld
+
include make/module.mk