head 1.3; access; symbols pkgsrc-2017Q3:1.2.0.110 pkgsrc-2017Q3-base:1.2 pkgsrc-2017Q2:1.2.0.106 pkgsrc-2017Q2-base:1.2 pkgsrc-2017Q1:1.2.0.104 pkgsrc-2017Q1-base:1.2 pkgsrc-2016Q4:1.2.0.102 pkgsrc-2016Q4-base:1.2 pkgsrc-2016Q3:1.2.0.100 pkgsrc-2016Q3-base:1.2 pkgsrc-2016Q2:1.2.0.98 pkgsrc-2016Q2-base:1.2 pkgsrc-2016Q1:1.2.0.96 pkgsrc-2016Q1-base:1.2 pkgsrc-2015Q4:1.2.0.94 pkgsrc-2015Q4-base:1.2 pkgsrc-2015Q3:1.2.0.92 pkgsrc-2015Q3-base:1.2 pkgsrc-2015Q2:1.2.0.90 pkgsrc-2015Q2-base:1.2 pkgsrc-2015Q1:1.2.0.88 pkgsrc-2015Q1-base:1.2 pkgsrc-2014Q4:1.2.0.86 pkgsrc-2014Q4-base:1.2 pkgsrc-2014Q3:1.2.0.84 pkgsrc-2014Q3-base:1.2 pkgsrc-2014Q2:1.2.0.82 pkgsrc-2014Q2-base:1.2 pkgsrc-2014Q1:1.2.0.80 pkgsrc-2014Q1-base:1.2 pkgsrc-2013Q4:1.2.0.78 pkgsrc-2013Q4-base:1.2 pkgsrc-2013Q3:1.2.0.76 pkgsrc-2013Q3-base:1.2 pkgsrc-2013Q2:1.2.0.74 pkgsrc-2013Q2-base:1.2 pkgsrc-2013Q1:1.2.0.72 pkgsrc-2013Q1-base:1.2 pkgsrc-2012Q4:1.2.0.70 pkgsrc-2012Q4-base:1.2 pkgsrc-2012Q3:1.2.0.68 pkgsrc-2012Q3-base:1.2 pkgsrc-2012Q2:1.2.0.66 pkgsrc-2012Q2-base:1.2 pkgsrc-2012Q1:1.2.0.64 pkgsrc-2012Q1-base:1.2 pkgsrc-2011Q4:1.2.0.62 pkgsrc-2011Q4-base:1.2 pkgsrc-2011Q3:1.2.0.60 pkgsrc-2011Q3-base:1.2 pkgsrc-2011Q2:1.2.0.58 pkgsrc-2011Q2-base:1.2 pkgsrc-2011Q1:1.2.0.56 pkgsrc-2011Q1-base:1.2 pkgsrc-2010Q4:1.2.0.54 pkgsrc-2010Q4-base:1.2 pkgsrc-2010Q3:1.2.0.52 pkgsrc-2010Q3-base:1.2 pkgsrc-2010Q2:1.2.0.50 pkgsrc-2010Q2-base:1.2 pkgsrc-2010Q1:1.2.0.48 pkgsrc-2010Q1-base:1.2 pkgsrc-2009Q4:1.2.0.46 pkgsrc-2009Q4-base:1.2 pkgsrc-2009Q3:1.2.0.44 pkgsrc-2009Q3-base:1.2 pkgsrc-2009Q2:1.2.0.42 pkgsrc-2009Q2-base:1.2 pkgsrc-2009Q1:1.2.0.40 pkgsrc-2009Q1-base:1.2 pkgsrc-2008Q4:1.2.0.38 pkgsrc-2008Q4-base:1.2 pkgsrc-2008Q3:1.2.0.36 pkgsrc-2008Q3-base:1.2 cube-native-xorg:1.2.0.34 cube-native-xorg-base:1.2 pkgsrc-2008Q2:1.2.0.32 pkgsrc-2008Q2-base:1.2 cwrapper:1.2.0.30 pkgsrc-2008Q1:1.2.0.28 pkgsrc-2008Q1-base:1.2 pkgsrc-2007Q4:1.2.0.26 pkgsrc-2007Q4-base:1.2 pkgsrc-2007Q3:1.2.0.24 pkgsrc-2007Q3-base:1.2 pkgsrc-2007Q2:1.2.0.22 pkgsrc-2007Q2-base:1.2 pkgsrc-2007Q1:1.2.0.20 pkgsrc-2007Q1-base:1.2 pkgsrc-2006Q4:1.2.0.18 pkgsrc-2006Q4-base:1.2 pkgsrc-2006Q3:1.2.0.16 pkgsrc-2006Q3-base:1.2 pkgsrc-2006Q2:1.2.0.14 pkgsrc-2006Q2-base:1.2 pkgsrc-2006Q1:1.2.0.12 pkgsrc-2006Q1-base:1.2 pkgsrc-2005Q4:1.2.0.10 pkgsrc-2005Q4-base:1.2 pkgsrc-2005Q3:1.2.0.8 pkgsrc-2005Q3-base:1.2 pkgsrc-2005Q2:1.2.0.6 pkgsrc-2005Q2-base:1.2 pkgsrc-2005Q1:1.2.0.4 pkgsrc-2005Q1-base:1.2 pkgsrc-2004Q4:1.2.0.2 pkgsrc-2004Q4-base:1.2 pkgsrc-2004Q3:1.1.0.2 pkgsrc-2004Q3-base:1.1; locks; strict; comment @# @; 1.3 date 2017.09.26.10.27.10; author wiz; state dead; branches; next 1.2; commitid 9ARpkXTuh9Wg2H8A; 1.2 date 2004.11.13.18.33.44; author tron; state Exp; branches; next 1.1; 1.1 date 2004.07.21.21.49.02; author scw; state Exp; branches; next ; desc @@ 1.3 log @*: remove qt3 and the packages using it, including KDE3 Announced in https://mail-index.netbsd.org/pkgsrc-users/2017/09/10/msg025556.html @ text @$NetBSD: patch-ah,v 1.2 2004/11/13 18:33:44 tron Exp $ --- kphone/dspoutoss.cpp.orig 2004-10-18 09:57:56.000000000 +0200 +++ kphone/dspoutoss.cpp 2004-11-13 19:15:54.000000000 +0100 @@@@ -8,6 +8,10 @@@@ #include #include +#ifdef __NetBSD__ +#include +#endif + #include "dspoutoss.h" DspOutOss::DspOutOss( const QString &fileName ) @@@@ -53,6 +57,7 @@@@ flags &= ~O_NONBLOCK; fcntl( audio_fd, F_SETFL, flags ); +#ifndef __NetBSD__ // keep fragsize less than 20ms !! int frag = ( ( 32767 << 16 ) | 7 ); if( ioctl( audio_fd, SNDCTL_DSP_SETFRAGMENT, &frag ) ) { @@@@ -60,6 +65,7 @@@@ printf( "ERROR: %s\n", lasterror.ascii() ); return false; } +#endif int format = AFMT_S16_LE; @@@@ -109,6 +115,23 @@@@ 8000, rate, 100*((rate-8000)/8000.0) ); } +#ifdef __NetBSD__ + int duplex = 1; + + if( ioctl( audio_fd, AUDIO_SETFD, &duplex ) == -1 ) { + lasterror = QString( "SETFD" ) + QString( strerror( errno ) ); + printf( "ERROR: %s\n", lasterror.ascii() ); + return false; + } + + // keep fragsize less than 20ms !! + int frag = ( ( 32767 << 16 ) | 7 ); + if( ioctl( audio_fd, SNDCTL_DSP_SETFRAGMENT, &frag ) ) { + lasterror = QString( "SETFRAG" ) + QString( strerror( errno ) ); + printf( "ERROR: %s\n", lasterror.ascii() ); + return false; + } +#endif audio_buf_info info; @@@@ -127,6 +150,14 @@@@ } audio_buf.resize( info.fragsize * sizeof( short ) ); +#ifdef __NetBSD__ + if( ioctl( audio_fd, AUDIO_FLUSH, 0 ) == -1 ) { + lasterror = QString( "FLUSH" ) + QString( strerror( errno ) ); + printf( "ERROR: %s\n", lasterror.ascii() ); + return false; + } +#endif + lasterror = QString::null; devstate = DeviceOpened; return true; @@@@ -150,6 +181,14 @@@@ } audio_buf.resize( info.fragsize * sizeof( short ) ); +#ifdef __NetBSD__ + if( ioctl( audio_fd, AUDIO_FLUSH, 0 ) == -1 ) { + lasterror = QString( "FLUSH" ) + QString( strerror( errno ) ); + printf( "ERROR: %s\n", lasterror.ascii() ); + return false; + } +#endif + lasterror = QString::null; devstate = DeviceOpened; return true; @@@@ -216,6 +255,7 @@@@ unsigned int DspOutOss::readableBytes( void ) { +#ifndef __NetBSD__ audio_buf_info info; struct timeval timeout; fd_set read_fds; @@@@ -239,6 +279,18 @@@@ } return info.bytes; + +#else /* !__NetBSD__ */ + + /* XXXSCW: This sucks, but kphone refuses to work without it */ + int rsize; + + if( ioctl( audio_fd, FIONREAD, &rsize) < 0 ) + return 0; + if (rsize == 0) + rsize = 256; + return rsize; +#endif /* __NetBSD__ */ } @ 1.2 log @Update "kphone" package to version 4.0.5. Changes since version 4.0.3: - Fixed bug in localization - Memory leak fixed - Localization added, thanks to Mario Scheel - Tray icon support added, thanks to Thomas Zell - Some errors fixed @ text @d1 1 a1 1 $NetBSD$ @ 1.1 log @Initial import of KPhone 4.0.3, a SIP (Session Initiation Protocol) user agent for *nix. (Basically, a VoIP client) There are some rough edges in the NetBSD audio support of this package, but it runs well enough on my esa(4)-equipped laptop to make and receive FWD calls. A couple of minor patches are courtesy of the FreeBSD port of Kphone. Alistair Crooks also tidied up my first amateurish attempt at packaging this. @ text @d3 3 a5 5 --- kphone/dspoutoss.cpp.orig 2004-03-29 15:59:45.000000000 +0100 +++ kphone/dspoutoss.cpp 2004-07-21 12:35:56.000000000 +0100 @@@@ -6,6 +6,9 @@@@ #include #include d7 2 d12 1 a12 1 d15 2 a16 1 @@@@ -52,6 +55,7 @@@@ d24 1 a24 1 @@@@ -59,6 +63,7 @@@@ d32 1 a32 1 @@@@ -108,6 +113,23 @@@@ d56 1 a56 1 @@@@ -126,6 +148,14 @@@@ d71 1 a71 1 @@@@ -149,6 +179,14 @@@@ d86 1 a86 1 @@@@ -215,6 +253,7 @@@@ d94 1 a94 1 @@@@ -238,6 +277,18 @@@@ @