From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:53914) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TugBC-0004rq-5Q for qemu-devel@nongnu.org; Mon, 14 Jan 2013 04:18:14 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TugB6-0002s7-BV for qemu-devel@nongnu.org; Mon, 14 Jan 2013 04:18:06 -0500 Received: from mail-we0-f182.google.com ([74.125.82.182]:45363) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TugB6-0002s0-5h for qemu-devel@nongnu.org; Mon, 14 Jan 2013 04:18:00 -0500 Received: by mail-we0-f182.google.com with SMTP id u54so1931107wey.41 for ; Mon, 14 Jan 2013 01:17:59 -0800 (PST) Date: Mon, 14 Jan 2013 10:17:56 +0100 From: Stefan Hajnoczi Message-ID: <20130114091756.GD11260@stefanha-thinkpad.redhat.com> References: <50F04581.7080902@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <50F04581.7080902@redhat.com> Subject: Re: [Qemu-devel] Fix the glib deprecated APIs List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini Cc: Ramesh G , qemu-devel@nongnu.org On Fri, Jan 11, 2013 at 06:01:53PM +0100, Paolo Bonzini wrote: > Il 11/01/2013 17:10, Ramesh G ha scritto: > > > > Hi, > > > > I got a couple of below compilation errors while compiling with glib > > > 2.32. > > > > $ make > > CC ../trace/simple.o > > ../trace/simple.c: In function ‘trace_thread_create’: > > ../trace/simple.c:407:5: error: ‘g_thread_create’ is deprecated > > (declared at /usr/include/glib-2.0/glib/deprecated/gthread.h:100): Use > > 'g_thread_new' instead [-Werror=deprecated-declarations] > > ../trace/simple.c: In function ‘trace_backend_init’: > > ../trace/simple.c:428:5: error: ‘g_cond_new’ is deprecated (declared at > > /usr/include/glib-2.0/glib/deprecated/gthread.h:275) > > [-Werror=deprecated-declarations] > > ../trace/simple.c:429:5: error: ‘g_cond_new’ is deprecated (declared at > > /usr/include/glib-2.0/glib/deprecated/gthread.h:275) > > [-Werror=deprecated-declarations] > > cc1: all warnings being treated as errors > > make: *** [../trace/simple.o] Error 1 > > $ > > > > I found these APIs have been deprecated in 2.32. Please find the patch > > attached which fixes this problem. Please let me know your thoughts. > > Could you instead change it to use qemu-thread? The reason to avoid QEMU APIs is to prevent entering an infinite loop if a trace event is placed into the qemu-thread code. Stefan