From patchwork Mon Sep 7 14:00:01 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Egger X-Patchwork-Id: 33081 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by bilbo.ozlabs.org (Postfix) with ESMTPS id 77BA0B70CF for ; Tue, 8 Sep 2009 00:09:03 +1000 (EST) Received: from localhost ([127.0.0.1]:54272 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Mkett-00018V-1A for incoming@patchwork.ozlabs.org; Mon, 07 Sep 2009 10:08:57 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MkenB-0007P1-Vb for qemu-devel@nongnu.org; Mon, 07 Sep 2009 10:02:02 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Mken5-0007Na-4Z for qemu-devel@nongnu.org; Mon, 07 Sep 2009 10:02:00 -0400 Received: from [199.232.76.173] (port=46585 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Mken3-0007NS-CR for qemu-devel@nongnu.org; Mon, 07 Sep 2009 10:01:53 -0400 Received: from va3ehsobe003.messaging.microsoft.com ([216.32.180.13]:42098 helo=VA3EHSOBE003.bigfish.com) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_ARCFOUR_MD5:16) (Exim 4.60) (envelope-from ) id 1Mken2-0002Y5-KR for qemu-devel@nongnu.org; Mon, 07 Sep 2009 10:01:52 -0400 Received: from mail108-va3-R.bigfish.com (10.7.14.246) by VA3EHSOBE003.bigfish.com (10.7.40.23) with Microsoft SMTP Server id 8.1.340.0; Mon, 7 Sep 2009 14:01:50 +0000 Received: from mail108-va3 (localhost.localdomain [127.0.0.1]) by mail108-va3-R.bigfish.com (Postfix) with ESMTP id 9B02C3384C4 for ; Mon, 7 Sep 2009 14:01:49 +0000 (UTC) X-SpamScore: 4 X-BigFish: VPS4(zza594izz1202hzzz32i6bh203h34h43j65h) X-Spam-TCS-SCL: 4:0 X-FB-SS: 5, Received: by mail108-va3 (MessageSwitch) id 1252332107772849_4733; Mon, 7 Sep 2009 14:01:47 +0000 (UCT) Received: from ausb3extmailp01.amd.com (unknown [163.181.251.8]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail108-va3.bigfish.com (Postfix) with ESMTP id 342E21B7806B for ; Mon, 7 Sep 2009 14:01:12 +0000 (UTC) Received: from ausb3twp01.amd.com ([163.181.250.37]) by ausb3extmailp01.amd.com (Switch-3.2.7/Switch-3.2.7) with ESMTP id n87E15iA019960 for ; Mon, 7 Sep 2009 09:01:08 -0500 X-WSS-ID: 0KPLTLR-01-52Q-02 X-M-MSG: Received: from sausexbh1.amd.com (sausexbh1.amd.com [163.181.22.101]) by ausb3twp01.amd.com (Tumbleweed MailGate 3.7.0) with ESMTP id 2773310284CF for ; Mon, 7 Sep 2009 09:01:03 -0500 (CDT) Received: from sausexmb2.amd.com ([163.181.3.157]) by sausexbh1.amd.com with Microsoft SMTPSVC(6.0.3790.3959); Mon, 7 Sep 2009 09:01:06 -0500 Received: from SDRSEXMB1.amd.com ([172.20.3.116]) by sausexmb2.amd.com with Microsoft SMTPSVC(6.0.3790.3959); Mon, 7 Sep 2009 09:01:06 -0500 Received: from seurexmb1.amd.com ([165.204.9.130]) by SDRSEXMB1.amd.com with Microsoft SMTPSVC(6.0.3790.3959); Mon, 7 Sep 2009 16:01:03 +0200 Received: from donner.osrc.amd.com ([165.204.15.15]) by seurexmb1.amd.com with Microsoft SMTPSVC(6.0.3790.3959); Mon, 7 Sep 2009 16:00:03 +0200 From: Christoph Egger To: qemu-devel@nongnu.org Date: Mon, 7 Sep 2009 16:00:01 +0200 User-Agent: KMail/1.9.10 MIME-Version: 1.0 Message-ID: <200909071600.02095.Christoph.Egger@amd.com> X-OriginalArrivalTime: 07 Sep 2009 14:00:03.0529 (UTC) FILETIME=[7F5B2B90:01CA2FC3] X-detected-operating-system: by monty-python.gnu.org: Windows 2000 SP4, XP SP1+ Subject: [Qemu-devel] [PATCH] build fix for audio/mixeng.c X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Hi! Attached patch fixes the build errors: audio/mixeng.c:150: error: 'conv_natural_uint8_t_to_mono' undeclared here (not in a function) audio/mixeng.c:151: error: 'conv_natural_uint16_t_to_mono' undeclared here (not in a function) audio/mixeng.c:152: error: 'conv_natural_uint32_t_to_mono' undeclared here (not in a function) [...] NetBSD provides standard types by default as both a typedef and a macro hence the fix makes the function use match the function definition. Signed-off-by: Christoph Egger diff --git a/audio/mixeng.c b/audio/mixeng.c index 8ce942e..aefdab2 100644 --- a/audio/mixeng.c +++ b/audio/mixeng.c @@ -143,56 +143,59 @@ #undef IN_T #undef SHIFT +/* NetBSD provides standard types by default as both a typedef and a macro */ +#define concat(x,y,z) glue(glue(x,y),z) + t_sample *mixeng_conv[2][2][2][3] = { { { { - conv_natural_uint8_t_to_mono, - conv_natural_uint16_t_to_mono, - conv_natural_uint32_t_to_mono + concat(conv_natural_, uint8_t, _to_mono), + concat(conv_natural_, uint16_t, _to_mono), + concat(conv_natural_, uint32_t, _to_mono), }, { - conv_natural_uint8_t_to_mono, - conv_swap_uint16_t_to_mono, - conv_swap_uint32_t_to_mono, + concat(conv_natural_, uint8_t, _to_mono), + concat(conv_swap_, uint16_t, _to_mono), + concat(conv_swap_, uint32_t, _to_mono), } }, { { - conv_natural_int8_t_to_mono, - conv_natural_int16_t_to_mono, - conv_natural_int32_t_to_mono + concat(conv_natural_, int8_t, _to_mono), + concat(conv_natural_, int16_t, _to_mono), + concat(conv_natural_, int32_t, _to_mono) }, { - conv_natural_int8_t_to_mono, - conv_swap_int16_t_to_mono, - conv_swap_int32_t_to_mono + concat(conv_natural_, int8_t, _to_mono), + concat(conv_swap_, int16_t, _to_mono), + concat(conv_swap_, int32_t, _to_mono) } } }, { { { - conv_natural_uint8_t_to_stereo, - conv_natural_uint16_t_to_stereo, - conv_natural_uint32_t_to_stereo + concat(conv_natural_, uint8_t, _to_stereo), + concat(conv_natural_, uint16_t, _to_stereo), + concat(conv_natural_, uint32_t, _to_stereo) }, { - conv_natural_uint8_t_to_stereo, - conv_swap_uint16_t_to_stereo, - conv_swap_uint32_t_to_stereo + concat(conv_natural_, uint8_t, _to_stereo), + concat(conv_swap_, uint16_t, _to_stereo), + concat(conv_swap_, uint32_t, _to_stereo) } }, { { - conv_natural_int8_t_to_stereo, - conv_natural_int16_t_to_stereo, - conv_natural_int32_t_to_stereo + concat(conv_natural_, int8_t, _to_stereo), + concat(conv_natural_, int16_t, _to_stereo), + concat(conv_natural_, int32_t, _to_stereo) }, { - conv_natural_int8_t_to_stereo, - conv_swap_int16_t_to_stereo, - conv_swap_int32_t_to_stereo, + concat(conv_natural_, int8_t, _to_stereo), + concat(conv_swap_, int16_t, _to_stereo), + concat(conv_swap_, int32_t, _to_stereo), } } } @@ -202,52 +205,52 @@ f_sample *mixeng_clip[2][2][2][3] = { { { { - clip_natural_uint8_t_from_mono, - clip_natural_uint16_t_from_mono, - clip_natural_uint32_t_from_mono + concat(clip_natural_, uint8_t, _from_mono), + concat(clip_natural_, uint16_t, _from_mono), + concat(clip_natural_, uint32_t, _from_mono) }, { - clip_natural_uint8_t_from_mono, - clip_swap_uint16_t_from_mono, - clip_swap_uint32_t_from_mono + concat(clip_natural_, uint8_t, _from_mono), + concat(clip_swap_, uint16_t, _from_mono), + concat(clip_swap_, uint32_t, _from_mono) } }, { { - clip_natural_int8_t_from_mono, - clip_natural_int16_t_from_mono, - clip_natural_int32_t_from_mono + concat(clip_natural_, int8_t, _from_mono), + concat(clip_natural_, int16_t, _from_mono), + concat(clip_natural_, int32_t, _from_mono) }, { - clip_natural_int8_t_from_mono, - clip_swap_int16_t_from_mono, - clip_swap_int32_t_from_mono + concat(clip_natural_, int8_t, _from_mono), + concat(clip_swap_, int16_t, _from_mono), + concat(clip_swap_, int32_t, _from_mono) } } }, { { { - clip_natural_uint8_t_from_stereo, - clip_natural_uint16_t_from_stereo, - clip_natural_uint32_t_from_stereo + concat(clip_natural_, uint8_t, _from_stereo), + concat(clip_natural_, uint16_t, _from_stereo), + concat(clip_natural_, uint32_t, _from_stereo) }, { - clip_natural_uint8_t_from_stereo, - clip_swap_uint16_t_from_stereo, - clip_swap_uint32_t_from_stereo + concat(clip_natural_, uint8_t, _from_stereo), + concat(clip_swap_, uint16_t, _from_stereo), + concat(clip_swap_, uint32_t, _from_stereo) } }, { { - clip_natural_int8_t_from_stereo, - clip_natural_int16_t_from_stereo, - clip_natural_int32_t_from_stereo + concat(clip_natural_, int8_t, _from_stereo), + concat(clip_natural_, int16_t, _from_stereo), + concat(clip_natural_, int32_t, _from_stereo) }, { - clip_natural_int8_t_from_stereo, - clip_swap_int16_t_from_stereo, - clip_swap_int32_t_from_stereo + concat(clip_natural_, int8_t, _from_stereo), + concat(clip_swap_, int16_t, _from_stereo), + concat(clip_swap_, int32_t, _from_stereo) } } }