Re: Building with external toolchain was broken 6 months ago wit
On 18 Mar 2014, at 22:01 , John-Mark Gurney <jmg@funkthat.com> wrote:
> Lev Serebryakov wrote this message on Wed, Mar 19, 2014 at 01:37 +0400:
>> I did't build my NanoBSD images for almost year, and in this time our
>> not-finished and fragile support for using "external" toolchain is rotte=
n,
>> due to r255187 (and, may meb, some other commits too).
>> =
>> I have very fresh -CURRENT (r263296)
>> =
>> I have these settings for my buildworld & buildkernel targets:
>> =
>> XCC=3D/usr/bin/cc
>> XCXX=3D/usr/bin/c++
>> XCPP=3D/usr/bin/cpp
>> XAS=3D/usr/bin/as
>> XAR=3D/usr/bin/ar
>> XLD=3D/usr/bin/ld
>> XNM=3D/usr/bin/nm
>> XOBJDUMP=3D/usr/bin/objdump
>> XRANLIB=3D/usr/bin/ranlib
>> XSTRINGS=3D/usr/bin/strings
>> COMPILER_TYPE=3Dclang
>> WITHOUT_CROSS_COMPILER=3Dyes
>> WITHOUT_BINUTILS=3Dyes
>> WITHOUT_CLANG=3Dyes
>> =
>> It worked 7 months ago. Now it works for "buildworld" but not for
>> "buildkernel:
>> =
>> --- aeskeys_amd64.o ---
>> /usr/bin/cc --sysroot=3D/data/obj.nano/gateway.v2/data/src/tmp -B/data/o=
bj.nano/gateway.v2/data/src/tmp/usr/bin -O2 -pipe -fno-strict-aliasing -Wer=
ror -D_KERNEL -DKLD_MODULE -nostdinc -DHAVE_KERNEL_OPTION_HEADERS -includ=
e /data/obj.nano/gateway.v2/data/src/sys/D2500CC/opt_global.h -I. -I@ -I@/c=
ontrib/altq -fno-common -g -fno-omit-frame-pointer -mno-omit-leaf-frame-poi=
nter -I/data/obj.nano/gateway.v2/data/src/sys/D2500CC -mno-aes -mno-avx -m=
cmodel=3Dkernel -mno-red-zone -mno-mmx -mno-sse -msoft-float -fno-asynchro=
nous-unwind-tables -ffreestanding -fstack-protector -std=3Diso9899:1999 -Qu=
nused-arguments -fstack-protector -Wall -Wredundant-decls -Wnested-externs=
-Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-=
qual -Wundef -Wno-pointer-sign -fformat-extensions -Wmissing-include-dirs=
-fdiagnostics-show-option -Wno-error-tautological-compare -Wno-error-empt=
y-body -Wno-error-parentheses-equality -Wno-unused-function -c /data/sr=
c/sys/modules/aesni/../../cryp
> to/aesni/aeskeys_amd64.S
>> --- aesni_wrap.o ---
>> In file included from /data/src/sys/modules/aesni/../../crypto/aesni/aes=
ni_wrap.c:40:
>> /data/src/sys/modules/aesni/../../crypto/aesni/aesencdec.h:30:10: fatal =
error: 'wmmintrin.h' file not found
>> #include <wmmintrin.h>
>> ^
>> 1 error generated.
>> *** [aesni_wrap.o] Error code 1
>> =
>> It could not find header file with intrinsics from "system" ("external")
>> clang. I could disable building of this module with WITHOUT_MODULES=3Dae=
sni,
>> and it works, but what if I need this module?
>> =
>> Could it be fixed, pleeeeeeease?
> =
> Sounds like your tool chain doesn't have the necessary support for
> AES-NI... Are you using gcc as cc? If so, do you have the necessary
> tool chain work that I did in r255185 in your local tree?
The problem is that the kernel is deepening on a compiler header which is n=
ot in the right place in objdir if the compiler is not built. I thought I =
had reported this before (maybe just informally). I have been helping myse=
lf locally using this:
Index: sys/modules/aesni/Makefile
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- sys/modules/aesni/Makefile (revision 263176)
+++ sys/modules/aesni/Makefile (working copy)
@@ -11,7 +11,8 @@ OBJS+=3D aesni_wrap.o
=
# Remove -nostdinc so we can get the intrinsics.
aesni_wrap.o: aesni_wrap.c
- ${CC} -c ${CFLAGS:C/^-O2$/-O3/:N-nostdinc} ${WERROR} ${PROF} \
+ ${CC} -I${.CURDIR}/../../../contrib/llvm/tools/clang/lib/Headers \
+ -c ${CFLAGS:C/^-O2$/-O3/:N-nostdinc} ${WERROR} ${PROF} \
-mmmx -msse -maes ${.IMPSRC}
${CTFCONVERT_CMD}
=97 =
Bjoern A. Zeeb ????????? ??? ??????? ??????:
'??? ??? ???? ?????? ??????? ?? ?? ??????? ??????? ??? ????? ????? ????
?????? ?? ????? ????', ????????? ?????????, "??? ????? ?? ?????", ?.???
_______________________________________________
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscribe@freebsd.org"
討論串 (同標題文章)
完整討論串 (本文為第 2 之 13 篇):