Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 09 Aug 2012 16:15:36 +0400
From:      Boris Samorodov <bsam@passap.ru>
To:        freebsd-current@FreeBSD.org
Subject:   [clang] kernel build failure
Message-ID:  <5023A9E8.6040503@passap.ru>

next in thread | raw e-mail | index | archive | help
Hi!

The kernel build fails at fresh CURRENT. At first I get a couple of
same warnings like:
-----
clang -c -O -pipe  -std=c99 -g -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-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_global.h  -mno-aes -mno-avx 
-mno-mmx -mno-sse -msoft-float -ffreestanding -fstack-protector
    /usr/src/sys/cam/scsi/scsi_cd.c
/usr/src/sys/cam/scsi/scsi_cd.c:571:7: warning: implicit declaration of 
function 'scsi_extract_sense_ccb' is invalid in C99 
[-Wimplicit-function-declaration]
                     scsi_extract_sense_ccb(ccb,
                     ^
-----

And then I get an error:
-----
linking kernel.debug
cam_periph.o: In function `cam_periph_error':
/usr/src/sys/cam/cam_periph.c:1776: undefined reference to 
`scsi_extract_sense_ccb'
scsi_cd.o: In function `cdasync':
/usr/src/sys/cam/scsi/scsi_cd.c:571: undefined reference to 
`scsi_extract_sense_ccb'
scsi_da.o: In function `daasync':
/usr/src/sys/cam/scsi/scsi_da.c:1394: undefined reference to 
`scsi_extract_sense_ccb'
*** [kernel.debug] Error code 1
-----

The system...:
-----
% uname -a
FreeBSD bsam.wart.ru 10.0-CURRENT FreeBSD 10.0-CURRENT #21 r238828M: Fri 
Jul 27 16:26:02 SAMT 2012     bsam@bsam.wart.ru:/usr/obj/usr/src/sys/BBX 
  i386
-----

...is build with options:
-----
WITH_CLANG_IS_CC="YES"
WITH_LIBCPLUSPLUS="YES"
-----

-- 
WBR, Boris Samorodov (bsam)
FreeBSD Committer, http://www.FreeBSD.org The Power To Serve



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?5023A9E8.6040503>