summaryrefslogtreecommitdiff
path: root/flx
diff options
context:
space:
mode:
Diffstat (limited to 'flx')
-rw-r--r--flx/init/Manifest16
-rw-r--r--flx/init/files/0.1.34-error-struct-stat.diff12
-rw-r--r--flx/init/files/0.1.34-no-no-omit-leaf-frame-pointer.diff9
-rw-r--r--flx/init/files/0.1.34-remove-strip-diet.diff36
-rw-r--r--flx/init/files/0.1.34-respect-CFLAGS-LDFLAGS.diff15
-rw-r--r--flx/init/files/0.1.35-MEDIUM-Remove-strip-and-uclibc.patch149
-rw-r--r--flx/init/files/0.1.35-MEDIUM-Respect-CFLAGS-and-LDFLAGS.patch56
-rw-r--r--flx/init/files/0.1.35-init-fix-a-major-bug-in-interactive-mode.patch29
-rw-r--r--flx/init/files/9999-MEDIUM-Remove-strip-and-uclibc.patch149
-rw-r--r--flx/init/files/9999-MEDIUM-Respect-CFLAGS-and-LDFLAGS.patch56
-rw-r--r--flx/init/files/9999-error-struct-stat.diff12
-rw-r--r--flx/init/files/9999-remove-strip-diet.diff45
-rw-r--r--flx/init/files/9999-respect-CFLAGS-LDFLAGS.diff24
-rw-r--r--flx/init/init-0.1.35.ebuild (renamed from flx/init/init-0.1.34.ebuild)6
-rw-r--r--flx/init/init-9999.ebuild4
15 files changed, 451 insertions, 167 deletions
diff --git a/flx/init/Manifest b/flx/init/Manifest
index a080ce2f..91af712e 100644
--- a/flx/init/Manifest
+++ b/flx/init/Manifest
@@ -1,10 +1,8 @@
-AUX 0.1.34-error-struct-stat.diff 240 SHA256 4555439fdbd221a30314a368e16ad53d6bf9cf723b84ddec766eafbd125f023a WHIRLPOOL f9471e4aca1106d2bc4fe184bbdc147efefdc41e96617901f4e328479995ebc270aec055e8d353d7154f0d3c94194e241520883581d0b216b9fc7fc6b0c3e21f
-AUX 0.1.34-no-no-omit-leaf-frame-pointer.diff 302 SHA256 28d16f01d4f5523da10db9472b4476f083d73a1dbf10c7e4dcae635beae9e6f3 WHIRLPOOL a7b7956c126d9bbd5666e535552cbab731365f944a10002851a972c276238b24c1bb948f328b89664534db6b24bf3c66aaaa2bc87a9d032b133717cf28a5dd83
-AUX 0.1.34-remove-strip-diet.diff 1165 SHA256 7e3a01385ab120ec2f0630d081aa2ce7cc324e5e9f3b9687dab62e09e5bc2fea WHIRLPOOL d507478c38bab5ceffe9afded94f08134ddfcf41355786dfbee4c105d9cac5689682e6cd3bd37c39ed25d02ef6a7325509fa6f9638563875efc1b101789c71cc
-AUX 0.1.34-respect-CFLAGS-LDFLAGS.diff 475 SHA256 920e0fc923f915a3bb0a59ae401cd4f6f4c7b2aca57786c821e61cec4248873e WHIRLPOOL 90715a0de2e926f729a630178cffcaf1d24f4dd1483d54d8297e14b980203d927a3364f6357048ef8b9b3032af023c219f7371679895c1c218c78b7ead2e88c2
-AUX 9999-error-struct-stat.diff 240 SHA256 4555439fdbd221a30314a368e16ad53d6bf9cf723b84ddec766eafbd125f023a WHIRLPOOL f9471e4aca1106d2bc4fe184bbdc147efefdc41e96617901f4e328479995ebc270aec055e8d353d7154f0d3c94194e241520883581d0b216b9fc7fc6b0c3e21f
-AUX 9999-remove-strip-diet.diff 1475 SHA256 90dfb592c73c7f1b0e8608418af5bcd829577c7b50cf676c4816990d77ef26c5 WHIRLPOOL 26b41d73386121f0c6273bd5d05da73814a0678e899137126f4c696dd0faf319fed81b7e50acd30ea2a0d4d90028482fa61ac2b4225282d9650693113286406a
-AUX 9999-respect-CFLAGS-LDFLAGS.diff 768 SHA256 0ae2ca40da7bedf0d2d64e05ae7d5ad0aa2e970a3334d842e8ff9fe4d172fd2a WHIRLPOOL 1c0e3236aee5ce3eb92b0f4c389ec97c167c73aeab4fe3c3b853a0009ce376fa58aedb372224054f41af04b33748f15f00e11da70f5a08e6ba5d5523ae318064
-EBUILD init-0.1.34.ebuild 1033 SHA256 7a8d43c898ef83ec47d515f9bd9d089c805f946ffd6bb83263a0dcb0fc2c78b4 WHIRLPOOL 5ecbfa0bb20bae494c682f6136a9c99b3fa54af22d50b5d9bc7d1287a59f6897af58b023499327a73d565463fbf3ec7b364fe66c882de7ff0c8fa587a06a1301
-EBUILD init-9999.ebuild 935 SHA256 77d8a066e3d9d9a93cad8d69fa3c189d5d15e258f65135ab49ec0dadb70851b1 WHIRLPOOL a961aaca907a84df334889303f88940e722416cf67c1eb011510ff14ca033a8e2207c5266ce74337d79b2c4fa99bd6c6b159891bd8ec4e167f84b3881696f589
+AUX 0.1.35-MEDIUM-Remove-strip-and-uclibc.patch 4720 SHA256 c605c0e1d38dd051736f074e6c02646c29f95e6138e2532a8efe82ec0bce1fa9 WHIRLPOOL 8db8edda4e9f55f3add670a2c77d9e6e431d64e8459c743f0829a86e5d50bd47854a968d27677aeb6c6c7c18fc33184e28844893a2db5454a69fdcf23e1b52f7
+AUX 0.1.35-MEDIUM-Respect-CFLAGS-and-LDFLAGS.patch 1772 SHA256 5be60935a419d85831b1be2e6562128bb982b7e4a161550dad9110e77c0e84e6 WHIRLPOOL 628578cad6730c4e26d80e24e3b1fa4d5127b20a090c4219c1516c73d75eb1f034c458f6f71f8944fab0e6fe11f103c2ad3e0abb39dd918f3fa58505494afb25
+AUX 0.1.35-init-fix-a-major-bug-in-interactive-mode.patch 1153 SHA256 dfcfb6e531e5f64d6212cb4b9ec5f538263f045a5b81c15294b554a8c8a4ebba WHIRLPOOL 8ed157458a8dbe419818d2f422312a507b2c530f509b7d063c27ec44429cba5a960ddcb5369c8adbaf3fdbcdf6cea9c6179412c13776fe1a9289b027a89aebca
+AUX 9999-MEDIUM-Remove-strip-and-uclibc.patch 4720 SHA256 c605c0e1d38dd051736f074e6c02646c29f95e6138e2532a8efe82ec0bce1fa9 WHIRLPOOL 8db8edda4e9f55f3add670a2c77d9e6e431d64e8459c743f0829a86e5d50bd47854a968d27677aeb6c6c7c18fc33184e28844893a2db5454a69fdcf23e1b52f7
+AUX 9999-MEDIUM-Respect-CFLAGS-and-LDFLAGS.patch 1772 SHA256 5be60935a419d85831b1be2e6562128bb982b7e4a161550dad9110e77c0e84e6 WHIRLPOOL 628578cad6730c4e26d80e24e3b1fa4d5127b20a090c4219c1516c73d75eb1f034c458f6f71f8944fab0e6fe11f103c2ad3e0abb39dd918f3fa58505494afb25
+EBUILD init-0.1.35.ebuild 1071 SHA256 a7dbad4052535804c3c5a68de13e1273704b22f3f37059bb5a8ceb91b16e0fc2 WHIRLPOOL b6e87d8ca8c027af5950900ae619be8ad59a271bfaf969b1ff3747de0e949184437bddfa833ec4edc5ce0b391a0ac6fdf9829b296dc108f4b062a56d998e0d93
+EBUILD init-9999.ebuild 961 SHA256 61bdbb4217e7b5566a1c7ae754e53d9ded99b23ddd7018b72b8e41f45916910e WHIRLPOOL bc75190a736083f0a034aff210bec022bc9c2b0f2edc9b2eaf01f4400d4e1e856c982fccc5ba0a59355b82d26b13c86fcf39776a7d9155a88d12f67404d99210
MISC metadata.xml 256 SHA256 6ca43960767ca28661abf97c85263db77fe7643902be2ce777c61aa688d8ea2d WHIRLPOOL cef8582829111be09e651eb819e6d1ea59c9c4386b842169ccd46a14c8e3ccb090486fecd61c5fd4aa47998cacc69cdc1fb5ca6bb6325a4da1ebfd0b6eebda7b
diff --git a/flx/init/files/0.1.34-error-struct-stat.diff b/flx/init/files/0.1.34-error-struct-stat.diff
deleted file mode 100644
index 9d21b1ae..00000000
--- a/flx/init/files/0.1.34-error-struct-stat.diff
+++ /dev/null
@@ -1,12 +0,0 @@
-diff --git a/init/mkdev.c b/init/mkdev.c
-index 47e4aa0..78a8c8d 100644
---- a/init/mkdev.c
-+++ b/init/mkdev.c
-@@ -49,6 +49,7 @@
- #include <stdlib.h>
- #include <sys/ioctl.h>
- #include <linux/loop.h>
-+#include <sys/stat.h>
-
-
- //#ifdef DEBUG
diff --git a/flx/init/files/0.1.34-no-no-omit-leaf-frame-pointer.diff b/flx/init/files/0.1.34-no-no-omit-leaf-frame-pointer.diff
deleted file mode 100644
index e7706737..00000000
--- a/flx/init/files/0.1.34-no-no-omit-leaf-frame-pointer.diff
+++ /dev/null
@@ -1,9 +0,0 @@
-diff --git a/init/Makefile b/init/Makefile
-index 9bcbcde..8b95b06 100644
---- a/init/Makefile
-+++ b/init/Makefile
-@@ -1,3 +1,3 @@
- OBJS=init mkdev
- include ../include/rules.make
--CFLAGS+=-fomit-frame-pointer -mno-omit-leaf-frame-pointer -Wl,--gc-sections
-+CFLAGS+=-fomit-frame-pointer -Wl,--gc-sections
diff --git a/flx/init/files/0.1.34-remove-strip-diet.diff b/flx/init/files/0.1.34-remove-strip-diet.diff
deleted file mode 100644
index d377de8a..00000000
--- a/flx/init/files/0.1.34-remove-strip-diet.diff
+++ /dev/null
@@ -1,36 +0,0 @@
-diff --git a/include/rules.make b/include/rules.make
-index 99bff82..f373aad 100644
---- a/include/rules.make
-+++ b/include/rules.make
-@@ -1,30 +1,16 @@
- CC ?= gcc
--STRIP ?= strip
--OBJDUMP ?= objdump
--SSTRIP ?= sstrip
--DIET ?= diet
--
--CC_ORIG := $(CC)
--override CC := $(DIET) $(CC)
-
- CFLAGS=$(GCC_ARCH_SMALL) $(GCC_CPU_SMALL) $(GCC_OPT_SMALL)
- #-mpreferred-stack-boundary=2 -malign-jumps=0 -malign-loops=0 -malign-functions=0 -Os -march=i386 -mcpu=i386
--LDFLAGS=-s -Wl,--gc-sections
-+LDFLAGS=-Wl,--gc-sections
-
- all: $(OBJS)
-
- %: %.c
- $(CC) $(LDFLAGS) $(CFLAGS) -o $@ $<
-- $(STRIP) -x --strip-unneeded -R .comment -R .note $@
-- $(OBJDUMP) -h $@ | grep -q '\.data[ ]*00000000' && $(STRIP) -R .data $@ || true
-- $(OBJDUMP) -h $@ | grep -q '\.sbss[ ]*00000000' && $(STRIP) -R .sbss $@ || true
-- #-if [ -n "$(SSTRIP)" ]; then $(SSTRIP) $@ ; fi
-
- %-debug: %.c
- $(CC) $(LDFLAGS) $(CFLAGS) -DDEBUG -o $@ $<
-- $(STRIP) -x --strip-unneeded -R .comment -R .note $@
-- $(OBJDUMP) -h $@ | grep -q '\.data[ ]*00000000' && $(STRIP) -R .data $@ || true
-- $(OBJDUMP) -h $@ | grep -q '\.sbss[ ]*00000000' && $(STRIP) -R .sbss $@ || true
-
- clean:
- @rm -f *.[ao] *~ core
diff --git a/flx/init/files/0.1.34-respect-CFLAGS-LDFLAGS.diff b/flx/init/files/0.1.34-respect-CFLAGS-LDFLAGS.diff
deleted file mode 100644
index 8ac81836..00000000
--- a/flx/init/files/0.1.34-respect-CFLAGS-LDFLAGS.diff
+++ /dev/null
@@ -1,15 +0,0 @@
-diff --git a/include/rules.make b/include/rules.make
-index f373aad..1f95cd1 100644
---- a/include/rules.make
-+++ b/include/rules.make
-@@ -1,8 +1,8 @@
- CC ?= gcc
-
--CFLAGS=$(GCC_ARCH_SMALL) $(GCC_CPU_SMALL) $(GCC_OPT_SMALL)
-+CFLAGS += $(GCC_ARCH_SMALL) $(GCC_CPU_SMALL) $(GCC_OPT_SMALL)
- #-mpreferred-stack-boundary=2 -malign-jumps=0 -malign-loops=0 -malign-functions=0 -Os -march=i386 -mcpu=i386
--LDFLAGS=-Wl,--gc-sections
-+LDFLAGS += -Wl,--gc-sections
-
- all: $(OBJS)
-
diff --git a/flx/init/files/0.1.35-MEDIUM-Remove-strip-and-uclibc.patch b/flx/init/files/0.1.35-MEDIUM-Remove-strip-and-uclibc.patch
new file mode 100644
index 00000000..6ffe6b44
--- /dev/null
+++ b/flx/init/files/0.1.35-MEDIUM-Remove-strip-and-uclibc.patch
@@ -0,0 +1,149 @@
+From caa62e8ba16c340aafd45375ec99f48261e62abf Mon Sep 17 00:00:00 2001
+From: Bertrand Jacquin <bertrand@jacquin.bzh>
+Date: Mon, 27 May 2013 22:36:39 +0200
+Subject: [PATCH 1/2] MEDIUM: Remove strip and uclibc
+
+---
+ flx/Makefile | 1 -
+ ifenslave/Makefile | 3 ---
+ include/rules.make | 16 +---------------
+ lcd/Makefile | 3 ---
+ mii/Makefile | 3 ---
+ mktmp/Makefile | 3 ---
+ remount/Makefile | 3 ---
+ signfs/Makefile | 1 -
+ wd/Makefile | 3 ---
+ 9 files changed, 1 insertion(+), 35 deletions(-)
+
+diff --git a/flx/Makefile b/flx/Makefile
+index 68ecb4c..408c9b5 100644
+--- a/flx/Makefile
++++ b/flx/Makefile
+@@ -39,7 +39,6 @@ all: $(NAME)
+
+ $(NAME): $(OBJ)
+ $(CC) -o $(NAME) $(OBJ) $(LDFLAGS)
+-# strip -R .note -R .comment signfs
+
+ clean:
+ @$(RM) -vf $(NAME) $(OBJ) $(LIBTOOLS:.c=.o) *~ core *.bak
+diff --git a/ifenslave/Makefile b/ifenslave/Makefile
+index 7ba3dc7..14fd640 100644
+--- a/ifenslave/Makefile
++++ b/ifenslave/Makefile
+@@ -13,9 +13,6 @@ ifenslave:
+
+ ifenslave%: ifenslave%.o
+ $(CC) $(LDFLAGS) $(CFLAGS) -o $@ $<
+- $(STRIP) -x --strip-unneeded -R .comment -R .note $@
+- $(OBJDUMP) -h $@ | grep -q '\.data[ ]*00000000' && $(STRIP) -R .data $@ || true
+- # sstrip $@
+
+ %.o: %.c
+ $(CC) $(CFLAGS) -c -o $@ $<
+diff --git a/include/rules.make b/include/rules.make
+index 715db29..f373aad 100644
+--- a/include/rules.make
++++ b/include/rules.make
+@@ -1,30 +1,16 @@
+ CC ?= gcc
+-STRIP ?= strip
+-OBJDUMP ?= objdump
+-SSTRIP ?= sstrip
+-UCLIBC ?= uclibc
+-
+-CC_ORIG := $(CC)
+-override CC := $(UCLIBC) $(CC) -Os
+
+ CFLAGS=$(GCC_ARCH_SMALL) $(GCC_CPU_SMALL) $(GCC_OPT_SMALL)
+ #-mpreferred-stack-boundary=2 -malign-jumps=0 -malign-loops=0 -malign-functions=0 -Os -march=i386 -mcpu=i386
+-LDFLAGS=-s -Wl,--gc-sections
++LDFLAGS=-Wl,--gc-sections
+
+ all: $(OBJS)
+
+ %: %.c
+ $(CC) $(LDFLAGS) $(CFLAGS) -o $@ $<
+- $(STRIP) -x --strip-unneeded -R .comment -R .note $@
+- $(OBJDUMP) -h $@ | grep -q '\.data[ ]*00000000' && $(STRIP) -R .data $@ || true
+- $(OBJDUMP) -h $@ | grep -q '\.sbss[ ]*00000000' && $(STRIP) -R .sbss $@ || true
+- #-if [ -n "$(SSTRIP)" ]; then $(SSTRIP) $@ ; fi
+
+ %-debug: %.c
+ $(CC) $(LDFLAGS) $(CFLAGS) -DDEBUG -o $@ $<
+- $(STRIP) -x --strip-unneeded -R .comment -R .note $@
+- $(OBJDUMP) -h $@ | grep -q '\.data[ ]*00000000' && $(STRIP) -R .data $@ || true
+- $(OBJDUMP) -h $@ | grep -q '\.sbss[ ]*00000000' && $(STRIP) -R .sbss $@ || true
+
+ clean:
+ @rm -f *.[ao] *~ core
+diff --git a/lcd/Makefile b/lcd/Makefile
+index 71d861f..4de920f 100644
+--- a/lcd/Makefile
++++ b/lcd/Makefile
+@@ -4,6 +4,3 @@ CFLAGS+=-fomit-frame-pointer
+
+ %: %.c
+ $(CC) $(LDFLAGS) $(CFLAGS) -o $@ $<
+- $(STRIP) -x --strip-unneeded -R .comment -R .note $@
+- $(OBJDUMP) -h $@ | grep -q '\.data[ ]*00000000' && $(STRIP) -R .data $@ || true
+- #$(SSTRIP) $@
+diff --git a/mii/Makefile b/mii/Makefile
+index 791f6b9..21d64d3 100644
+--- a/mii/Makefile
++++ b/mii/Makefile
+@@ -7,9 +7,6 @@ all: $(OBJS)
+
+ %-diag: %-diag.o libmii.o
+ $(CC) $(LDFLAGS) $(CFLAGS) -o $@ $^
+- $(STRIP) -x --strip-unneeded -R .comment -R .note $@
+- $(OBJDUMP) -h $@ | grep -q '\.data[ ]*00000000' && $(STRIP) -R .data $@ || true
+- #$(SSTRIP) $@
+
+ %.o: %.c
+ $(CC) -DLIBMII $(CFLAGS) -c -o $@ $<
+diff --git a/mktmp/Makefile b/mktmp/Makefile
+index 2188b91..ef4b083 100644
+--- a/mktmp/Makefile
++++ b/mktmp/Makefile
+@@ -4,6 +4,3 @@ include ../include/rules.make
+
+ %: %.c
+ $(CC) $(LDFLAGS) $(CFLAGS) -o $@ $<
+- $(STRIP) -x --strip-unneeded -R .comment -R .note $@
+- $(OBJDUMP) -h $@ | grep -q '\.data[ ]*00000000' && $(STRIP) -R .data $@ || true
+- #$(SSTRIP) $@
+diff --git a/remount/Makefile b/remount/Makefile
+index 5aa2491..54a79ad 100644
+--- a/remount/Makefile
++++ b/remount/Makefile
+@@ -7,6 +7,3 @@ remountw : remountr
+
+ %: %.c
+ $(CC) $(LDFLAGS) $(CFLAGS) -o $@ $<
+- $(STRIP) -x --strip-unneeded -R .comment -R .note $@
+- $(OBJDUMP) -h $@ | grep -q '\.data[ ]*00000000' && $(STRIP) -R .data $@ || true
+- -if [ -n "$(SSTRIP)" ]; then $(SSTRIP) $@ ; fi
+diff --git a/signfs/Makefile b/signfs/Makefile
+index f50b301..d4214c6 100644
+--- a/signfs/Makefile
++++ b/signfs/Makefile
+@@ -35,7 +35,6 @@ LIBTOOLS=md5.c libtools.c others.c
+
+ $(NAME): libtools.a $(OBJ)
+ $(CC) -o $(NAME) $(OBJ) $(LDFLAGS)
+- #strip -R .note -R .comment signfs
+
+ libtools.a: $(LIBTOOLS:.c=.o)
+ $(AR) -r libtools.a $(LIBTOOLS:.c=.o)
+diff --git a/wd/Makefile b/wd/Makefile
+index 6f1fa72..eaf857a 100644
+--- a/wd/Makefile
++++ b/wd/Makefile
+@@ -4,6 +4,3 @@ CFLAGS+=-fomit-frame-pointer
+
+ %: %.c
+ $(CC) $(LDFLAGS) $(CFLAGS) -W -Wall -U_FORTIFY_SOURCE -o $@ $<
+- $(STRIP) -x --strip-unneeded -R .comment -R .note $@
+- $(OBJDUMP) -h $@ | grep -q '\.data[ ]*00000000' && $(STRIP) -R .data $@ || true
+- -if [ -n "$(SSTRIP)" ]; then $(SSTRIP) $@ ; fi
diff --git a/flx/init/files/0.1.35-MEDIUM-Respect-CFLAGS-and-LDFLAGS.patch b/flx/init/files/0.1.35-MEDIUM-Respect-CFLAGS-and-LDFLAGS.patch
new file mode 100644
index 00000000..dec2fc8d
--- /dev/null
+++ b/flx/init/files/0.1.35-MEDIUM-Respect-CFLAGS-and-LDFLAGS.patch
@@ -0,0 +1,56 @@
+From 25a9b5d4cd1b57c81e697ff7e54bf9121e8bbfa4 Mon Sep 17 00:00:00 2001
+From: Bertrand Jacquin <bertrand@jacquin.bzh>
+Date: Mon, 27 May 2013 22:36:39 +0200
+Subject: [PATCH 2/2] MEDIUM: Respect CFLAGS and LDFLAGS
+
+---
+ flx/Makefile | 4 ++--
+ include/rules.make | 5 ++---
+ signfs/Makefile | 4 ++--
+ 3 files changed, 6 insertions(+), 7 deletions(-)
+
+diff --git a/flx/Makefile b/flx/Makefile
+index 408c9b5..09e25b4 100644
+--- a/flx/Makefile
++++ b/flx/Makefile
+@@ -32,8 +32,8 @@ SRC=main.c arg.c utils.c md5.c flx.c fct1.c check.c sign.c \
+ output.c output_file.c
+ OBJ=$(SRC:.c=.o)
+ COPTS=-O2 -fno-strict-aliasing
+-CFLAGS= -Wall $(COPTS) -DMEM_OPTIM -DPROGRAM_NAME=\"$(NAME)\" -DPROGRAM_VERSION=\"$(VERSION)\" -U_FORTIFY_SOURCE
+-LDFLAGS=-L. -Wl,--gc-sections
++CFLAGS += -DMEM_OPTIM -DPROGRAM_NAME=\"$(NAME)\" -DPROGRAM_VERSION=\"$(VERSION)\" -U_FORTIFY_SOURCE
++LDFLAGS += -L. -Wl,--gc-sections
+
+ all: $(NAME)
+
+diff --git a/include/rules.make b/include/rules.make
+index f373aad..02240e0 100644
+--- a/include/rules.make
++++ b/include/rules.make
+@@ -1,8 +1,7 @@
+ CC ?= gcc
+
+-CFLAGS=$(GCC_ARCH_SMALL) $(GCC_CPU_SMALL) $(GCC_OPT_SMALL)
+-#-mpreferred-stack-boundary=2 -malign-jumps=0 -malign-loops=0 -malign-functions=0 -Os -march=i386 -mcpu=i386
+-LDFLAGS=-Wl,--gc-sections
++CFLAGS += $(GCC_ARCH_SMALL) $(GCC_CPU_SMALL) $(GCC_OPT_SMALL)
++LDFLAGS += -Wl,--gc-sections
+
+ all: $(OBJS)
+
+diff --git a/signfs/Makefile b/signfs/Makefile
+index d4214c6..ab03992 100644
+--- a/signfs/Makefile
++++ b/signfs/Makefile
+@@ -29,8 +29,8 @@ NAME=signfs
+ SRC=main.c signfs.c structure.c
+ OBJ=$(SRC:.c=.o)
+ COPTS=-Os -march=i386
+-CFLAGS=$(COPTS) -Wall
+-LDFLAGS=-L. -ltools
++CFLAGS += -Wall
++LDFLAGS += -L. -ltools
+ LIBTOOLS=md5.c libtools.c others.c
+
+ $(NAME): libtools.a $(OBJ)
diff --git a/flx/init/files/0.1.35-init-fix-a-major-bug-in-interactive-mode.patch b/flx/init/files/0.1.35-init-fix-a-major-bug-in-interactive-mode.patch
new file mode 100644
index 00000000..d9193875
--- /dev/null
+++ b/flx/init/files/0.1.35-init-fix-a-major-bug-in-interactive-mode.patch
@@ -0,0 +1,29 @@
+From 48946dbe5530abb8594002821f041694a4a26cb2 Mon Sep 17 00:00:00 2001
+From: Willy Tarreau <w@1wt.eu>
+Date: Mon, 13 Oct 2014 16:22:21 +0200
+Subject: [PATCH] init: fix a major bug in interactive mode
+
+A buffer overflow happens in interactive mode, where the prompt is copied
+into a string as large as the level of braces and forgets to also allocate
+enough room for the max string length. Moreover, the string copy is limited
+to the max string length but this size was not allocated. The net effect is
+init segfaulting in interactive mode when exiting a prompt using ".",
+because the message displayed when entering the mode overwrites some context
+info which his needed upon exit.
+---
+ init/init.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/init/init.c b/init/init.c
+index e0a45d9..7819410 100644
+--- a/init/init.c
++++ b/init/init.c
+@@ -1376,7 +1376,7 @@ int main(int argc, char **argv, char **envp) {
+ if (cmd_input == INPUT_KBD) {
+ int len;
+ char *cmd_ptr = cmd_line;
+- static char prompt[MAX_BRACE_LEVEL + 4];
++ static char prompt[sizeof(cmd_line) + MAX_BRACE_LEVEL + 4];
+ char *p = prompt;
+ int lev1, lev2;
+
diff --git a/flx/init/files/9999-MEDIUM-Remove-strip-and-uclibc.patch b/flx/init/files/9999-MEDIUM-Remove-strip-and-uclibc.patch
new file mode 100644
index 00000000..6ffe6b44
--- /dev/null
+++ b/flx/init/files/9999-MEDIUM-Remove-strip-and-uclibc.patch
@@ -0,0 +1,149 @@
+From caa62e8ba16c340aafd45375ec99f48261e62abf Mon Sep 17 00:00:00 2001
+From: Bertrand Jacquin <bertrand@jacquin.bzh>
+Date: Mon, 27 May 2013 22:36:39 +0200
+Subject: [PATCH 1/2] MEDIUM: Remove strip and uclibc
+
+---
+ flx/Makefile | 1 -
+ ifenslave/Makefile | 3 ---
+ include/rules.make | 16 +---------------
+ lcd/Makefile | 3 ---
+ mii/Makefile | 3 ---
+ mktmp/Makefile | 3 ---
+ remount/Makefile | 3 ---
+ signfs/Makefile | 1 -
+ wd/Makefile | 3 ---
+ 9 files changed, 1 insertion(+), 35 deletions(-)
+
+diff --git a/flx/Makefile b/flx/Makefile
+index 68ecb4c..408c9b5 100644
+--- a/flx/Makefile
++++ b/flx/Makefile
+@@ -39,7 +39,6 @@ all: $(NAME)
+
+ $(NAME): $(OBJ)
+ $(CC) -o $(NAME) $(OBJ) $(LDFLAGS)
+-# strip -R .note -R .comment signfs
+
+ clean:
+ @$(RM) -vf $(NAME) $(OBJ) $(LIBTOOLS:.c=.o) *~ core *.bak
+diff --git a/ifenslave/Makefile b/ifenslave/Makefile
+index 7ba3dc7..14fd640 100644
+--- a/ifenslave/Makefile
++++ b/ifenslave/Makefile
+@@ -13,9 +13,6 @@ ifenslave:
+
+ ifenslave%: ifenslave%.o
+ $(CC) $(LDFLAGS) $(CFLAGS) -o $@ $<
+- $(STRIP) -x --strip-unneeded -R .comment -R .note $@
+- $(OBJDUMP) -h $@ | grep -q '\.data[ ]*00000000' && $(STRIP) -R .data $@ || true
+- # sstrip $@
+
+ %.o: %.c
+ $(CC) $(CFLAGS) -c -o $@ $<
+diff --git a/include/rules.make b/include/rules.make
+index 715db29..f373aad 100644
+--- a/include/rules.make
++++ b/include/rules.make
+@@ -1,30 +1,16 @@
+ CC ?= gcc
+-STRIP ?= strip
+-OBJDUMP ?= objdump
+-SSTRIP ?= sstrip
+-UCLIBC ?= uclibc
+-
+-CC_ORIG := $(CC)
+-override CC := $(UCLIBC) $(CC) -Os
+
+ CFLAGS=$(GCC_ARCH_SMALL) $(GCC_CPU_SMALL) $(GCC_OPT_SMALL)
+ #-mpreferred-stack-boundary=2 -malign-jumps=0 -malign-loops=0 -malign-functions=0 -Os -march=i386 -mcpu=i386
+-LDFLAGS=-s -Wl,--gc-sections
++LDFLAGS=-Wl,--gc-sections
+
+ all: $(OBJS)
+
+ %: %.c
+ $(CC) $(LDFLAGS) $(CFLAGS) -o $@ $<
+- $(STRIP) -x --strip-unneeded -R .comment -R .note $@
+- $(OBJDUMP) -h $@ | grep -q '\.data[ ]*00000000' && $(STRIP) -R .data $@ || true
+- $(OBJDUMP) -h $@ | grep -q '\.sbss[ ]*00000000' && $(STRIP) -R .sbss $@ || true
+- #-if [ -n "$(SSTRIP)" ]; then $(SSTRIP) $@ ; fi
+
+ %-debug: %.c
+ $(CC) $(LDFLAGS) $(CFLAGS) -DDEBUG -o $@ $<
+- $(STRIP) -x --strip-unneeded -R .comment -R .note $@
+- $(OBJDUMP) -h $@ | grep -q '\.data[ ]*00000000' && $(STRIP) -R .data $@ || true
+- $(OBJDUMP) -h $@ | grep -q '\.sbss[ ]*00000000' && $(STRIP) -R .sbss $@ || true
+
+ clean:
+ @rm -f *.[ao] *~ core
+diff --git a/lcd/Makefile b/lcd/Makefile
+index 71d861f..4de920f 100644
+--- a/lcd/Makefile
++++ b/lcd/Makefile
+@@ -4,6 +4,3 @@ CFLAGS+=-fomit-frame-pointer
+
+ %: %.c
+ $(CC) $(LDFLAGS) $(CFLAGS) -o $@ $<
+- $(STRIP) -x --strip-unneeded -R .comment -R .note $@
+- $(OBJDUMP) -h $@ | grep -q '\.data[ ]*00000000' && $(STRIP) -R .data $@ || true
+- #$(SSTRIP) $@
+diff --git a/mii/Makefile b/mii/Makefile
+index 791f6b9..21d64d3 100644
+--- a/mii/Makefile
++++ b/mii/Makefile
+@@ -7,9 +7,6 @@ all: $(OBJS)
+
+ %-diag: %-diag.o libmii.o
+ $(CC) $(LDFLAGS) $(CFLAGS) -o $@ $^
+- $(STRIP) -x --strip-unneeded -R .comment -R .note $@
+- $(OBJDUMP) -h $@ | grep -q '\.data[ ]*00000000' && $(STRIP) -R .data $@ || true
+- #$(SSTRIP) $@
+
+ %.o: %.c
+ $(CC) -DLIBMII $(CFLAGS) -c -o $@ $<
+diff --git a/mktmp/Makefile b/mktmp/Makefile
+index 2188b91..ef4b083 100644
+--- a/mktmp/Makefile
++++ b/mktmp/Makefile
+@@ -4,6 +4,3 @@ include ../include/rules.make
+
+ %: %.c
+ $(CC) $(LDFLAGS) $(CFLAGS) -o $@ $<
+- $(STRIP) -x --strip-unneeded -R .comment -R .note $@
+- $(OBJDUMP) -h $@ | grep -q '\.data[ ]*00000000' && $(STRIP) -R .data $@ || true
+- #$(SSTRIP) $@
+diff --git a/remount/Makefile b/remount/Makefile
+index 5aa2491..54a79ad 100644
+--- a/remount/Makefile
++++ b/remount/Makefile
+@@ -7,6 +7,3 @@ remountw : remountr
+
+ %: %.c
+ $(CC) $(LDFLAGS) $(CFLAGS) -o $@ $<
+- $(STRIP) -x --strip-unneeded -R .comment -R .note $@
+- $(OBJDUMP) -h $@ | grep -q '\.data[ ]*00000000' && $(STRIP) -R .data $@ || true
+- -if [ -n "$(SSTRIP)" ]; then $(SSTRIP) $@ ; fi
+diff --git a/signfs/Makefile b/signfs/Makefile
+index f50b301..d4214c6 100644
+--- a/signfs/Makefile
++++ b/signfs/Makefile
+@@ -35,7 +35,6 @@ LIBTOOLS=md5.c libtools.c others.c
+
+ $(NAME): libtools.a $(OBJ)
+ $(CC) -o $(NAME) $(OBJ) $(LDFLAGS)
+- #strip -R .note -R .comment signfs
+
+ libtools.a: $(LIBTOOLS:.c=.o)
+ $(AR) -r libtools.a $(LIBTOOLS:.c=.o)
+diff --git a/wd/Makefile b/wd/Makefile
+index 6f1fa72..eaf857a 100644
+--- a/wd/Makefile
++++ b/wd/Makefile
+@@ -4,6 +4,3 @@ CFLAGS+=-fomit-frame-pointer
+
+ %: %.c
+ $(CC) $(LDFLAGS) $(CFLAGS) -W -Wall -U_FORTIFY_SOURCE -o $@ $<
+- $(STRIP) -x --strip-unneeded -R .comment -R .note $@
+- $(OBJDUMP) -h $@ | grep -q '\.data[ ]*00000000' && $(STRIP) -R .data $@ || true
+- -if [ -n "$(SSTRIP)" ]; then $(SSTRIP) $@ ; fi
diff --git a/flx/init/files/9999-MEDIUM-Respect-CFLAGS-and-LDFLAGS.patch b/flx/init/files/9999-MEDIUM-Respect-CFLAGS-and-LDFLAGS.patch
new file mode 100644
index 00000000..dec2fc8d
--- /dev/null
+++ b/flx/init/files/9999-MEDIUM-Respect-CFLAGS-and-LDFLAGS.patch
@@ -0,0 +1,56 @@
+From 25a9b5d4cd1b57c81e697ff7e54bf9121e8bbfa4 Mon Sep 17 00:00:00 2001
+From: Bertrand Jacquin <bertrand@jacquin.bzh>
+Date: Mon, 27 May 2013 22:36:39 +0200
+Subject: [PATCH 2/2] MEDIUM: Respect CFLAGS and LDFLAGS
+
+---
+ flx/Makefile | 4 ++--
+ include/rules.make | 5 ++---
+ signfs/Makefile | 4 ++--
+ 3 files changed, 6 insertions(+), 7 deletions(-)
+
+diff --git a/flx/Makefile b/flx/Makefile
+index 408c9b5..09e25b4 100644
+--- a/flx/Makefile
++++ b/flx/Makefile
+@@ -32,8 +32,8 @@ SRC=main.c arg.c utils.c md5.c flx.c fct1.c check.c sign.c \
+ output.c output_file.c
+ OBJ=$(SRC:.c=.o)
+ COPTS=-O2 -fno-strict-aliasing
+-CFLAGS= -Wall $(COPTS) -DMEM_OPTIM -DPROGRAM_NAME=\"$(NAME)\" -DPROGRAM_VERSION=\"$(VERSION)\" -U_FORTIFY_SOURCE
+-LDFLAGS=-L. -Wl,--gc-sections
++CFLAGS += -DMEM_OPTIM -DPROGRAM_NAME=\"$(NAME)\" -DPROGRAM_VERSION=\"$(VERSION)\" -U_FORTIFY_SOURCE
++LDFLAGS += -L. -Wl,--gc-sections
+
+ all: $(NAME)
+
+diff --git a/include/rules.make b/include/rules.make
+index f373aad..02240e0 100644
+--- a/include/rules.make
++++ b/include/rules.make
+@@ -1,8 +1,7 @@
+ CC ?= gcc
+
+-CFLAGS=$(GCC_ARCH_SMALL) $(GCC_CPU_SMALL) $(GCC_OPT_SMALL)
+-#-mpreferred-stack-boundary=2 -malign-jumps=0 -malign-loops=0 -malign-functions=0 -Os -march=i386 -mcpu=i386
+-LDFLAGS=-Wl,--gc-sections
++CFLAGS += $(GCC_ARCH_SMALL) $(GCC_CPU_SMALL) $(GCC_OPT_SMALL)
++LDFLAGS += -Wl,--gc-sections
+
+ all: $(OBJS)
+
+diff --git a/signfs/Makefile b/signfs/Makefile
+index d4214c6..ab03992 100644
+--- a/signfs/Makefile
++++ b/signfs/Makefile
+@@ -29,8 +29,8 @@ NAME=signfs
+ SRC=main.c signfs.c structure.c
+ OBJ=$(SRC:.c=.o)
+ COPTS=-Os -march=i386
+-CFLAGS=$(COPTS) -Wall
+-LDFLAGS=-L. -ltools
++CFLAGS += -Wall
++LDFLAGS += -L. -ltools
+ LIBTOOLS=md5.c libtools.c others.c
+
+ $(NAME): libtools.a $(OBJ)
diff --git a/flx/init/files/9999-error-struct-stat.diff b/flx/init/files/9999-error-struct-stat.diff
deleted file mode 100644
index 9d21b1ae..00000000
--- a/flx/init/files/9999-error-struct-stat.diff
+++ /dev/null
@@ -1,12 +0,0 @@
-diff --git a/init/mkdev.c b/init/mkdev.c
-index 47e4aa0..78a8c8d 100644
---- a/init/mkdev.c
-+++ b/init/mkdev.c
-@@ -49,6 +49,7 @@
- #include <stdlib.h>
- #include <sys/ioctl.h>
- #include <linux/loop.h>
-+#include <sys/stat.h>
-
-
- //#ifdef DEBUG
diff --git a/flx/init/files/9999-remove-strip-diet.diff b/flx/init/files/9999-remove-strip-diet.diff
deleted file mode 100644
index ffbbb0f5..00000000
--- a/flx/init/files/9999-remove-strip-diet.diff
+++ /dev/null
@@ -1,45 +0,0 @@
-From e0fa5f0e5e772c91bd38be344f9d8162ed913da8 Mon Sep 17 00:00:00 2001
-From: Bertrand Jacquin <bertrand@jacquin.bzh>
-Date: Mon, 27 May 2013 22:36:39 +0200
-Subject: [PATCH] MEDIUM: Remove strip and uclibc
-
----
- include/rules.make | 15 +--------------
- 1 file changed, 1 insertion(+), 14 deletions(-)
-
-diff --git a/include/rules.make b/include/rules.make
-index 715db29..ac19c79 100644
---- a/include/rules.make
-+++ b/include/rules.make
-@@ -1,30 +1,17 @@
- CC ?= gcc
--STRIP ?= strip
--OBJDUMP ?= objdump
--SSTRIP ?= sstrip
--UCLIBC ?= uclibc
--
--CC_ORIG := $(CC)
--override CC := $(UCLIBC) $(CC) -Os
-
- CFLAGS=$(GCC_ARCH_SMALL) $(GCC_CPU_SMALL) $(GCC_OPT_SMALL)
- #-mpreferred-stack-boundary=2 -malign-jumps=0 -malign-loops=0 -malign-functions=0 -Os -march=i386 -mcpu=i386
--LDFLAGS=-s -Wl,--gc-sections
-+LDFLAGS=-Wl,--gc-sections
-
- all: $(OBJS)
-
- %: %.c
- $(CC) $(LDFLAGS) $(CFLAGS) -o $@ $<
- $(STRIP) -x --strip-unneeded -R .comment -R .note $@
-- $(OBJDUMP) -h $@ | grep -q '\.data[ ]*00000000' && $(STRIP) -R .data $@ || true
-- $(OBJDUMP) -h $@ | grep -q '\.sbss[ ]*00000000' && $(STRIP) -R .sbss $@ || true
-- #-if [ -n "$(SSTRIP)" ]; then $(SSTRIP) $@ ; fi
-
- %-debug: %.c
- $(CC) $(LDFLAGS) $(CFLAGS) -DDEBUG -o $@ $<
-- $(STRIP) -x --strip-unneeded -R .comment -R .note $@
-- $(OBJDUMP) -h $@ | grep -q '\.data[ ]*00000000' && $(STRIP) -R .data $@ || true
-- $(OBJDUMP) -h $@ | grep -q '\.sbss[ ]*00000000' && $(STRIP) -R .sbss $@ || true
-
- clean:
- @rm -f *.[ao] *~ core
diff --git a/flx/init/files/9999-respect-CFLAGS-LDFLAGS.diff b/flx/init/files/9999-respect-CFLAGS-LDFLAGS.diff
deleted file mode 100644
index eee82589..00000000
--- a/flx/init/files/9999-respect-CFLAGS-LDFLAGS.diff
+++ /dev/null
@@ -1,24 +0,0 @@
-From fec67f5e0511469c50bfdd984ab9f3c5399dacad Mon Sep 17 00:00:00 2001
-From: Bertrand Jacquin <bertrand@jacquin.bzh>
-Date: Mon, 27 May 2013 22:36:39 +0200
-Subject: [PATCH] MEDIUM: Respect CFLAGS and LDFLAGS
-
----
- include/rules.make | 5 ++---
- 1 file changed, 2 insertions(+), 3 deletions(-)
-
-diff --git a/include/rules.make b/include/rules.make
-index ac19c79..5aecf0a 100644
---- a/include/rules.make
-+++ b/include/rules.make
-@@ -1,8 +1,7 @@
- CC ?= gcc
-
--CFLAGS=$(GCC_ARCH_SMALL) $(GCC_CPU_SMALL) $(GCC_OPT_SMALL)
--#-mpreferred-stack-boundary=2 -malign-jumps=0 -malign-loops=0 -malign-functions=0 -Os -march=i386 -mcpu=i386
--LDFLAGS=-Wl,--gc-sections
-+CFLAGS += $(GCC_ARCH_SMALL) $(GCC_CPU_SMALL) $(GCC_OPT_SMALL)
-+LDFLAGS += -Wl,--gc-sections
-
- all: $(OBJS)
-
diff --git a/flx/init/init-0.1.34.ebuild b/flx/init/init-0.1.35.ebuild
index faf506eb..9bfd2587 100644
--- a/flx/init/init-0.1.34.ebuild
+++ b/flx/init/init-0.1.35.ebuild
@@ -21,9 +21,9 @@ RDEPEND="${DEPEND}"
src_prepare () {
default
- epatch "${FILESDIR}/${PV}-remove-strip-diet.diff"
- epatch "${FILESDIR}/${PV}-respect-CFLAGS-LDFLAGS.diff"
- epatch "${FILESDIR}/${PV}-no-no-omit-leaf-frame-pointer.diff"
+ epatch "${FILESDIR}/${PV}-init-fix-a-major-bug-in-interactive-mode.patch"
+ epatch "${FILESDIR}/${PV}-MEDIUM-Remove-strip-and-uclibc.patch"
+ epatch "${FILESDIR}/${PV}-MEDIUM-Respect-CFLAGS-and-LDFLAGS.patch"
tc-export CC
}
diff --git a/flx/init/init-9999.ebuild b/flx/init/init-9999.ebuild
index 8daafbf2..ef7ed569 100644
--- a/flx/init/init-9999.ebuild
+++ b/flx/init/init-9999.ebuild
@@ -20,8 +20,8 @@ RDEPEND="${DEPEND}"
src_prepare () {
default
- epatch "${FILESDIR}/${PV}-remove-strip-diet.diff"
- epatch "${FILESDIR}/${PV}-respect-CFLAGS-LDFLAGS.diff"
+ epatch "${FILESDIR}/${PV}-MEDIUM-Remove-strip-and-uclibc.patch"
+ epatch "${FILESDIR}/${PV}-MEDIUM-Respect-CFLAGS-and-LDFLAGS.patch"
tc-export CC
}