commit: f6b465debcc65eda41084008cd24aad9c2f6f0fc
Author: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org>
AuthorDate: Sun Sep 3 06:27:10 2017 +0000
Commit: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org>
CommitDate: Sun Sep 3 06:28:16 2017 +0000
URL: https://gitweb.gentoo.org/proj/genkernel.git/commit/?id=f6b465de
gen_compile: allow mdadm-4 to compile.
Signed-off-by: Robin H. Johnson <robbat2 <AT> gentoo.org>
gen_compile.sh | 17 ++++++++++-------
1 file changed, 10 insertions(+), 7 deletions(-)
diff --git a/gen_compile.sh b/gen_compile.sh
index 19ea1ce..1cd1ebf 100755
--- a/gen_compile.sh
+++ b/gen_compile.sh
@@ -576,17 +576,20 @@ compile_mdadm() {
cd "${MDADM_DIR}"
apply_patches mdadm ${MDADM_VER}
- sed -i "/^CFLAGS = /s:^CFLAGS = \(.*\)$:CFLAGS = -Os:" Makefile
- sed -i "/^CXFLAGS = /s:^CXFLAGS = \(.*\)$:CXFLAGS = -Os:"
Makefile
- sed -i "/^CWFLAGS = /s:^CWFLAGS = \(.*\)$:CWFLAGS = -Wall:"
Makefile
- sed -i "s/^# LDFLAGS = -static/LDFLAGS = -static/" Makefile
+ defs='-DNO_DLM -DNO_COROSYNC'
+ sed -i \
+ -e "/^CFLAGS = /s:^CFLAGS = \(.*\)$:CFLAGS = -Os
${defs}:" \
+ -e "/^CXFLAGS = /s:^CXFLAGS = \(.*\)$:CXFLAGS = -Os
${defs}:" \
+ -e "/^CWFLAGS = /s:^CWFLAGS = \(.*\)$:CWFLAGS = -Wall:"
\
+ -e "s/^# LDFLAGS = -static/LDFLAGS = -static/" \
+ Makefile || gen_die "Failed to sed mdadm Makefile"
print_info 1 'mdadm: >> Compiling...'
- compile_generic 'mdadm mdmon' utils
+ compile_generic 'mdadm mdmon' utils
mkdir -p "${TEMP}/mdadm/sbin"
- install -m 0755 -s mdadm "${TEMP}/mdadm/sbin/mdadm"
- install -m 0755 -s mdmon "${TEMP}/mdadm/sbin/mdmon"
+ install -m 0755 -s mdadm "${TEMP}/mdadm/sbin/mdadm" || gen_die
"Failed mdadm install"
+ install -m 0755 -s mdmon "${TEMP}/mdadm/sbin/mdmon" || gen_die
"Failed mdmon install"
print_info 1 ' >> Copying to bincache...'
cd "${TEMP}/mdadm"
${UTILS_CROSS_COMPILE}strip "sbin/mdadm" "sbin/mdmon" ||