aboutsummaryrefslogtreecommitdiffstats
path: root/include/package-debug.mk
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2009-01-13 03:21:25 +0000
committerFelix Fietkau <nbd@openwrt.org>2009-01-13 03:21:25 +0000
commiteb1c4db03967f28efd280ecb869009e9fe9c9dab (patch)
treed622c36d667a9dba9c1dfac56b6adde613fc5814 /include/package-debug.mk
parentef6e3e880fd696d029f69168581893883ec69f58 (diff)
downloadupstream-eb1c4db03967f28efd280ecb869009e9fe9c9dab.tar.gz
upstream-eb1c4db03967f28efd280ecb869009e9fe9c9dab.tar.bz2
upstream-eb1c4db03967f28efd280ecb869009e9fe9c9dab.zip
add support for an optional staging directory for debug binaries
SVN-Revision: 14018
Diffstat (limited to 'include/package-debug.mk')
-rw-r--r--include/package-debug.mk26
1 files changed, 26 insertions, 0 deletions
diff --git a/include/package-debug.mk b/include/package-debug.mk
new file mode 100644
index 0000000000..2a85bfebb8
--- /dev/null
+++ b/include/package-debug.mk
@@ -0,0 +1,26 @@
+#
+# Copyright (C) 2006,2007 OpenWrt.org
+#
+# This is free software, licensed under the GNU General Public License v2.
+# See /LICENSE for more information.
+#
+
+ifeq ($(DUMP),)
+ define BuildTarget/debug
+
+ DEBUG_STAMP_$(1) := $(DEBUG_DIR)/stamp/$(1)
+
+ ifdef Package/$(1)/install
+ ifneq ($(CONFIG_PACKAGE_$(1))$(SDK)$(DEVELOPER),)
+ compile: $$(DEBUG_STAMP_$(1))
+ endif
+ endif
+
+ $$(DEBUG_STAMP_$(1)): $(PKG_BUILD_DIR)/.built
+ mkdir -p $(DEBUG_DIR)/stamp
+ $(call Package/$(1)/install,$(DEBUG_DIR))
+ touch $$(DEBUG_STAMP_$(1))
+
+
+ endef
+endif