Lines 34-40
Link Here
|
34 |
} |
34 |
} |
35 |
|
35 |
|
36 |
src_prepare() { |
36 |
src_prepare() { |
37 |
sed -e '/-fomit-frame-pointer/d' -e '/-mno-align-long-strings/d' \ |
37 |
#gcc 4.6 support |
|
|
38 |
if [ `echo $(tc-getCC) | grep gcc` ] ; then |
39 |
GCCVER=`$(tc-getCC) -dumpversion` |
40 |
GCCMAJOR=`echo ${GCCVER} | cut -f1 -d.` |
41 |
GCCMINOR=`echo ${GCCVER} | cut -f2 -d.` |
42 |
if [[ ${GCCMAJOR} -eq 4 && ${GCCMINOR} -ge 6 ]] ; then |
43 |
einfo "Detect gcc-4.6 or later version." |
44 |
epatch "${FILESDIR}"/${PN}-9.1-gcc46.patch |
45 |
sed -i -e '/-m elf_i386_fbsd/d' "${S}"/i386/Makefile.inc || die |
46 |
for dir in boot2 gptboot gptzfsboot zfsboot; do |
47 |
sed -i -e 's:^LDFLAGS=\(.*\):LDFLAGS=\1 -m elf_i386_fbsd:' \ |
48 |
"${S}"/i386/${dir}/Makefile || die |
49 |
done |
50 |
fi |
51 |
fi |
52 |
|
53 |
sed -e '/-mno-align-long-strings/d' \ |
38 |
-i "${S}"/i386/boot2/Makefile \ |
54 |
-i "${S}"/i386/boot2/Makefile \ |
39 |
-i "${S}"/i386/gptboot/Makefile \ |
55 |
-i "${S}"/i386/gptboot/Makefile \ |
40 |
-i "${S}"/i386/gptzfsboot/Makefile \ |
56 |
-i "${S}"/i386/gptzfsboot/Makefile \ |