aboutsummaryrefslogtreecommitdiffstats
path: root/tools/sparse
diff options
context:
space:
mode:
authorJohn Crispin <blogic@openwrt.org>2014-04-12 21:21:49 +0000
committerJohn Crispin <blogic@openwrt.org>2014-04-12 21:21:49 +0000
commit12bb716ac3dacb9fe835f2adcb23c4234d74003c (patch)
tree6b15651ee1a9e41fc8e642baaf49116acad14ac3 /tools/sparse
parent9f3447fc0e3c5933c2b215bb6298b525404f0283 (diff)
downloadmaster-187ad058-12bb716ac3dacb9fe835f2adcb23c4234d74003c.tar.gz
master-187ad058-12bb716ac3dacb9fe835f2adcb23c4234d74003c.tar.bz2
master-187ad058-12bb716ac3dacb9fe835f2adcb23c4234d74003c.zip
sparse: add as a new package selectable from the config
This change does multiple things, all related to enable sparse usage as a static analysis tool selectable from the OpenWrt configuration: *add a KERNEL_SPARSE option in the config to add sparse to the kernel build (through the C=1 option usage) *add sparse as a new host tools. It will get selected automatically when the above option will be enabled Signed-off-by: Mathieu Olivari <mathieu@qca.qualcomm.com> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@40490 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'tools/sparse')
-rw-r--r--tools/sparse/Makefile22
1 files changed, 22 insertions, 0 deletions
diff --git a/tools/sparse/Makefile b/tools/sparse/Makefile
new file mode 100644
index 0000000000..6cdeed5cca
--- /dev/null
+++ b/tools/sparse/Makefile
@@ -0,0 +1,22 @@
+#
+# Copyright (C) 2014 Qualcomm-Atheros Inc.
+#
+
+include $(TOPDIR)/rules.mk
+
+PKG_NAME:=sparse
+PKG_VERSION:=0.5.0
+
+PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
+PKG_SOURCE_URL:=@KERNEL/software/devel/sparse/dist/
+PKG_MD5SUM:=68bc834c57836251fbee55a7707bab39
+
+PKG_BUILD_PARALLEL:=1
+
+include $(INCLUDE_DIR)/host-build.mk
+
+define Host/Install
+ $(INSTALL_BIN) $(HOST_BUILD_DIR)/sparse $(STAGING_DIR_HOST)/bin
+endef
+
+$(eval $(call HostBuild))