Date: Sun, 30 Sep 2012 06:04:48 -0700 From: David Wolfskill <david@catwhisker.org> To: current@freebsd.org Subject: clang reports reports errors (buildkernel @r241067) Message-ID: <20120930130448.GQ1645@albert.catwhisker.org>
next in thread | raw e-mail | index | archive | help
--8so8ZvRz607RvwFp Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable E.g.: =2E.. =3D=3D=3D> bios (all) =3D=3D=3D> bios/smapi (all) ctfconvert -L VERSION -g hdacc.o clang -O2 -pipe -fno-strict-aliasing -D_KERNEL -DKLD_MODULE -nostdinc -DH= AVE_KERNEL_OPTION_HEADERS -include /common/S4/obj/usr/src/sys/CANARY/opt_gl= obal.h -I. -I@ -I@/contrib/altq -fno-common -g -I/common/S4/obj/usr/src/sys= /CANARY -mno-aes -mno-avx -mno-mmx -mno-sse -msoft-float -ffreestanding -f= stack-protector -std=3Diso9899:1999 -Qunused-arguments -fstack-protector -W= all -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing-proto= types -Wpointer-arith -Winline -Wcast-qual -Wundef -Wno-pointer-sign -ffor= mat-extensions -Wmissing-include-dirs -fdiagnostics-show-option -Wno-erro= r-tautological-compare -Wno-error-empty-body -Wno-error-parentheses-equali= ty -no-integrated-as -c /usr/src/sys/modules/bios/smapi/../../../i386/bios= /smapi_bios.S clang -c -O -pipe -std=3Dc99 -g -Wall -Wredundant-decls -Wnested-externs -= Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qu= al -Wundef -Wno-pointer-sign -fformat-extensions -Wmissing-include-dirs -= fdiagnostics-show-option -Wno-error-tautological-compare -Wno-error-empty-= body -Wno-error-parentheses-equality -nostdinc -I. -I/usr/src/sys -I/usr/= src/sys/contrib/altq -D_KERNEL -DHAVE_KERNEL_OPTION_HEADERS -include opt_gl= obal.h -mno-aes -mno-avx -mno-mmx -mno-sse -msoft-float -ffreestanding -fs= tack-protector -Werror /usr/src/sys/dev/sound/pcm/ac97.c ctfconvert -L VERSION -g smapi_bios.o ctfconvert -L VERSION -g ac97.o clang -O2 -pipe -fno-strict-aliasing -D_KERNEL -DKLD_MODULE -nostdinc -DH= AVE_KERNEL_OPTION_HEADERS -include /common/S4/obj/usr/src/sys/CANARY/opt_gl= obal.h -I. -I@ -I@/contrib/altq -fno-common -g -I/common/S4/obj/usr/src/sys= /CANARY -mno-aes -mno-avx -mno-mmx -mno-sse -msoft-float -ffreestanding -f= stack-protector -std=3Diso9899:1999 -Qunused-arguments -fstack-protector -W= all -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing-proto= types -Wpointer-arith -Winline -Wcast-qual -Wundef -Wno-pointer-sign -ffor= mat-extensions -Wmissing-include-dirs -fdiagnostics-show-option -Wno-erro= r-tautological-compare -Wno-error-empty-body -Wno-error-parentheses-equali= ty -c /usr/src/sys/modules/bios/smapi/../../../i386/bios/smapi.c ctfconvert -L VERSION -g hdac.o /usr/src/sys/modules/bios/smapi/../../../i386/bios/smapi.c:295:3: warning: = implicit declaration of function 'free' is invalid in C99 [-Wimplicit-funct= ion-declaration] free(devs, M_TEMP); ^ /usr/src/sys/modules/bios/smapi/../../../i386/bios/smapi.c:295:14: error: u= se of undeclared identifier 'M_TEMP' free(devs, M_TEMP); ^ 1 warning and 1 error generated. clang -c -O -pipe -std=3Dc99 -g -Wall -Wredundant-decls -Wnested-externs -= Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qu= al -Wundef -Wno-pointer-sign -fformat-extensions -Wmissing-include-dirs -= fdiagnostics-show-option -Wno-error-tautological-compare -Wno-error-empty-= body -Wno-error-parentheses-equality -nostdinc -I. -I/usr/src/sys -I/usr/= src/sys/contrib/altq -D_KERNEL -DHAVE_KERNEL_OPTION_HEADERS -include opt_gl= obal.h -mno-aes -mno-avx -mno-mmx -mno-sse -msoft-float -ffreestanding -fs= tack-protector -Werror /usr/src/sys/dev/sound/pcm/ac97_patch.c *** [smapi.o] Error code 1 1 error *** [all] Error code 2 1 error *** [all] Error code 2 1 error *** [modules-all] Error code 2 clang -c -O -pipe -std=3Dc99 -g -Wall -Wredundant-decls -Wnested-externs -= Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qu= al -Wundef -Wno-pointer-sign -fformat-extensions -Wmissing-include-dirs -= fdiagnostics-show-option -Wno-error-tautological-compare -Wno-error-empty-= body -Wno-error-parentheses-equality -nostdinc -I. -I/usr/src/sys -I/usr/= src/sys/contrib/altq -D_KERNEL -DHAVE_KERNEL_OPTION_HEADERS -include opt_gl= obal.h -mno-aes -mno-avx -mno-mmx -mno-sse -msoft-float -ffreestanding -fs= tack-protector -Werror /usr/src/sys/dev/sound/pcm/channel.c ctfconvert -L VERSION -g ac97_patch.o ctfconvert -L VERSION -g channel.o ctfconvert -L VERSION -g hdaa.o 1 error *** [buildkernel] Error code 2 1 error *** [buildkernel] Error code 2 1 error It looks to me as if sys/i386/bios/smapi.c lacks #include <sys/types.h> #include <sys/malloc.h> (ref. free(9)) -- but I'm not all that much of a kernel hacker, so I may well be off-base here. Peace, david --=20 David H. Wolfskill david@catwhisker.org Depriving a girl or boy of an opportunity for education is evil. See http://www.catwhisker.org/~david/publickey.gpg for my public key. --8so8ZvRz607RvwFp Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (FreeBSD) iEYEARECAAYFAlBoQ28ACgkQmprOCmdXAD3eLgCcDZ8QjG023721Z9xxOPzV8F6W mpEAn0I388727bP/hXPJtQBcViZYkRa1 =+1DK -----END PGP SIGNATURE----- --8so8ZvRz607RvwFp--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20120930130448.GQ1645>