From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-Status: No, score=-4.3 required=3.0 tests=AWL,BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, RCVD_IN_DNSWL_LOW,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,SPF_PASS, URIBL_BLOCKED shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from lists.sourceforge.net (lists.sourceforge.net [216.105.38.7]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dcvr.yhbt.net (Postfix) with ESMTPS id BBE521F66E for ; Thu, 27 Aug 2020 12:45:36 +0000 (UTC) Received: from [127.0.0.1] (helo=sfs-ml-2.v29.lw.sourceforge.com) by sfs-ml-2.v29.lw.sourceforge.com with esmtp (Exim 4.90_1) (envelope-from ) id 1kBHHa-0005SM-9O; Thu, 27 Aug 2020 12:45:34 +0000 Received: from [172.30.20.202] (helo=mx.sourceforge.net) by sfs-ml-2.v29.lw.sourceforge.com with esmtps (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kBHHY-0005S4-LX for sox-devel@lists.sourceforge.net; Thu, 27 Aug 2020 12:45:32 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sourceforge.net; s=x; h=Content-Transfer-Encoding:Content-Type:MIME-Version :Message-ID:In-Reply-To:Date:References:Subject:Cc:To:From:Sender:Reply-To: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=gxEh2XUD8HoJDDPOawqMni6W3tijPdn2o6iSlSmtz0w=; b=kkXpMAIwQpR82vfGmPkAxYrMpt qop4FNKK7dgGN4K6FTMusgC1nr+PqkFL+qEQihxZ+wxNa1g2z4G7eEDme6zshFwk/fUMAhKdQmtoj l9mQTu52CJl/gT4WJrPsCHmtrN0ALZA6mEfdJ4nkzg8wp2PHp8XM7+wg2iX4hKwI3BR0=; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sf.net; s=x ; h=Content-Transfer-Encoding:Content-Type:MIME-Version:Message-ID: In-Reply-To:Date:References:Subject:Cc:To:From:Sender:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=gxEh2XUD8HoJDDPOawqMni6W3tijPdn2o6iSlSmtz0w=; b=mskrTXNHyDNk6PPyck/SAzfv3U cwMPRbAqMgJC/+75wwLc8W34oPHFPKd7t4d86Xo+O5MkrOeVzPdH/IAXz/t7EP4PMkJXQw80Eb840 iqO7hKyNel4JjQIXUlqQI0/3dMawz/UjnhXDS4MPe94UVVuNOvebPbViO/LZA7izoca0=; Received: from [81.2.72.234] (helo=unicorn.mansr.com) by sfi-mx-1.v28.lw.sourceforge.com with esmtps (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.92.2) id 1kBHHW-002IYG-H5 for sox-devel@lists.sourceforge.net; Thu, 27 Aug 2020 12:45:32 +0000 Received: from raven.mansr.com (raven.mansr.com [81.2.72.235]) by unicorn.mansr.com (Postfix) with ESMTPS id 28DF815360; Thu, 27 Aug 2020 13:45:14 +0100 (BST) Received: by raven.mansr.com (Postfix, from userid 51770) id C69FD21A6F2; Thu, 27 Aug 2020 13:45:12 +0100 (BST) From: =?iso-8859-1?Q?M=E5ns_Rullg=E5rd?= To: Jan Stary References: <20200827092158.GA5768@www.stare.cz> <20200827124014.GA20713@www.stare.cz> Date: Thu, 27 Aug 2020 13:45:12 +0100 In-Reply-To: <20200827124014.GA20713@www.stare.cz> (Jan Stary's message of "Thu, 27 Aug 2020 14:40:14 +0200") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux) MIME-Version: 1.0 X-Headers-End: 1kBHHW-002IYG-H5 Subject: Re: Build system cleanup X-BeenThere: sox-devel@lists.sourceforge.net X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: sox-devel@lists.sourceforge.net Cc: sox-devel@lists.sourceforge.net Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Errors-To: sox-devel-bounces@lists.sourceforge.net Jan Stary writes: >> > checking for strdup... yes >> > >> > Not specific to NetBSD of course, but why are we running these >> > tests (taking strdup as a random example)? Is there a POSIX >> > system without strdup? And if we miss strdup, then what? >> > With that configure.ac line changed to check for xstrdup instead, >> > this will just become >> > >> > checking for xstrdup... no >> > >> > but everyting follows as before. Which means we have checked for >> > a function (via AC_CHECK_FUNCS), found out it does not exist, >> > and ignored the result. What is that for? >> = >> I already explained this about five times. > > The only explanation I have seen so far is > "it was warranted in the olden days". Perhaps it was; > but why are we checking for e.g. strdup() in 2020 > (and ingoring the result of AC_CHECK_FUNCS anyway)? It's there because I haven't got around to removing it yet. It's harmless for now. >> > checking for sys/soundcard.h... yes >> > >> > On NetBSD, sys/soundcard.h says >> > >> > This is an OSS (Linux) audio emulator. >> > Use the Native NetBSD API for developing new code, >> > and this only for compiling Linux programs. >> > >> > The check is >> > >> > SOX_FMT_HEADERS([oss], [sys/soundcard.h], [SOUND_MIXER_MUTE], >> > [], [devices]) >> > >> > so at least we correctly recognize this as OSS emulation. >> > But the check does not work universaly: NetBSD has >> > /usr/include/sys/soundcard.h -> ../soundcard.h, but e.g. >> > OpenBSD only has /usr/include/soundcard.h (same code though). >> > Apparently, the name makes a difference: >> > a test for "sys/soundcard.h" will fail on OpenBSD. >> > >> > checking whether SOUND_MIXER_MUTE is declared... no >> > >> > Why SOUND_MIXER_MUTE, specificaly, out of all the others? >> > For example, SOUND_MIXER_INFO is declared, which would >> > make the oss emulation detected (not saying this is >> > the correct test). >> > >> > Lastly, oss requires a library to be linked: >> > https://netbsd.gw.com/cgi-bin/man-cgi?ossaudio >> > That would be /usr/lib/libossaudio.so - I believe a recent >> > commit has concluded that oss does not require any library >> > (being a bunch of defined ioctls); on NetBSD, it maybe does. >> > >> > $ nm /usr/lib/libossaudio.so | grep oss >> > 0000000000001f60 T _oss_ioctl >> = >> Real OSS does _not_ need a library. That is _only_ used for the >> incomplete emulation that we don't want. The test is chosen such that >> it passes on Linux, FreeBSD, and Solaris while failing on NetBSD and >> OpenBSD. > > In case it is intended to detect OSS as not present > on OpenBSD and NetBSD (who only emulate OSS), > it seems to work as intended. That was the intention. >> > checking for sys/audioio.h... yes >> > >> > This seems to be NetBSD's native audio interface. >> > https://netbsd.gw.com/cgi-bin/man-cgi?audio >> > It's what the NetBSD port of SoX uses: >> > http://ftp.netbsd.org/pub/pkgsrc/current/pkgsrc/audio/sox/ >> > >> > checking whether AUDIO_HWFEATURE_DUPLEX is declared... no >> > >> > ... but we miss that, because of this. >> > It seems NetBSD's audio system came from Sun audio >> > (/usr/pkg/bin/sox reports AUDIO DEVICE DRIVERS: sunau), >> > but it's not quite the same; in particular, >> > AUDIO_HWFEATURE_DUPLEX is not defined. >> = >> Already fixed. > > The detectin works, thanks: > > Audio devices: > alsa no > ao no > coreaudio no > oss no > pulseaudio no > sndio no > sunaudio yes > waveaudio no > > It doesn't actually play though: > > $ play -V -n -b 16 synth 1 > play INFO sunaudio: Sun Audio driver only supports bytes and words > play: SoX v14.4.2 > play INFO nulfile: sample rate not specified; using 48000 > > Input File : '' (null) > Channels : 1 > Sample Rate : 48000 > Precision : 32-bit > > Output File : 'default' (sunau) > Channels : 1 > Sample Rate : 48000 > Precision : 16-bit > Sample Encoding: 16-bit Signed Integer PCM > Endian Type : little > Reverse Nibbles: no > Reverse Bits : no > > play INFO sox: effects chain: input 48000Hz 1 channels > play INFO sox: effects chain: synth 48000Hz 1 channels > play INFO sox: effects chain: dither 48000Hz 1 channels > play INFO sox: effects chain: output 48000Hz 1 channels > In:0.00% 00:00:00.00 [00:00:00.00] Out:0 [ | ] Clip:0 M= emory fault (core dumped) Already fixed. -- = M=E5ns Rullg=E5rd _______________________________________________ SoX-devel mailing list SoX-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/sox-devel