summaryrefslogtreecommitdiff
path: root/package/sstrip
diff options
context:
space:
mode:
authorGustavo Zacarias <gustavo@zacarias.com.ar>2010-12-28 16:10:26 -0300
committerPeter Korsgaard <jacmet@sunsite.dk>2010-12-28 20:43:58 +0100
commitf78b344ea82f6f45547788652c4352ba2a623cbb (patch)
tree7edf66d992f2fb5999b20c80f523986a66801faa /package/sstrip
parent6b0e9dd06f27d134340a4aedde6e6e2105820832 (diff)
sstrip: make it a proper package
* Convert sstrip to a proper gentargets package * Use openwrt svn version, it's basically the same one we used * Change the hooks from old toolchain/sstrip to new package/sstrip * Drop the old toolchain/sstrip directory * sstrip for the target is now in Package -> Development Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar> Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
Diffstat (limited to 'package/sstrip')
-rw-r--r--package/sstrip/Config.in7
-rw-r--r--package/sstrip/sstrip.mk45
2 files changed, 52 insertions, 0 deletions
diff --git a/package/sstrip/Config.in b/package/sstrip/Config.in
new file mode 100644
index 000000000..12a5941c5
--- /dev/null
+++ b/package/sstrip/Config.in
@@ -0,0 +1,7 @@
+config BR2_PACKAGE_SSTRIP
+ bool "sstrip"
+ help
+ Small utility that removes a few bytes from an executable that
+ strip leaves behind.
+
+ http://www.muppetlabs.com/~breadbox/software/elfkickers.html
diff --git a/package/sstrip/sstrip.mk b/package/sstrip/sstrip.mk
new file mode 100644
index 000000000..2dc383d4e
--- /dev/null
+++ b/package/sstrip/sstrip.mk
@@ -0,0 +1,45 @@
+############################################################
+#
+# sstrip
+#
+############################################################
+
+SSTRIP_SITE = svn://dev.openwrt.org/openwrt/trunk/tools/sstrip
+SSTRIP_VERSION = 20154
+HOST_SSTRIP_BINARY = $(REAL_GNU_TARGET_NAME)-sstrip
+
+# This is a kludge to get host-ccache built before us or it fails
+ifeq ($(BR2_CCACHE),y)
+HOST_SSTRIP_DEPENDENCIES = host-ccache
+endif
+
+define SSTRIP_BUILD_CMDS
+ cd $(@D) ; \
+ $(TARGET_CC) $(TARGET_CFLAGS) -include endian.h -include byteswap.h \
+ -o sstrip src/sstrip.c
+endef
+
+define SSTRIP_INSTALL_TARGET_CMDS
+ $(INSTALL) -D $(@D)/sstrip $(TARGET_DIR)/usr/bin/sstrip
+endef
+
+define SSTRIP_UNINSTALL_TARGET_CMDS
+ rm -f $(TARGET_DIR)/usr/bin/sstrip
+endef
+
+define HOST_SSTRIP_BUILD_CMDS
+ cd $(@D) ; \
+ $(HOSTCC) $(HOST_CFLAGS) -include endian.h -include byteswap.h \
+ -o sstrip src/sstrip.c
+endef
+
+define HOST_SSTRIP_INSTALL_CMDS
+ $(INSTALL) -D $(@D)/sstrip $(HOST_DIR)/usr/bin/$(HOST_SSTRIP_BINARY)
+endef
+
+define HOST_SSTRIP_UNINSTALL_CMDS
+ rm -f $(HOST_DIR)/usr/bin/$(HOST_SSTRIP_BINARY)
+endef
+
+$(eval $(call GENTARGETS,package,sstrip))
+$(eval $(call GENTARGETS,package,sstrip,host))