summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMark Hatle <mark.hatle@windriver.com>2011-06-20 13:08:18 -0500
committerRichard Purdie <richard.purdie@linuxfoundation.org>2011-06-23 12:07:31 +0100
commit745fffc5c2e79729bc2a574b7011ea712ed23033 (patch)
treefbf1d0e2c870e899889e76d6f937d3d75535311d
parenta82642faaa30303635854bdab3acb4a86a3ac92f (diff)
downloadpoky-745fffc5c2e79729bc2a574b7011ea712ed23033.tar.gz
tinylogin: Avoid stripped binaries
(From OE-Core rev: 6a4e0a4e1f84d124e01a81b5a8563df080c7c999) Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/recipes-core/tinylogin/tinylogin-1.4/avoid_static.patch33
-rw-r--r--meta/recipes-core/tinylogin/tinylogin_1.4.bb7
2 files changed, 37 insertions, 3 deletions
diff --git a/meta/recipes-core/tinylogin/tinylogin-1.4/avoid_static.patch b/meta/recipes-core/tinylogin/tinylogin-1.4/avoid_static.patch
new file mode 100644
index 0000000000..8a06af0ddf
--- /dev/null
+++ b/meta/recipes-core/tinylogin/tinylogin-1.4/avoid_static.patch
@@ -0,0 +1,33 @@
1tinylogin: Do not link statically when building debug
2
3For some reason if DODEBUG was enabled (to prevent stripping) the binary was
4also statically linked. This patch prevents that behavior.
5
6Upstream-Status: Inappropriate [no upstream]
7
8Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
9
10diff -ur tinylogin-1.4.orig/Makefile tinylogin-1.4/Makefile
11--- tinylogin-1.4.orig/Makefile 2011-06-18 11:00:23.073927349 -0500
12+++ tinylogin-1.4/Makefile 2011-06-18 11:03:26.394849372 -0500
13@@ -123,20 +123,6 @@
14 LDFLAGS += -s -Wl,-warn-common
15 STRIP = $(STRIPTOOL) --remove-section=.note --remove-section=.comment $(PROG)
16 endif
17-ifeq ($(strip $(DODEBUG)),true)
18- LDFLAGS += --static
19- #
20- #use '-ffunction-sections -fdata-sections' and '--gc-sections' (if they
21- # work) to try and strip out any unused junk. Doesn't do much for me,
22- # but you may want to give it a shot...
23- #
24- #ifeq ($(shell $(CC) -ffunction-sections -fdata-sections -S \
25- # -o /dev/null -xc /dev/null 2>/dev/null && $(LD) \
26- # --gc-sections -v >/dev/null && echo 1),1)
27- # CFLAGS += -ffunction-sections -fdata-sections
28- # LDFLAGS += --gc-sections
29- #endif
30-endif
31 ifeq ($(strip $(DOSTATIC)),true)
32 LDFLAGS += --static
33 #
diff --git a/meta/recipes-core/tinylogin/tinylogin_1.4.bb b/meta/recipes-core/tinylogin/tinylogin_1.4.bb
index 0b51b25853..b620d45924 100644
--- a/meta/recipes-core/tinylogin/tinylogin_1.4.bb
+++ b/meta/recipes-core/tinylogin/tinylogin_1.4.bb
@@ -7,7 +7,7 @@ and groups on an embedded system."
7HOMEPAGE = "http://tinylogin.busybox.net/" 7HOMEPAGE = "http://tinylogin.busybox.net/"
8LICENSE = "GPLv2" 8LICENSE = "GPLv2"
9LIC_FILES_CHKSUM="file://LICENSE;md5=f1060fa3a366f098b5b1d8c2077ba269" 9LIC_FILES_CHKSUM="file://LICENSE;md5=f1060fa3a366f098b5b1d8c2077ba269"
10PR = "r6" 10PR = "r7"
11 11
12SRC_URI = "http://tinylogin.busybox.net/downloads/tinylogin-${PV}.tar.bz2 \ 12SRC_URI = "http://tinylogin.busybox.net/downloads/tinylogin-${PV}.tar.bz2 \
13 file://cvs-20040608.patch;patch=1;pnum=1 \ 13 file://cvs-20040608.patch;patch=1;pnum=1 \
@@ -15,7 +15,8 @@ SRC_URI = "http://tinylogin.busybox.net/downloads/tinylogin-${PV}.tar.bz2 \
15 file://adduser-empty_pwd.patch;patch=1 \ 15 file://adduser-empty_pwd.patch;patch=1 \
16 file://remove-index.patch;patch=1 \ 16 file://remove-index.patch;patch=1 \
17 file://use_O2_option.patch \ 17 file://use_O2_option.patch \
18 file://passwd_rotate_check.patch" 18 file://passwd_rotate_check.patch \
19 file://avoid_static.patch"
19 20
20SRC_URI[md5sum] = "44da0ff2b727455669890b24305e351d" 21SRC_URI[md5sum] = "44da0ff2b727455669890b24305e351d"
21SRC_URI[sha256sum] = "5e542e4b7825305a3678bf73136c392feb0d44b8bbf926e8eda5453eea7ddd6b" 22SRC_URI[sha256sum] = "5e542e4b7825305a3678bf73136c392feb0d44b8bbf926e8eda5453eea7ddd6b"
@@ -23,7 +24,7 @@ SRC_URI[sha256sum] = "5e542e4b7825305a3678bf73136c392feb0d44b8bbf926e8eda5453eea
23EXTRA_OEMAKE = "" 24EXTRA_OEMAKE = ""
24 25
25do_compile () { 26do_compile () {
26 oe_runmake 'CC=${CC}' 'CROSS=${HOST_PREFIX}' 27 oe_runmake 'CC=${CC}' 'CROSS=${HOST_PREFIX}' 'DODEBUG=true'
27} 28}
28 29
29do_install () { 30do_install () {