From owner-freebsd-questions@FreeBSD.ORG Sat Feb 11 21:33:21 2012 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AAD361065674 for ; Sat, 11 Feb 2012 21:33:21 +0000 (UTC) (envelope-from freebsd@pki2.com) Received: from btw.pki2.com (btw.pki2.com [IPv6:2001:470:a:6fd::2]) by mx1.freebsd.org (Postfix) with ESMTP id 4FD1E8FC19 for ; Sat, 11 Feb 2012 21:33:21 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) by btw.pki2.com (8.14.5/8.14.5) with ESMTP id q1BLXFuO011263 for ; Sat, 11 Feb 2012 13:33:15 -0800 (PST) (envelope-from freebsd@pki2.com) From: Dennis Glatting To: freebsd-questions@freebsd.org Content-Type: text/plain; charset="ISO-8859-1" Date: Sat, 11 Feb 2012 13:33:15 -0800 Message-ID: <1328995995.65205.1.camel@btw.pki2.com> Mime-Version: 1.0 X-Mailer: Evolution 2.32.1 FreeBSD GNOME Team Port Content-Transfer-Encoding: 7bit X-yoursite-MailScanner-Information: Dennis Glatting X-yoursite-MailScanner-ID: q1BLXFuO011263 X-yoursite-MailScanner: Found to be clean X-MailScanner-From: freebsd@pki2.com Subject: Can clang compile RELENG_9? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 11 Feb 2012 21:33:21 -0000 I get errors when trying to compile RELENG_9 with clang. Is clag suppose to work when it comes to compiling the OS or am I missing something: clang -O2 -pipe -DUSE_GZIP=1 -I/usr/src/usr.sbin/sysinstall/../../gnu/lib/libodialog -I. -std=gnu99 -fstack-protector -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -Wno-pointer-sign -Wno-tautological-compare -Wno-unused-value -Wno-parentheses-equality -Wno-unused-function -Wno-conversion -Wno-switch-enum -Wno-empty-body -c /usr/src/usr.sbin/sysinstall/dispatch.c /usr/src/usr.sbin/sysinstall/dispatch.c:594:17: error: format string is not a string literal (potentially insecure) [-Werror,-Wformat-security] msgConfirm(err); ^~~ 1 error generated. *** Error code 1 When compiling the kernel: clang -c -O2 -pipe -fno-strict-aliasing -std=c99 -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../../.. -I../../../contrib/altq -D_KERNEL -DHAVE_KERNEL_OPTION_HEADERS -include opt_global.h -fno-omit-frame-pointer -mno-aes -mno-avx -mcmodel=kernel -mno-red-zone -mno-mmx -msoft-float -fno-asynchronous-unwind-tables -ffreestanding -fstack-protector -Werror ../../../dev/an/if_an.c ../../../dev/an/if_an.c:799:41: error: implicit conversion from enumeration type 'enum ieee80211_phytype' to different enumeration type 'enum ieee80211_phymode' [-Werror,-Wconversion] mword = ieee80211_rate2media(NULL, r, IEEE80211_T_DS); ~~~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~ ../../../dev/an/if_an.c:3301:30: error: implicit conversion from enumeration type 'enum ieee80211_phytype' to different enumeration type 'enum ieee80211_phymode' [-Werror,-Wconversion] status.an_current_tx_rate, IEEE80211_T_DS); ^~~~~~~~~~~~~~ 2 errors generated. *** Error code 1