From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:34483) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TUeeS-0007a2-Pd for qemu-devel@nongnu.org; Sat, 03 Nov 2012 10:24:45 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TUeeR-00048f-U5 for qemu-devel@nongnu.org; Sat, 03 Nov 2012 10:24:44 -0400 Received: from mail-pa0-f45.google.com ([209.85.220.45]:49074) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TUeeR-00047x-GJ for qemu-devel@nongnu.org; Sat, 03 Nov 2012 10:24:43 -0400 Received: by mail-pa0-f45.google.com with SMTP id fb10so2941745pad.4 for ; Sat, 03 Nov 2012 07:24:42 -0700 (PDT) Sender: Paolo Bonzini Message-ID: <50952924.7070405@redhat.com> Date: Sat, 03 Nov 2012 15:24:36 +0100 From: Paolo Bonzini MIME-Version: 1.0 References: <1351867404-25510-1-git-send-email-pbonzini@redhat.com> <509527DF.6040801@redhat.com> In-Reply-To: <509527DF.6040801@redhat.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH v2 0/5] Fixes for thread pool patches. List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Blue Swirl , Peter Maydell , qemu-devel@nongnu.org, jan.kiszka@siemens.com Il 03/11/2012 15:19, Paolo Bonzini ha scritto: > Il 03/11/2012 12:50, Blue Swirl ha scritto: >> I'm still getting problems with Clang on Linux: >> >> CC qemu-sockets.o >> /src/qemu/qemu-sockets.c:64:12: error: function >> 'default_monitor_get_fd' is not needed and will not be emitted >> [-Werror,-Wunneeded-internal-declaration] >> static int default_monitor_get_fd(Monitor *mon, const char *name, Error **errp) >> ^ >> /src/qemu/qemu-sockets.c:73:12: error: function >> 'default_qemu_set_fd_handler2' is not needed and will not be emitted >> [-Werror,-Wunneeded-internal-declaration] >> static int default_qemu_set_fd_handler2(int fd, >> ^ >> 2 errors generated. >> >> Perhaps the weak magic isn't so great after all. >> > > It's a clang bug. The error should be suppressed, since the function is > used with the weak alias. > > Or try if adding "|| defined __clang__" to compiler.h fixes it. Other possible fixes include adding "inline" to the declarations, or of course -Wno-unneeded-internal-declaration. Paolo