liboss-commit Mailing List for Apple OS X libOSS
Brought to you by:
thesin
You can subscribe to this list here.
2002 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(55) |
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
(57) |
Nov
(52) |
Dec
(2) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2003 |
Jan
(16) |
Feb
(9) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Alexander S. <mrv...@us...> - 2003-02-22 19:55:11
|
Update of /cvsroot/liboss/liboss/src In directory sc8-pr-cvs1:/tmp/cvs-serv31838 Modified Files: osscat.c Log Message: Adding a missing close() Index: osscat.c =================================================================== RCS file: /cvsroot/liboss/liboss/src/osscat.c,v retrieving revision 1.14 retrieving revision 1.15 diff -u -r1.14 -r1.15 --- osscat.c 22 Feb 2003 03:02:38 -0000 1.14 +++ osscat.c 22 Feb 2003 19:55:04 -0000 1.15 @@ -92,5 +92,6 @@ return 1; } + close(play); return 0; } |
From: Alexander S. <mrv...@us...> - 2003-02-22 19:50:25
|
Update of /cvsroot/liboss/liboss/lib In directory sc8-pr-cvs1:/tmp/cvs-serv30218/lib Modified Files: esddsp.c Log Message: Fixing cpp-precomp lameness Index: esddsp.c =================================================================== RCS file: /cvsroot/liboss/liboss/lib/esddsp.c,v retrieving revision 1.24 retrieving revision 1.25 diff -u -r1.24 -r1.25 --- esddsp.c 19 Jan 2003 19:47:14 -0000 1.24 +++ esddsp.c 22 Feb 2003 19:50:21 -0000 1.25 @@ -22,9 +22,9 @@ #endif #ifdef DSP_DEBUG -#define DPRINTF(format, args...) printf(format, ## args) +#define DPRINTF printf #else -#define DPRINTF(format, args...) +static inline void DPRINTF(char *format, ...) {return;} #endif #include "config.h" |
From: Alexander S. <mrv...@us...> - 2003-02-22 19:42:38
|
Update of /cvsroot/liboss/liboss In directory sc8-pr-cvs1:/tmp/cvs-serv27679 Modified Files: autogen.sh liboss.info.in Log Message: Better version of autogen.sh Index: autogen.sh =================================================================== RCS file: /cvsroot/liboss/liboss/autogen.sh,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- autogen.sh 5 Nov 2002 16:23:11 -0000 1.4 +++ autogen.sh 22 Feb 2003 19:42:33 -0000 1.5 @@ -1,7 +1,7 @@ #!/bin/sh # Run this to generate all the initial makefiles, etc. # This was lifted from the Gimp, and adapted slightly by -# Raph Levien, slightly hacked for xine by Daniel Caujolle-Bert. +# Raph Levien, slightly hacked for xine by Daniel Caujolle-Bert, and modified more for OS X by Jeremy Parsons and Alexander Strange. DIE=0 @@ -22,7 +22,7 @@ DIE=1 } -(libtoolize --version) < /dev/null > /dev/null 2>&1 || { +(glibtoolize --version) < /dev/null > /dev/null 2>&1 || (libtoolize --version) < /dev/null > /dev/null 2>&1 || { echo echo "You must have libtool installed to compile $PROG." echo "Get ftp://ftp.gnu.org/pub/gnu/libtool-1.4.tar.gz" @@ -56,7 +56,7 @@ aclocal $aclocalinclude; \ echo "done.") && \ (echo $_echo_n " + Running libtoolize: $_echo_c"; \ - libtoolize --force --copy >/dev/null 2>&1; \ + libtoolize --force --copy >/dev/null 2>&1 || glibtoolize --force --copy >/dev/null 2>&1; \ echo "done.") && \ (echo $_echo_n " + Running autoheader: $_echo_c"; \ autoheader; \ Index: liboss.info.in =================================================================== RCS file: /cvsroot/liboss/liboss/liboss.info.in,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- liboss.info.in 22 Feb 2003 04:32:39 -0000 1.5 +++ liboss.info.in 22 Feb 2003 19:42:33 -0000 1.6 @@ -10,7 +10,7 @@ Package: %N-shlibs Files: lib/%N.*.dylib Depends: esound-shlibs -<< + << DocFiles: AUTHORS COPYING ChangeLog INSTALL NEWS README TODO Description: OSS Audio API Emulation Library DescDetail: << |
From: Alexander S. <mrv...@us...> - 2003-02-22 05:34:57
|
Update of /cvsroot/liboss/liboss In directory sc8-pr-cvs1:/tmp/cvs-serv26242 Modified Files: ChangeLog Log Message: Reran cvs2cl Index: ChangeLog =================================================================== RCS file: /cvsroot/liboss/liboss/ChangeLog,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- ChangeLog 23 Oct 2002 01:34:19 -0000 1.4 +++ ChangeLog 22 Feb 2003 05:34:54 -0000 1.5 @@ -1,328 +1,626 @@ -2002-10-22 21:28 mrvacbob +2003-02-21 20:32 mrvacbob + + * liboss.info.in: Fixing dependencies in .info + +2003-02-21 19:06 mrvacbob + + * configure.in: Disabling -mmultiple and -mstring in case someone + tries to run it on LinuxPPC on a 601 :) + +2003-02-21 19:02 mrvacbob + + * configure.in, include/liboss/soundcard.h, src/Makefile.am, + src/osscat.c: Builds on FreeBSD 4.7 + +2003-01-19 11:47 mrvacbob + + * configure.in, include/liboss/soundcard.h, lib/esddsp.c: liboss + doesn't crash anymore. successfully ran osscat. removed + machine/byte_order.h because it was unnecessary. + +2003-01-18 13:21 mrvacbob + + * configure.in: Configure script works again. + +2003-01-12 14:40 mrvacbob + + * configure.in: OK, I have no clue why this doesn't work. + +2003-01-12 08:57 mrvacbob + + * acinclude.m4, configure.in, lib/Makefile.am: Almost got this all + cross-platformy, but I'm getting sh parse errors and I have no idea + why. + +2003-01-12 08:11 mrvacbob + + * configure.in: Fixing autoupdate lameness + +2003-01-12 08:07 mrvacbob + + * Makefile.am, configure.in: Added better CFLAGS checking. + -frename-registers fails erroneusly due to compiler bugs + +2003-01-11 15:55 mrvacbob + + * configure.in, lib/Makefile.am, lib/esddsp.c: It now compiles. + Also, I made it so it should dlopen() libc.so on non-Darwin + platforms, so this should, theorectically, be cross-platform. + Someone go try it. + +2003-01-11 11:33 mrvacbob + + * include/liboss/soundcard.h, lib/Makefile.am, lib/ossins.c: Added + libossins back in. We need to make maintainer-clean not delete + acinclude.m4 + +2003-01-06 13:52 mrvacbob + + * configure.in, lib/Makefile.am, lib/esddsp.c, src/Makefile.am: + Moved esddsp over to syscall() if possible. This should allow us to + write an 'esddsp' program equivalent that works. Also disabled + endian-swapping in liboss_write(), and moved CFLAGS over to + AM_CFLAGS, because automake told me to. + ------------------------------------------------------------------- + --- + +2002-12-11 17:19 mrvacbob + + * configure.in, liboss.kdevprj, liboss.kdevses, lib/esddsp.c: + Reverting dsp_init() back because the 'new method' was a no-op, and + fixed up configure.in based on advice from 'autoscan' + +2002-11-14 14:38 thesin + + * lib/esddsp.c: This gets me further in xmms thanks max, now to + figure out a better implementation of OSpace and Fragment + +2002-11-07 15:09 thesin + + * lib/esddsp.c: forgot the CR, that should help now hehe + +2002-11-07 08:21 thesin + + * lib/esddsp.c: added some printouts to see what arts is doing + +2002-11-07 08:05 thesin + + * lib/esddsp.c: ESD doesn't care about frags lets see if I can use + it to reset the buffers + +2002-11-06 21:36 thesin + + * lib/esddsp.c: might work, will have to try arts tomorrow I think + that is all the handles it needs + +2002-11-06 20:40 thesin + + * lib/esddsp.c: one more, hope your ready Rangerrick hehe, but it's + gonna be the hardess by far + +2002-11-06 20:13 thesin + + * include/liboss/Makefile.am, lib/esddsp.c: One down, two to go + +2002-11-06 18:46 thesin + + * include/liboss/soundcard_oss.h, lib/liboss.c: old files no longer + needed + +2002-11-06 15:50 thesin + + * lib/esddsp.c: clean up out left over va_end calls, since they are + done in the header now + +2002-11-06 15:34 fingolfin + + * lib/esddsp.c: use the same indention rule everywhere; added two + FIXME's, for the people working on this to review :-) + +2002-11-06 13:03 thesin + + * include/liboss/soundcard.h, src/osscat.c: I rock, works 100% with + mpg123 now + +2002-11-06 12:44 thesin + + * lib/esddsp.c: this creates bus errors for now + +2002-11-06 12:14 thesin + + * lib/esddsp.c, src/osscat.c: Works much much better, gonna see if + I can get mpg123 to work now + +2002-11-06 11:10 rangerrick + + * configure.in, include/Makefile.am, include/audioio.h, + include/soundcard.h, include/soundcard_oss.h, + include/liboss/.cvsignore, include/liboss/Makefile.am, + include/liboss/audioio.h, include/liboss/soundcard.h, + include/liboss/soundcard_oss.h, lib/esddsp.c, src/osscat.c: moved + the includes around a bit + +2002-11-06 10:51 thesin + + * include/soundcard.h, lib/esddsp.c, src/osscat.c: need to make a + liboss_write for write calls, this is just the first version since + i need to move some files I'll do that then finish this + +2002-11-06 10:14 rangerrick + + * configure.in, lib/Makefile.am: ordering fixes + +2002-11-06 09:50 thesin + + * include/soundcard.h: Oops + +2002-11-06 09:42 thesin + + * include/soundcard.h: added calls to va_end for future hehe + +2002-11-06 09:36 rangerrick + + * include/soundcard.h: let you override the function names that get + inlined + +2002-11-05 20:34 thesin + + * Makefile.am: Don't ask + +2002-11-05 20:32 thesin + + * Makefile.am, include/soundcard_oss.h, lib/liboss.c, + lib/ossaudio.c: adding netbsd files for reference for now, BTW it + will compile it, but the is no hijack code, might be useful though + +2002-11-05 19:14 thesin + + * include/Makefile.am, include/audioio.h, include/soundcard.h, + lib/esddsp.c: osscat works as it should hopefully others will + follow, added audioio.h to control audioio structs and defs + +2002-11-05 16:00 thesin + + * TODO, include/soundcard.h, lib/esddsp.c: was a little noisy, thus + removed some print outs, and added to the TODO list, I think it's + just that stuff that is missing. lots of it is done in liboss.c + prolly why i got it to work once I'll continue going through this + stuff when I get home tonight + +2002-11-05 14:07 thesin + + * src/osscat.c: okay it needs to be set to mono + +2002-11-05 13:50 thesin + + * src/osscat.c: osscat hard codes sample speed, I just doubled it + to play kde wavs at right speed + +2002-11-05 13:34 thesin + + * include/soundcard.h, lib/Makefile.am, lib/liboss.c: osscat works + perfectly, still working on mpg123, just static + +2002-11-05 11:48 thesin + + * lib/: Makefile.am, libossins.c: libossins doesn't work removing + +2002-11-05 11:46 thesin + + * include/soundcard.h: some additions and some little fixes + +2002-11-05 09:35 thesin + + * configure.in: I few more clean ups, compiles and osscat makes + sound + +2002-11-05 09:16 thesin + + * lib/liboss.c: Compiles now + +2002-11-05 08:43 thesin + + * include/soundcard.h: need to have same type as in acctualy + definitions, getting a little further + +2002-11-05 08:41 thesin + + * configure.in: fix for blank --with-esd + +2002-11-05 08:23 thesin + + * autogen.sh, liboss.info.in, lib/Makefile.am, lib/libossins.c, + lib/ossinsert.c: little clean up, no need for CFLAGS in lib since + CPPFLAGS is identical for now, will fix as I'm able to build and + for now I can't get past esddsp.c + +2002-10-30 17:15 mrvacbob + + * include/soundcard.h: Defines the stuff if LIBOSS_INTERNAL is set + now + +2002-10-30 15:08 mrvacbob + + * lib/Makefile.am: Doh! ossinsert works now + +2002-10-30 14:42 mrvacbob + + * liboss.kdevprj, liboss.kdevses: KDevelop actually seems to suck + on Darwin + +2002-10-30 14:27 mrvacbob + + * liboss.kdevprj, liboss.kdevses: KDevelop rocks! + +2002-10-27 21:30 rangerrick + + * Makefile.am, liboss.info.in: doc fix + +2002-10-27 15:01 mrvacbob + + * lib/esddsp.c: Enabling /dev/mixer emulation + +2002-10-27 14:47 mrvacbob + + * configure.in, lib/Makefile.am, lib/ossinsert.c: ossinsert now + builds, also optimizing the hell out of it, because I do stuff like + that. + +2002-10-24 15:11 mrvacbob + + * lib/ossinsert.c: This will eventually become a way to let liboss + act like the esddsp and artsdsp wrapper programs + +2002-10-23 06:59 rangerrick + + * Makefile.am, configure.in, liboss.info.in: more cruft removal + + damn, it's ugly, BUT -- autotools, is there anything they CAN'T do? + Oh yeah, be readable. But other than that they're pretty cool. + +2002-10-22 20:04 rangerrick + + * .cvsignore, Makefile.am, configure.in, liboss.info.in: added an + info file + +2002-10-22 19:39 rangerrick + + * .cvsignore, Makefile.am, configure.in, liboss.pc.in: added a + pkg-config file for liboss + +2002-10-22 19:05 mrvacbob + + * include/soundcard.h: Now works with C++ + +2002-10-22 18:34 mrvacbob + + * ChangeLog: Updating this + +2002-10-22 18:28 mrvacbob * TODO, configure.in, include/soundcard.h, lib/esddsp.c, src/Makefile.am: Now soundcard.h uses inline functions. We need to write liboss-config or use pkgconfig, but arts may compile (manually) now -2002-10-22 16:13 rangerrick +2002-10-22 13:13 rangerrick * AUTHORS, INSTALL, README: doco updates -2002-10-22 15:51 thesin +2002-10-22 12:51 thesin * ChangeLog: ran cvs2cl to get a better changelog, it needs editing and everyone should start using it now -2002-10-22 15:46 rangerrick +2002-10-22 12:46 rangerrick * TODO, configure.in, lib/Makefile.am: more cruft removal and cleanup -2002-10-22 15:28 thesin +2002-10-22 12:28 thesin * src/osscat.c: don't ask why I put .. -2002-10-22 15:27 thesin +2002-10-22 12:27 thesin * lib/esddsp.c, src/osscat.c: There will never be any other soundcard.h -2002-10-22 13:19 rangerrick +2002-10-22 10:19 rangerrick * acconfig.h, configure.in: if we use the 3-argument version of AC_DEFINE, we don't need acconfig.h anymore, and autogen doesn't bitch ;) -2002-10-22 12:51 rangerrick +2002-10-22 09:51 rangerrick * configure.in, lib/Makefile.am: LIBESD resembles LIBDL -2002-10-22 01:24 rangerrick +2002-10-21 22:24 rangerrick * include/Makefile.am: liboss/soundcard.h -2002-10-22 01:21 rangerrick +2002-10-21 22:21 rangerrick * configure.in, lib/.cvsignore, lib/Makefile.am, src/.cvsignore: more build tweaks -2002-10-22 00:48 rangerrick +2002-10-21 21:48 rangerrick * configure.in: rearranged the macros so that it will detect esd even if it's not in -I and -L -2002-10-22 00:47 rangerrick +2002-10-21 21:47 rangerrick * autogen.sh: --prefix=`pwd`?? why??? -2002-10-22 00:47 rangerrick +2002-10-21 21:47 rangerrick * .cvsignore: more things to ignore -2002-10-21 19:18 thesin +2002-10-21 16:18 thesin * configure.in: added a test for esd.h -2002-10-21 18:40 fingolfin +2002-10-21 15:40 fingolfin * config.guess, config.sub, depcomp, install-sh, ltmain.sh, missing, mkinstalldirs: removed some files which are generated by autotools -2002-10-19 08:41 fingolfin +2002-10-19 05:41 fingolfin * .cvsignore, doc/.cvsignore, include/.cvsignore, lib/.cvsignore, src/.cvsignore: updated .cvsignore -2002-10-19 04:11 vasi +2002-10-19 01:11 vasi * src/osscat.c: Woohoo, it WORKS!!! Just 'osscat somewavfile.wav' should play a nice sound, assuming the wav file was made with right params. Most of the ones in /sw/share/sounds should work fine. -2002-10-19 03:02 vasi +2002-10-19 00:02 vasi * src/osscat.c: We have sound! Too bad it's meaningless static so far...time to look up exactly what a .WAV is... -2002-10-18 18:46 mrvacbob +2002-10-18 15:46 mrvacbob * AUTHORS, lib/esddsp.c, src/osscat.c: osscat almost works now. It calls write(), and esddsp doesn't override write(). We may need to implement this -2002-10-18 18:11 mrvacbob +2002-10-18 15:11 mrvacbob * lib/: Makefile.am, esddsp.c: Oops, this is kinda needed -2002-10-18 18:00 mrvacbob +2002-10-18 15:00 mrvacbob * configure.in, include/soundcard.h, lib/Makefile.am, src/Makefile.am, src/osscat.c: More changes. It now compiles. osscat crashes trying to call a symbol acquired from dlsym (open), but i don't think it's dlcompat's fault -2002-10-17 22:50 mrvacbob +2002-10-17 19:50 mrvacbob * configure.in, include/soundcard.h, lib/Makefile.am: Attempting an implementation using esddsp. Does not work. Does not even compile. I can't figure out what the error means, though. -2002-06-22 14:20 mrvacbob +2002-06-22 11:20 mrvacbob * configure.in, depcomp: Reworked some of the build system (yay for autoupdate/autoscan) -2002-05-10 11:57 fingolfin +2002-05-10 08:57 fingolfin * .cvsignore: updated .cvsignore -2002-05-10 11:48 thesin +2002-05-10 08:48 thesin * include/.cvsignore, src/.cvsignore: cvs sanity addition -2002-05-10 11:43 thesin +2002-05-10 08:43 thesin * autogen.sh: Changed autogen.sh to autorun configure using pwd ass the prefix for vasi, to stop this a variable called NO_CONFIGURE must not be equal to null -2002-05-10 11:25 thesin +2002-05-10 08:25 thesin * include/Makefile.am: Oops -2002-05-10 11:20 thesin +2002-05-10 08:20 thesin * Makefile.am: Almost forgot this one -2002-05-10 11:20 thesin +2002-05-10 08:20 thesin * configure.in, include/Makefile.am, lib/Makefile.am: Fix for install phase -2002-05-10 11:05 thesin +2002-05-10 08:05 thesin * configure.in, lib/libosscat.c, src/Makefile.am, src/osscat.c: Add a src dir and change bin program name to osscat, and now compiles and installs -2002-05-10 10:53 vasi +2002-05-10 07:53 vasi * lib/liboss.c: Added lots of stuff. Some sound may come soon! -2002-05-10 10:38 thesin +2002-05-10 07:38 thesin * Makefile.am: Adding a dir for binaries -2002-05-10 06:12 vasi +2002-05-10 03:12 vasi * lib/libosscat.c: Stupid errors fixed. -2002-05-10 06:10 vasi +2002-05-10 03:10 vasi * lib/libosscat.c: Test case. -2002-05-09 23:35 thesin +2002-05-09 20:35 thesin * acconfig.h, configure.in: Added the CoreAudio if statement -2002-05-09 23:32 thesin +2002-05-09 20:32 thesin * lib/liboss.c: Changed CoreAudio Define -2002-05-09 19:07 thesin +2002-05-09 16:07 thesin * configure.in: Added Coreaudio as an option for futur expansion, this is temp till I get home and add a test for coreaudio -2002-05-09 19:02 thesin +2002-05-09 16:02 thesin * lib/: Makefile.am, liboss.c: Added Coreaudio as an option for futur expansion -2002-05-09 15:41 thesin +2002-05-09 12:41 thesin * configure.in: my bad on the comment, just removed completly -2002-05-09 15:36 thesin +2002-05-09 12:36 thesin * configure.in: removed -ldl check and added static default to yes -2002-05-09 15:20 thesin +2002-05-09 12:20 thesin * configure.in, lib/Makefile.am: Fixed library versioning code -2002-05-09 14:42 thesin +2002-05-09 11:42 thesin * lib/Makefile.am: noinstall_HEADERS works properly now -2002-05-09 14:07 thesin +2002-05-09 11:07 thesin * .cvsignore: Thanks Fingolfin forgot about these, here is an other one. -2002-05-09 13:51 fingolfin +2002-05-09 10:51 fingolfin * .cvsignore, doc/.cvsignore, lib/.cvsignore: added .cvsignore files, so that I am at least not completly useless -2002-05-09 11:57 thesin +2002-05-09 08:57 thesin * configure.in: Removed SPEC portion since not needed ATM or maybe never -2002-05-09 11:57 thesin +2002-05-09 08:57 thesin * lib/Makefile.am: Fixed header install portion and versioning of libs -2002-05-09 11:41 thesin +2002-05-09 08:41 thesin * configure.in: now sets LDFLAGS and CPPFLAGS to enable dlcompat and uses prefix as search paths as well -2002-05-09 11:40 thesin +2002-05-09 08:40 thesin * lib/Makefile.am: an other build fix till that portion is made -2002-05-09 11:22 thesin +2002-05-09 08:22 thesin * lib/Makefile.am: Fixed so it doesn't include @COREAUDIO@ till i set it -2002-05-09 10:28 thesin +2002-05-09 07:28 thesin * configure.in: Added vasi's header changes to configure.in testing phase -2002-05-09 10:26 thesin +2002-05-09 07:26 thesin * lib/liboss.c: changed to use to proper form fomr coresaudio.h -2002-05-09 10:24 thesin +2002-05-09 07:24 thesin * lib/Makefile.am: Changing to use variables instead of hard coded -2002-05-09 04:15 vasi +2002-05-09 01:15 vasi * TODO: oss_real_time suggested. -2002-05-09 03:48 vasi +2002-05-09 00:48 vasi * include/soundcard.h, lib/Makefile.am, lib/liboss.c: Compiles, but does nothing. -2002-05-08 17:36 rangerrick +2002-05-08 14:36 rangerrick * TODO: looks like someone made the TODO in a mac editor... CR's were all messed from terminal. =) -2002-05-08 17:21 thesin +2002-05-08 14:21 thesin * lib/liboss.c: Same fix Feanor just added to configure -2002-05-08 17:18 mrvacbob +2002-05-08 14:18 mrvacbob * configure.in: Cleanup -2002-05-08 17:04 thesin +2002-05-08 14:04 thesin * Makefile.in, aclocal.m4, depcomp, stamp-h.in, doc/Makefile.in, lib/Makefile.in, config.h.in: Removed a few more files to force the use of autogen.sh for cvs users -2002-05-08 17:00 thesin +2002-05-08 14:00 thesin * configure: Removed configure, forcing uses of autogen.sh for cvs use -2002-05-08 16:59 thesin +2002-05-08 13:59 thesin * configure.in: minor fix the AM defs -2002-05-08 16:25 vasi +2002-05-08 13:25 vasi * TODO: At least this is what I think is necessary, roughly in order. Seems to make sense? -2002-05-07 18:07 thesin +2002-05-07 15:07 thesin * README: Testing the commit list -2002-05-07 17:27 rangerrick +2002-05-07 14:27 rangerrick * README: just another test -2002-05-07 17:26 rangerrick +2002-05-07 14:26 rangerrick * README: testing =) -2002-05-07 17:26 thesin +2002-05-07 14:26 thesin * AUTHORS: testing -2002-05-06 11:08 thesin +2002-05-06 08:08 thesin * AUTHORS: Updated AUTHORS -2002-05-03 13:13 thesin +2002-05-03 10:13 thesin * INSTALL: added configure to install proceedures -2002-05-03 13:11 thesin +2002-05-03 10:11 thesin * AUTHORS: trying the get the list to work again -2002-05-03 13:01 thesin +2002-05-03 10:01 thesin * ChangeLog: Updated ChangeLog and testing commit list -2002-05-03 12:57 thesin +2002-05-03 09:57 thesin * COPYING: Changed license to LGPL -2002-05-03 12:19 thesin +2002-05-03 09:19 thesin * acconfig.h, acinclude.m4, AUTHORS, ChangeLog, aclocal.m4, autogen.sh, config.guess, config.h.in, config.sub, configure, @@ -332,7 +630,7 @@ include/soundcard.h, lib/Makefile.am, lib/Makefile.in, lib/liboss.c: Initial revision -2002-05-03 12:19 thesin +2002-05-03 09:19 thesin * acconfig.h, acinclude.m4, AUTHORS, ChangeLog, aclocal.m4, autogen.sh, config.guess, config.h.in, config.sub, configure, |
From: Alexander S. <mrv...@us...> - 2003-02-22 04:32:43
|
Update of /cvsroot/liboss/liboss In directory sc8-pr-cvs1:/tmp/cvs-serv5572 Modified Files: liboss.info.in Log Message: Fixing dependencies in .info Index: liboss.info.in =================================================================== RCS file: /cvsroot/liboss/liboss/liboss.info.in,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- liboss.info.in 5 Nov 2002 16:23:11 -0000 1.4 +++ liboss.info.in 22 Feb 2003 04:32:39 -0000 1.5 @@ -2,13 +2,14 @@ Version: @VERSION@ Revision: 0.@DATESTAMP@.1 Depends: %n-shlibs (>= %v-%r) -BuildDepends: dlcompat, esound +BuildDepends: esound BuildDependsOnly: true Source: %n-%v.tar.bz2 ConfigureParams: --with-esd SplitOff: << Package: %N-shlibs Files: lib/%N.*.dylib + Depends: esound-shlibs << DocFiles: AUTHORS COPYING ChangeLog INSTALL NEWS README TODO Description: OSS Audio API Emulation Library |
From: Alexander S. <mrv...@us...> - 2003-02-22 03:06:43
|
Update of /cvsroot/liboss/liboss In directory sc8-pr-cvs1:/tmp/cvs-serv938 Modified Files: configure.in Log Message: Disabling -mmultiple and -mstring in case someone tries to run it on LinuxPPC on a 601 :) Index: configure.in =================================================================== RCS file: /cvsroot/liboss/liboss/configure.in,v retrieving revision 1.41 retrieving revision 1.42 diff -u -r1.41 -r1.42 --- configure.in 22 Feb 2003 03:02:36 -0000 1.41 +++ configure.in 22 Feb 2003 03:06:40 -0000 1.42 @@ -82,8 +82,8 @@ AC_TRY_CFLAGS("-mdynamic-no-pic", nopic="-mdynamic-no-pic", nopic="") AC_TRY_CFLAGS("-fprefetch-loop-arrays",fopt="-fprefetch-loop-arrays",fopt="") AC_TRY_CFLAGS("-frename-registers",fopt="$fopt -frename-registers") -AC_TRY_CFLAGS("-mmultiple",mopt="-mmultiple",mopt="") -AC_TRY_CFLAGS("-mstring",mopt="$mopt -mstring") +dnl AC_TRY_CFLAGS("-mmultiple",mopt="-mmultiple",mopt="") +dnl AC_TRY_CFLAGS("-mstring",mopt="$mopt -mstring") dnl dnl debug cflags |
From: Alexander S. <mrv...@us...> - 2003-02-22 03:02:41
|
Update of /cvsroot/liboss/liboss/src In directory sc8-pr-cvs1:/tmp/cvs-serv31358/src Modified Files: Makefile.am osscat.c Log Message: Builds on FreeBSD 4.7 Index: Makefile.am =================================================================== RCS file: /cvsroot/liboss/liboss/src/Makefile.am,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- Makefile.am 6 Jan 2003 21:52:57 -0000 1.4 +++ Makefile.am 22 Feb 2003 03:02:38 -0000 1.5 @@ -2,7 +2,7 @@ ## Process this file with automake to produce Makefile.in ## -AM_CFLAGS = @NONPIC_CFLAGS@ @CLIENT_CFLAGS@ +AM_CFLAGS = $(NONPIC_CFLAGS) $(INTERNAL_CLIENT_CFLAGS) bin_PROGRAMS = osscat Index: osscat.c =================================================================== RCS file: /cvsroot/liboss/liboss/src/osscat.c,v retrieving revision 1.13 retrieving revision 1.14 diff -u -r1.13 -r1.14 --- osscat.c 6 Nov 2002 21:03:32 -0000 1.13 +++ osscat.c 22 Feb 2003 03:02:38 -0000 1.14 @@ -26,7 +26,7 @@ int main(int argc, char **argv) { int retval = 0, arg = 0; - int play, sz; + int play, sz, format; int stereo = STEREO, speed = RATE; int bits = BITS; @@ -74,7 +74,7 @@ exit(1); } - int format = (bits == 16) ? AFMT_S16_NE : AFMT_S8; + format = (bits == 16) ? AFMT_S16_NE : AFMT_S8; retval = ioctl(play, SNDCTL_DSP_SETFMT, &format); if (retval < 0) return retval; |
From: Alexander S. <mrv...@us...> - 2003-02-22 03:02:41
|
Update of /cvsroot/liboss/liboss/include/liboss In directory sc8-pr-cvs1:/tmp/cvs-serv31358/include/liboss Modified Files: soundcard.h Log Message: Builds on FreeBSD 4.7 Index: soundcard.h =================================================================== RCS file: /cvsroot/liboss/liboss/include/liboss/soundcard.h,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- soundcard.h 19 Jan 2003 19:47:14 -0000 1.4 +++ soundcard.h 22 Feb 2003 03:02:38 -0000 1.5 @@ -314,6 +314,7 @@ #undef ioctl #undef open #undef close +#undef write #ifndef LIBOSS_IOCTL # define LIBOSS_IOCTL ioctl |
From: Alexander S. <mrv...@us...> - 2003-02-22 03:02:40
|
Update of /cvsroot/liboss/liboss In directory sc8-pr-cvs1:/tmp/cvs-serv31358 Modified Files: configure.in Log Message: Builds on FreeBSD 4.7 Index: configure.in =================================================================== RCS file: /cvsroot/liboss/liboss/configure.in,v retrieving revision 1.40 retrieving revision 1.41 diff -u -r1.40 -r1.41 --- configure.in 19 Jan 2003 19:47:13 -0000 1.40 +++ configure.in 22 Feb 2003 03:02:36 -0000 1.41 @@ -64,6 +64,8 @@ AC_CANONICAL_TARGET([]) AM_INIT_AUTOMAKE([dist-bzip2]) +AM_MAINTAINER_MODE + AC_PROG_CC AC_PROG_CPP AC_PROG_CXX @@ -76,7 +78,7 @@ dnl Flags not supported by all *cc* variants AC_TRY_CFLAGS("-Wall", wall="-Wall", wall="") -AC_TRY_CFLAGS("-no-cpp-precomp", nocpp="-no-cpp-precomp", nocpp="") +dnl AC_TRY_CFLAGS("-no-cpp-precomp", nocpp="-no-cpp-precomp", nocpp="") AC_TRY_CFLAGS("-mdynamic-no-pic", nopic="-mdynamic-no-pic", nopic="") AC_TRY_CFLAGS("-fprefetch-loop-arrays",fopt="-fprefetch-loop-arrays",fopt="") AC_TRY_CFLAGS("-frename-registers",fopt="$fopt -frename-registers") @@ -101,12 +103,14 @@ dnl Common cflags for all platforms CFLAGS="$CFLAGS $nocpp $wall -I${prefix}/include -O2 $fopt $mopt" NONPIC_CFLAGS="$nopic" -CLIENT_CFLAGS="$INCLUDES -Dopen=___sys_open -Dclose=___sys_close -Dioctl=___sys_ioctl -include liboss/soundcard.h" +CLIENT_CFLAGS="$INCLUDES -Dopen=___sys_open -Dwrite=___sys_write -Dclose=___sys_close -Dioctl=___sys_ioctl -include ${prefix}/liboss/soundcard.h" +INTERNAL_CLIENT_CFLAGS='$(INCLUDES) -Dopen=___sys_open -Dwrite=___sys_write -Dclose=___sys_close -Dioctl=___sys_ioctl -include $(top_srcdir)/include/liboss/soundcard.h' CPPFLAGS="$CPPFLAGS $CFLAGS" DEBUG_CFLAGS="$CFLAGS $DEBUG_CFLAGS" LIBS="-L${prefix}/lib" AC_SUBST(NONPIC_CFLAGS) AC_SUBST(CLIENT_CFLAGS) +AC_SUBST(INTERNAL_CLIENT_CFLAGS) dnl dnl Libtool |
From: Alexander S. <mrv...@us...> - 2003-01-19 19:47:17
|
Update of /cvsroot/liboss/liboss/lib In directory sc8-pr-cvs1:/tmp/cvs-serv13519/lib Modified Files: esddsp.c Log Message: liboss doesn't crash anymore. successfully ran osscat. removed machine/byte_order.h because it was unnecessary. Index: esddsp.c =================================================================== RCS file: /cvsroot/liboss/liboss/lib/esddsp.c,v retrieving revision 1.23 retrieving revision 1.24 diff -u -r1.23 -r1.24 --- esddsp.c 11 Jan 2003 23:55:59 -0000 1.23 +++ esddsp.c 19 Jan 2003 19:47:14 -0000 1.24 @@ -39,7 +39,7 @@ #include <sys/stat.h> #include <stdio.h> #include <sys/errno.h> -#ifdef HAVE_SYS_SYSCALL_H +#ifdef HAVE_SYSCALLS #include <sys/syscall.h> #endif @@ -48,7 +48,7 @@ #include <esd.h> -#ifndef HAVE_SYS_SYSCALL_H +#ifndef HAVE_SYSCALLS #define REAL_LIBC libSystem_handle #endif @@ -60,7 +60,7 @@ static char *ident = NULL, *mixer = NULL; static int use_mixer = 1; -#ifndef HAVE_SYS_SYSCALL_H +#ifndef HAVE_SYSCALLS static void *libSystem_handle = NULL; static int acquired_handle = 0; #endif @@ -80,12 +80,12 @@ { static int (*func) (int,const void*,size_t) = NULL; -#ifndef HAVE_SYS_SYSCALL_H +#ifndef HAVE_SYSCALLS if (!func) func = (int (*) (int)) dlsym (REAL_LIBC, "_write"); #endif -#ifndef HAVE_SYS_SYSCALL_H +#ifndef HAVE_SYSCALLS return (*func) (play,buf,sz); #else return syscall(SYS_write,play,buf,sz); @@ -130,7 +130,7 @@ if (str) { - mixer = malloc (strlen (str) + strlen (ident) + 10); + mixer = malloc (strlen (str) + strlen (ident) + 20); sprintf (mixer, "%s/.esddsp_%s", str, ident); } } @@ -165,7 +165,7 @@ static void liboss_init(void) { -#ifndef HAVE_SYS_SYSCALL_H +#ifndef HAVE_SYSCALLS if (!acquired_handle) { libSystem_handle = dlopen(SYSTEM_LIB,RTLD_LAZY); @@ -182,7 +182,7 @@ mode_t mode; liboss_init (); -#ifndef HAVE_SYS_SYSCALL_H +#ifndef HAVE_SYSCALLS if (!func) func = (int (*) (const char *, int, mode_t)) dlsym (REAL_LIBC, "_open"); #endif @@ -197,7 +197,11 @@ int ret; flags |= O_NONBLOCK; +#ifndef HAVE_SYSCALLS if ((ret = (*func) (pathname, flags, mode)) >= 0) +#else + if ((ret = syscall(SYS_open,pathname,flags,mode)) >= 0) +#endif return ret; } @@ -211,7 +215,7 @@ return (mixfd = (*func) (mixer, O_RDWR | O_CREAT, S_IRUSR | S_IWUSR)); } else -#ifndef HAVE_SYS_SYSCALL_H +#ifndef HAVE_SYSCALLS return (*func) (pathname, flags, mode); #else return syscall(SYS_open,pathname,flags,mode); @@ -411,7 +415,7 @@ void *argp; liboss_init (); -#ifndef HAVE_SYS_SYSCALL_H +#ifndef HAVE_SYSCALLS if (!func) func = (int (*) (int, request_t, void *)) dlsym (REAL_LIBC, "_ioctl"); #endif @@ -424,7 +428,7 @@ if(use_mixer) return mixctl (fd, request, argp); } else { /* (fd != sndfd && fd != mixfd) */ -#ifndef HAVE_SYS_SYSCALL_H +#ifndef HAVE_SYSCALLS return (*func) (fd, request, argp); #else return syscall(SYS_ioctl,fd,request,argp); @@ -437,7 +441,7 @@ liboss_close (int fd) { static int (*func) (int) = NULL; -#ifndef HAVE_SYS_SYSCALL_H +#ifndef HAVE_SYSCALLS if (!func) func = (int (*) (int)) dlsym (REAL_LIBC, "_close"); #endif @@ -445,7 +449,7 @@ sndfd = -1; else if (fd == mixfd) mixfd = -1; -#ifndef HAVE_SYS_SYSCALL_H +#ifndef HAVE_SYSCALLS return (*func) (fd); #else return syscall(SYS_close,fd); |
From: Alexander S. <mrv...@us...> - 2003-01-19 19:47:17
|
Update of /cvsroot/liboss/liboss/include/liboss In directory sc8-pr-cvs1:/tmp/cvs-serv13519/include/liboss Modified Files: soundcard.h Log Message: liboss doesn't crash anymore. successfully ran osscat. removed machine/byte_order.h because it was unnecessary. Index: soundcard.h =================================================================== RCS file: /cvsroot/liboss/liboss/include/liboss/soundcard.h,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- soundcard.h 11 Jan 2003 19:33:09 -0000 1.3 +++ soundcard.h 19 Jan 2003 19:47:14 -0000 1.4 @@ -111,7 +111,6 @@ /* Need native 16 bit format which depends on byte order */ #include <machine/endian.h> -#include <machine/byte_order.h> #if _BYTE_ORDER == _LITTLE_ENDIAN #define AFMT_S16_NE AFMT_S16_LE #else |
From: Alexander S. <mrv...@us...> - 2003-01-19 19:47:17
|
Update of /cvsroot/liboss/liboss In directory sc8-pr-cvs1:/tmp/cvs-serv13519 Modified Files: configure.in Log Message: liboss doesn't crash anymore. successfully ran osscat. removed machine/byte_order.h because it was unnecessary. Index: configure.in =================================================================== RCS file: /cvsroot/liboss/liboss/configure.in,v retrieving revision 1.39 retrieving revision 1.40 diff -u -r1.39 -r1.40 --- configure.in 18 Jan 2003 21:21:56 -0000 1.39 +++ configure.in 19 Jan 2003 19:47:13 -0000 1.40 @@ -2,8 +2,8 @@ dnl configure.in for liboss dnl AC_INIT([LibOSS],[0.0.1],[lib...@li...],[liboss]) -AC_CONFIG_SRCDIR([src/osscat.c]) -AC_CONFIG_HEADERS([config.h]) +AC_CONFIG_SRCDIR([lib/esddsp.c]) +AM_CONFIG_HEADER([config.h]) dnl Making releases: dnl LIBOSS_SUB += 1; @@ -183,6 +183,8 @@ ]) ] ) + +AC_DEFINE_UNQUOTED(HAVE_SYSCALLS,$HAS_SYSCALLS,[has the syscall() interface]) AC_ARG_WITH(esd, [ --with-esd=DIR where the ESound root is (DIR/include DIR/lib) ], |
From: Alexander S. <mrv...@us...> - 2003-01-18 21:22:01
|
Update of /cvsroot/liboss/liboss In directory sc8-pr-cvs1:/tmp/cvs-serv20050 Modified Files: configure.in Log Message: Configure script works again. Index: configure.in =================================================================== RCS file: /cvsroot/liboss/liboss/configure.in,v retrieving revision 1.38 retrieving revision 1.39 diff -u -r1.38 -r1.39 --- configure.in 12 Jan 2003 22:40:11 -0000 1.38 +++ configure.in 18 Jan 2003 21:21:56 -0000 1.39 @@ -164,30 +164,26 @@ LIBDL="" USE_DLOPEN="" SYSTEMLIB="/usr/lib/libc.so" +AC_CHECK_LIB(System,ioctl,[SYSTEMLIB="/usr/lib/libSystem.dylib"],[ +AC_CHECK_LIB(c,ioctl,[],AC_MSG_ERROR("cannot find C library"))]) + AC_SUBST(HAS_SYSCALLS) AC_SUBST(HAS_DLOPENS) AC_SUBST(SYSTEMLIB) AC_SUBST(LIBDL) AC_CHECK_HEADERS([sys/syscall.h],[ -AC_CHECK_FUNC(syscall,HAS_SYSCALLS="true") +AC_CHECK_FUNC(syscall,[HAS_SYSCALLS="true"],[ +AC_CHECK_LIB(dl,dlsym,[ +HAS_DLOPENS="true" +LIBDL="-ldl" +USE_DLOPEN="-DUSE_DLOPEN" +],[ +AC_MSG_ERROR("Cannot find syscall() or dlsym()") +]) +]) ] ) - -if test x$HAS_SYSCALLS != xtrue - AC_CHECK_LIB(dl,dlsym,[ - HAS_DLOPENS="true" - LIBDL="-ldl" - USE_DLOPEN="-DUSE_DLOPEN" - ],[ - AC_MSG_ERROR("Cannot find syscall() or dlsym()")]) - AC_CHECK_LIB(System,ioctl,[SYSTEMLIB="/usr/lib/libSystem.dylib"],[ - AC_CHECK_LIB(c,ioctl,[],[ - AC_MSG_ERROR("Cannot find the C library") - ]) - ]) -fi - AC_ARG_WITH(esd, [ --with-esd=DIR where the ESound root is (DIR/include DIR/lib) ], esd_prefix="$withval" @@ -208,7 +204,7 @@ fi done if test x$esd != xtrue; then - AC_MSG_RESULT(no) + AC_MSG_ERROR("EsounD is required") fi ]) AC_SUBST(ESD_INCS) |
From: Alexander S. <mrv...@us...> - 2003-01-12 22:40:15
|
Update of /cvsroot/liboss/liboss In directory sc8-pr-cvs1:/tmp/cvs-serv26865 Modified Files: configure.in Log Message: OK, I have no clue why this doesn't work. Index: configure.in =================================================================== RCS file: /cvsroot/liboss/liboss/configure.in,v retrieving revision 1.37 retrieving revision 1.38 diff -u -r1.37 -r1.38 --- configure.in 12 Jan 2003 16:57:59 -0000 1.37 +++ configure.in 12 Jan 2003 22:40:11 -0000 1.38 @@ -159,16 +159,20 @@ dnl Required libraries dnl -HAS_SYSCALLS= -HAS_DLOPENS= -LIBDL= -USE_DLOPEN= +HAS_SYSCALLS="" +HAS_DLOPENS="" +LIBDL="" +USE_DLOPEN="" SYSTEMLIB="/usr/lib/libc.so" AC_SUBST(HAS_SYSCALLS) AC_SUBST(HAS_DLOPENS) AC_SUBST(SYSTEMLIB) AC_SUBST(LIBDL) -AC_CHECK_HEADERS(sys/syscall.h,AC_CHECK_FUNC(syscall,HAS_SYSCALLS="true",[]),[]) +AC_CHECK_HEADERS([sys/syscall.h],[ +AC_CHECK_FUNC(syscall,HAS_SYSCALLS="true") +] +) + if test x$HAS_SYSCALLS != xtrue AC_CHECK_LIB(dl,dlsym,[ @@ -177,10 +181,12 @@ USE_DLOPEN="-DUSE_DLOPEN" ],[ AC_MSG_ERROR("Cannot find syscall() or dlsym()")]) - AC_CHECK_LIB(System,ioctl,SYSTEMLIB="/usr/lib/libSystem.dylib", - AC_CHECK_LIB(c,ioctl,,AC_MSG_ERROR("Cannot find the C library"))) + AC_CHECK_LIB(System,ioctl,[SYSTEMLIB="/usr/lib/libSystem.dylib"],[ + AC_CHECK_LIB(c,ioctl,[],[ + AC_MSG_ERROR("Cannot find the C library") + ]) + ]) fi - AC_ARG_WITH(esd, [ --with-esd=DIR where the ESound root is (DIR/include DIR/lib) ], |
From: Alexander S. <mrv...@us...> - 2003-01-12 16:58:04
|
Update of /cvsroot/liboss/liboss/lib In directory sc8-pr-cvs1:/tmp/cvs-serv8295/lib Modified Files: Makefile.am Log Message: Almost got this all cross-platformy, but I'm getting sh parse errors and I have no idea why. Index: Makefile.am =================================================================== RCS file: /cvsroot/liboss/liboss/lib/Makefile.am,v retrieving revision 1.25 retrieving revision 1.26 diff -u -r1.25 -r1.26 --- Makefile.am 11 Jan 2003 23:55:59 -0000 1.25 +++ Makefile.am 12 Jan 2003 16:58:01 -0000 1.26 @@ -2,7 +2,7 @@ ## Process this file with automake to produce Makefile.in ## -AM_CFLAGS = $(ESD_INCS) $(COREAUDIO_CFLAGS) $(DLSYM_UNDERSCORE) -DLIBOSS_INTERNAL -DSYSTEM_LIB=\"@SYSTEMLIB@\" +AM_CFLAGS = $(ESD_INCS) $(COREAUDIO_CFLAGS) -DLIBOSS_INTERNAL -DSYSTEM_LIB=\"@SYSTEMLIB@\" lib_LTLIBRARIES = liboss.la libossins.la |
From: Alexander S. <mrv...@us...> - 2003-01-12 16:58:04
|
Update of /cvsroot/liboss/liboss In directory sc8-pr-cvs1:/tmp/cvs-serv8295 Modified Files: acinclude.m4 configure.in Log Message: Almost got this all cross-platformy, but I'm getting sh parse errors and I have no idea why. Index: acinclude.m4 =================================================================== RCS file: /cvsroot/liboss/liboss/acinclude.m4,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -r1.1.1.1 -r1.2 --- acinclude.m4 3 May 2002 16:19:55 -0000 1.1.1.1 +++ acinclude.m4 12 Jan 2003 16:57:59 -0000 1.2 @@ -33,5 +33,4 @@ ifelse([$2],[],[:],[$2]) else ifelse([$3],[],[:],[$3]) - fi]) - + fi]) \ No newline at end of file Index: configure.in =================================================================== RCS file: /cvsroot/liboss/liboss/configure.in,v retrieving revision 1.36 retrieving revision 1.37 diff -u -r1.36 -r1.37 --- configure.in 12 Jan 2003 16:11:01 -0000 1.36 +++ configure.in 12 Jan 2003 16:57:59 -0000 1.37 @@ -3,7 +3,7 @@ dnl AC_INIT([LibOSS],[0.0.1],[lib...@li...],[liboss]) AC_CONFIG_SRCDIR([src/osscat.c]) -AM_CONFIG_HEADER([config.h]) +AC_CONFIG_HEADERS([config.h]) dnl Making releases: dnl LIBOSS_SUB += 1; @@ -96,10 +96,7 @@ INCLUDES='-I$(top_srcdir) -I$(top_srcdir)/include' AC_SUBST(INCLUDES) -dnl where's 'open'? -SYSTEMLIB="/usr/lib/libc.so" -AC_CHECK_LIB(System,ioctl,[SYSTEMLIB="/usr/lib/libSystem.dylib"]) -AC_SUBST(SYSTEMLIB) +dnl where's the stuff we want to pick up? dnl Common cflags for all platforms CFLAGS="$CFLAGS $nocpp $wall -I${prefix}/include -O2 $fopt $mopt" @@ -143,7 +140,6 @@ AC_FUNC_MALLOC AC_HEADER_DIRENT -AC_CHECK_HEADERS(sys/syscall.h,[USE_DLOPEN="-DUSE_DLOPEN"],[USE_DLOPEN=""]) dnl dnl CoreAudio dnl @@ -158,19 +154,33 @@ AC_SYS_LONG_FILE_NAMES + dnl dnl Required libraries dnl +HAS_SYSCALLS= +HAS_DLOPENS= LIBDL= -AC_CHECK_LIB(dl,dlsym,[LIBDL="-ldl"]) +USE_DLOPEN= +SYSTEMLIB="/usr/lib/libc.so" +AC_SUBST(HAS_SYSCALLS) +AC_SUBST(HAS_DLOPENS) +AC_SUBST(SYSTEMLIB) AC_SUBST(LIBDL) +AC_CHECK_HEADERS(sys/syscall.h,AC_CHECK_FUNC(syscall,HAS_SYSCALLS="true",[]),[]) + +if test x$HAS_SYSCALLS != xtrue + AC_CHECK_LIB(dl,dlsym,[ + HAS_DLOPENS="true" + LIBDL="-ldl" + USE_DLOPEN="-DUSE_DLOPEN" + ],[ + AC_MSG_ERROR("Cannot find syscall() or dlsym()")]) + AC_CHECK_LIB(System,ioctl,SYSTEMLIB="/usr/lib/libSystem.dylib", + AC_CHECK_LIB(c,ioctl,,AC_MSG_ERROR("Cannot find the C library"))) +fi -dnl dlcompat has a function that's a drop-in replacement -dnl for dlsym that will automatically prepend underscores on a failed lookup -DLSYM_UNDERSCORE= -dnl AC_CHECK_LIB(dl,dlsym_prepend_underscore,[DLSYM_UNDERSCORE="-Ddlsym=dlsym_prepend_underscore"]) -AC_SUBST(DLSYM_UNDERSCORE) AC_ARG_WITH(esd, [ --with-esd=DIR where the ESound root is (DIR/include DIR/lib) ], |
From: Alexander S. <mrv...@us...> - 2003-01-12 16:11:04
|
Update of /cvsroot/liboss/liboss In directory sc8-pr-cvs1:/tmp/cvs-serv20931 Modified Files: configure.in Log Message: Fixing autoupdate lameness Index: configure.in =================================================================== RCS file: /cvsroot/liboss/liboss/configure.in,v retrieving revision 1.35 retrieving revision 1.36 diff -u -r1.35 -r1.36 --- configure.in 12 Jan 2003 16:07:22 -0000 1.35 +++ configure.in 12 Jan 2003 16:11:01 -0000 1.36 @@ -3,7 +3,7 @@ dnl AC_INIT([LibOSS],[0.0.1],[lib...@li...],[liboss]) AC_CONFIG_SRCDIR([src/osscat.c]) -AC_CONFIG_HEADERS([config.h]) +AM_CONFIG_HEADER([config.h]) dnl Making releases: dnl LIBOSS_SUB += 1; |
From: Alexander S. <mrv...@us...> - 2003-01-12 16:07:26
|
Update of /cvsroot/liboss/liboss In directory sc8-pr-cvs1:/tmp/cvs-serv19683 Modified Files: Makefile.am configure.in Log Message: Added better CFLAGS checking. -frename-registers fails erroneusly due to compiler bugs Index: Makefile.am =================================================================== RCS file: /cvsroot/liboss/liboss/Makefile.am,v retrieving revision 1.9 retrieving revision 1.10 diff -u -r1.9 -r1.10 --- Makefile.am 6 Nov 2002 04:34:10 -0000 1.9 +++ Makefile.am 12 Jan 2003 16:07:22 -0000 1.10 @@ -21,7 +21,7 @@ maintainer-clean-generic: -@echo "This command is intended for maintainers to use;" -@echo "it deletes files that may require special tools to rebuild." - -rm -f Makefile.in configure acinclude.m4 aclocal.m4 + -rm -f Makefile.in configure aclocal.m4 -rm -f config.h.in stamp-h.in ltconfig ltmain.sh -rm -f config.guess config.sub install-sh missing mkinstalldirs -rm -f libtool-nofpic depcomp config.log Index: configure.in =================================================================== RCS file: /cvsroot/liboss/liboss/configure.in,v retrieving revision 1.34 retrieving revision 1.35 diff -u -r1.34 -r1.35 --- configure.in 11 Jan 2003 23:55:58 -0000 1.34 +++ configure.in 12 Jan 2003 16:07:22 -0000 1.35 @@ -3,7 +3,7 @@ dnl AC_INIT([LibOSS],[0.0.1],[lib...@li...],[liboss]) AC_CONFIG_SRCDIR([src/osscat.c]) -AM_CONFIG_HEADER([config.h]) +AC_CONFIG_HEADERS([config.h]) dnl Making releases: dnl LIBOSS_SUB += 1; @@ -78,6 +78,10 @@ AC_TRY_CFLAGS("-Wall", wall="-Wall", wall="") AC_TRY_CFLAGS("-no-cpp-precomp", nocpp="-no-cpp-precomp", nocpp="") AC_TRY_CFLAGS("-mdynamic-no-pic", nopic="-mdynamic-no-pic", nopic="") +AC_TRY_CFLAGS("-fprefetch-loop-arrays",fopt="-fprefetch-loop-arrays",fopt="") +AC_TRY_CFLAGS("-frename-registers",fopt="$fopt -frename-registers") +AC_TRY_CFLAGS("-mmultiple",mopt="-mmultiple",mopt="") +AC_TRY_CFLAGS("-mstring",mopt="$mopt -mstring") dnl dnl debug cflags @@ -98,7 +102,7 @@ AC_SUBST(SYSTEMLIB) dnl Common cflags for all platforms -CFLAGS="$CFLAGS $nocpp $wall -I${prefix}/include -O2 -fprefetch-loop-arrays -frename-registers -mcpu=750 -mtune=750 -mmultiple -mstring" +CFLAGS="$CFLAGS $nocpp $wall -I${prefix}/include -O2 $fopt $mopt" NONPIC_CFLAGS="$nopic" CLIENT_CFLAGS="$INCLUDES -Dopen=___sys_open -Dclose=___sys_close -Dioctl=___sys_ioctl -include liboss/soundcard.h" CPPFLAGS="$CPPFLAGS $CFLAGS" |
From: Alexander S. <mrv...@us...> - 2003-01-11 23:56:03
|
Update of /cvsroot/liboss/liboss/lib In directory sc8-pr-cvs1:/tmp/cvs-serv1554/lib Modified Files: Makefile.am esddsp.c Log Message: It now compiles. Also, I made it so it should dlopen() libc.so on non-Darwin platforms, so this should, theorectically, be cross-platform. Someone go try it. Index: Makefile.am =================================================================== RCS file: /cvsroot/liboss/liboss/lib/Makefile.am,v retrieving revision 1.24 retrieving revision 1.25 diff -u -r1.24 -r1.25 --- Makefile.am 11 Jan 2003 19:33:10 -0000 1.24 +++ Makefile.am 11 Jan 2003 23:55:59 -0000 1.25 @@ -2,7 +2,7 @@ ## Process this file with automake to produce Makefile.in ## -AM_CFLAGS = $(ESD_INCS) $(COREAUDIO_CFLAGS) $(DLSYM_UNDERSCORE) -DLIBOSS_INTERNAL +AM_CFLAGS = $(ESD_INCS) $(COREAUDIO_CFLAGS) $(DLSYM_UNDERSCORE) -DLIBOSS_INTERNAL -DSYSTEM_LIB=\"@SYSTEMLIB@\" lib_LTLIBRARIES = liboss.la libossins.la @@ -17,7 +17,6 @@ libossins_la_LIBADD = liboss.la libossins_la_LDFLAGS = -export-dynamic \ -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) $(ESD_LDFLAGS) -libossins_la_CFLAGS = -fomit-frame-pointer include_HEADERS = Index: esddsp.c =================================================================== RCS file: /cvsroot/liboss/liboss/lib/esddsp.c,v retrieving revision 1.22 retrieving revision 1.23 diff -u -r1.22 -r1.23 --- esddsp.c 6 Jan 2003 21:52:57 -0000 1.22 +++ esddsp.c 11 Jan 2003 23:55:59 -0000 1.23 @@ -168,7 +168,7 @@ #ifndef HAVE_SYS_SYSCALL_H if (!acquired_handle) { - libSystem_handle = dlopen("/usr/lib/libSystem.dylib",RTLD_LAZY); + libSystem_handle = dlopen(SYSTEM_LIB,RTLD_LAZY); acquired_handle = 1; } #endif |
From: Alexander S. <mrv...@us...> - 2003-01-11 23:56:02
|
Update of /cvsroot/liboss/liboss In directory sc8-pr-cvs1:/tmp/cvs-serv1554 Modified Files: configure.in Log Message: It now compiles. Also, I made it so it should dlopen() libc.so on non-Darwin platforms, so this should, theorectically, be cross-platform. Someone go try it. Index: configure.in =================================================================== RCS file: /cvsroot/liboss/liboss/configure.in,v retrieving revision 1.33 retrieving revision 1.34 diff -u -r1.33 -r1.34 --- configure.in 6 Jan 2003 21:52:54 -0000 1.33 +++ configure.in 11 Jan 2003 23:55:58 -0000 1.34 @@ -65,7 +65,9 @@ AM_INIT_AUTOMAKE([dist-bzip2]) AC_PROG_CC +AC_PROG_CPP AC_PROG_CXX +AC_PROG_CXXCPP AC_PROG_GCC_TRADITIONAL AC_PROG_INSTALL AC_PROG_MAKE_SET @@ -89,6 +91,11 @@ dnl INCLUDES='-I$(top_srcdir) -I$(top_srcdir)/include' AC_SUBST(INCLUDES) + +dnl where's 'open'? +SYSTEMLIB="/usr/lib/libc.so" +AC_CHECK_LIB(System,ioctl,[SYSTEMLIB="/usr/lib/libSystem.dylib"]) +AC_SUBST(SYSTEMLIB) dnl Common cflags for all platforms CFLAGS="$CFLAGS $nocpp $wall -I${prefix}/include -O2 -fprefetch-loop-arrays -frename-registers -mcpu=750 -mtune=750 -mmultiple -mstring" |
From: Alexander S. <mrv...@us...> - 2003-01-11 19:33:12
|
Update of /cvsroot/liboss/liboss/lib In directory sc8-pr-cvs1:/tmp/cvs-serv1744/lib Modified Files: Makefile.am Added Files: ossins.c Log Message: Added libossins back in. We need to make maintainer-clean not delete acinclude.m4 --- NEW FILE: ossins.c --- #include <liboss/soundcard.h> int ioctl (int x, unsigned long y,...) { int result; va_list l; va_start(l,y); result = liboss_ioctl(x,y,l); va_end (l); return result; } int open (const char* x, int y,...) { int result; va_list l; va_start(l,y); result = liboss_open(x,y,l); va_end (l); return result; } int close (int x) {return liboss_close(x);} int write (int x, const void *y, size_t l) { return liboss_write(x,y,l); } Index: Makefile.am =================================================================== RCS file: /cvsroot/liboss/liboss/lib/Makefile.am,v retrieving revision 1.23 retrieving revision 1.24 diff -u -r1.23 -r1.24 --- Makefile.am 6 Jan 2003 21:52:57 -0000 1.23 +++ Makefile.am 11 Jan 2003 19:33:10 -0000 1.24 @@ -4,13 +4,20 @@ AM_CFLAGS = $(ESD_INCS) $(COREAUDIO_CFLAGS) $(DLSYM_UNDERSCORE) -DLIBOSS_INTERNAL -lib_LTLIBRARIES = liboss.la +lib_LTLIBRARIES = liboss.la libossins.la liboss_la_SOURCES = esddsp.c liboss_la_DEPENDENCIES = liboss_la_LIBADD = $(COREAUDIO_LDFLAGS) $(LIBDL) $(LIBESD) liboss_la_LDFLAGS = -export-dynamic \ -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) $(ESD_LDFLAGS) + +libossins_la_SOURCES = ossins.c +libossins_la_DEPENDENCIES = liboss.la +libossins_la_LIBADD = liboss.la +libossins_la_LDFLAGS = -export-dynamic \ + -version-info $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) $(ESD_LDFLAGS) +libossins_la_CFLAGS = -fomit-frame-pointer include_HEADERS = |
From: Alexander S. <mrv...@us...> - 2003-01-11 19:33:12
|
Update of /cvsroot/liboss/liboss/include/liboss In directory sc8-pr-cvs1:/tmp/cvs-serv1744/include/liboss Modified Files: soundcard.h Log Message: Added libossins back in. We need to make maintainer-clean not delete acinclude.m4 Index: soundcard.h =================================================================== RCS file: /cvsroot/liboss/liboss/include/liboss/soundcard.h,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- soundcard.h 6 Nov 2002 21:03:30 -0000 1.2 +++ soundcard.h 11 Jan 2003 19:33:09 -0000 1.3 @@ -360,14 +360,11 @@ return result; } -static inline int LIBOSS_CLOSE (int x) {liboss_close(x); return x;} +static inline int LIBOSS_CLOSE (int x) {return liboss_close(x);} static inline int LIBOSS_WRITE (int x, const void *y, size_t l) { - int result; - - result = liboss_write(x,y,l); - return result; + return liboss_write(x,y,l); } #else extern int liboss_ioctl (int,unsigned long,va_list); |
From: Alexander S. <mrv...@us...> - 2003-01-06 21:53:01
|
Update of /cvsroot/liboss/liboss/src In directory sc8-pr-cvs1:/tmp/cvs-serv4528/src Modified Files: Makefile.am Log Message: Moved esddsp over to syscall() if possible. This should allow us to write an 'esddsp' program equivalent that works. Also disabled endian-swapping in liboss_write(), and moved CFLAGS over to AM_CFLAGS, because automake told me to. ---------------------------------------------------------------------- Index: Makefile.am =================================================================== RCS file: /cvsroot/liboss/liboss/src/Makefile.am,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- Makefile.am 23 Oct 2002 01:28:13 -0000 1.3 +++ Makefile.am 6 Jan 2003 21:52:57 -0000 1.4 @@ -2,7 +2,7 @@ ## Process this file with automake to produce Makefile.in ## -CFLAGS = @NONPIC_CFLAGS@ @CLIENT_CFLAGS@ +AM_CFLAGS = @NONPIC_CFLAGS@ @CLIENT_CFLAGS@ bin_PROGRAMS = osscat |
From: Alexander S. <mrv...@us...> - 2003-01-06 21:53:00
|
Update of /cvsroot/liboss/liboss/lib In directory sc8-pr-cvs1:/tmp/cvs-serv4528/lib Modified Files: Makefile.am esddsp.c Log Message: Moved esddsp over to syscall() if possible. This should allow us to write an 'esddsp' program equivalent that works. Also disabled endian-swapping in liboss_write(), and moved CFLAGS over to AM_CFLAGS, because automake told me to. ---------------------------------------------------------------------- Index: Makefile.am =================================================================== RCS file: /cvsroot/liboss/liboss/lib/Makefile.am,v retrieving revision 1.22 retrieving revision 1.23 diff -u -r1.22 -r1.23 --- Makefile.am 6 Nov 2002 18:14:52 -0000 1.22 +++ Makefile.am 6 Jan 2003 21:52:57 -0000 1.23 @@ -2,7 +2,7 @@ ## Process this file with automake to produce Makefile.in ## -CFLAGS = $(ESD_INCS) $(COREAUDIO_CFLAGS) $(DLSYM_UNDERSCORE) -DLIBOSS_INTERNAL +AM_CFLAGS = $(ESD_INCS) $(COREAUDIO_CFLAGS) $(DLSYM_UNDERSCORE) -DLIBOSS_INTERNAL lib_LTLIBRARIES = liboss.la Index: esddsp.c =================================================================== RCS file: /cvsroot/liboss/liboss/lib/esddsp.c,v retrieving revision 1.21 retrieving revision 1.22 diff -u -r1.21 -r1.22 --- esddsp.c 12 Dec 2002 01:19:35 -0000 1.21 +++ esddsp.c 6 Jan 2003 21:52:57 -0000 1.22 @@ -1,23 +1,25 @@ /* Evil evil evil hack to get OSS apps to cooperate with esd - * Copyright (C) 1998, 1999 Manish Singh <yo...@gi...> - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Library General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Library General Public License for more details. - * - * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place - Suite 330, - * Boston, MA 02111-1307, USA. - */ +* Copyright (C) 1998, 1999 Manish Singh <yo...@gi...> +* +* This library is free software; you can redistribute it and/or +* modify it under the terms of the GNU Library General Public +* License as published by the Free Software Foundation; either +* version 2 of the License, or (at your option) any later version. +* +* This library is distributed in the hope that it will be useful, +* but WITHOUT ANY WARRANTY; without even the implied warranty of +* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +* Library General Public License for more details. +* +* You should have received a copy of the GNU Library General Public +* License along with this library; if not, write to the +* Free Software Foundation, Inc., 59 Temple Place - Suite 330, +* Boston, MA 02111-1307, USA. +*/ -#define DSP_DEBUG +#ifdef DEBUG +#define DSP_DEBUG +#endif #ifdef DSP_DEBUG #define DPRINTF(format, args...) printf(format, ## args) @@ -46,7 +48,9 @@ #include <esd.h> +#ifndef HAVE_SYS_SYSCALL_H #define REAL_LIBC libSystem_handle +#endif typedef unsigned long request_t; @@ -56,373 +60,405 @@ static char *ident = NULL, *mixer = NULL; static int use_mixer = 1; +#ifndef HAVE_SYS_SYSCALL_H static void *libSystem_handle = NULL; static int acquired_handle = 0; +#endif #define OSS_VOLUME_BASE 50 #define ESD_VOL_TO_OSS(left, right) (short int) \ - (((OSS_VOLUME_BASE * (right) / ESD_VOLUME_BASE) << 8) | \ - (OSS_VOLUME_BASE * (left) / ESD_VOLUME_BASE)) +(((OSS_VOLUME_BASE * (right) / ESD_VOLUME_BASE) << 8) | \ + (OSS_VOLUME_BASE * (left) / ESD_VOLUME_BASE)) #define OSS_VOL_TO_ESD_LEFT(vol) \ - (ESD_VOLUME_BASE * (vol & 0xff) / OSS_VOLUME_BASE) +(ESD_VOLUME_BASE * (vol & 0xff) / OSS_VOLUME_BASE) #define OSS_VOL_TO_ESD_RIGHT(vol) \ - (ESD_VOLUME_BASE * ((vol >> 8) & 0xff) / OSS_VOLUME_BASE) +(ESD_VOLUME_BASE * ((vol >> 8) & 0xff) / OSS_VOLUME_BASE) + +static int real_write(int play, const void *buf, size_t sz) +{ + static int (*func) (int,const void*,size_t) = NULL; + +#ifndef HAVE_SYS_SYSCALL_H + if (!func) + func = (int (*) (int)) dlsym (REAL_LIBC, "_write"); +#endif + +#ifndef HAVE_SYS_SYSCALL_H + return (*func) (play,buf,sz); +#else + return syscall(SYS_write,play,buf,sz); +#endif +} static void get_volume (int *left, int *right) { - int vol; + int vol; - if (read (mixfd, &vol, sizeof (vol)) != sizeof (vol)) - *left = *right = ESD_VOLUME_BASE; - else + if (read (mixfd, &vol, sizeof (vol)) != sizeof (vol)) + *left = *right = ESD_VOLUME_BASE; + else { - *left = OSS_VOL_TO_ESD_LEFT (vol); - *right = OSS_VOL_TO_ESD_RIGHT (vol); + *left = OSS_VOL_TO_ESD_LEFT (vol); + *right = OSS_VOL_TO_ESD_RIGHT (vol); } } static void set_volume (int left, int right) { - int vol = ESD_VOL_TO_OSS (left, right); + int vol = ESD_VOL_TO_OSS (left, right); - write (mixfd, &vol, sizeof (vol)); + real_write (mixfd, &vol, sizeof (vol)); } static void dsp_init (void) { - if (!ident) + if (!ident) { - char *str = getenv ("ESDDSP_NAME"); - ident = malloc (ESD_NAME_MAX); - strncpy (ident, (str ? str : "esddsp"), ESD_NAME_MAX); - - str = getenv ("HOME"); - - use_mixer = 1; - - if (str) - { - mixer = malloc (strlen (str) + strlen (ident) + 10); - sprintf (mixer, "%s/.esddsp_%s", str, ident); - } + char *str = getenv ("ESDDSP_NAME"); + ident = malloc (ESD_NAME_MAX); + strncpy (ident, (str ? str : "esddsp"), ESD_NAME_MAX); + + str = getenv ("HOME"); + + use_mixer = 1; + + if (str) + { + mixer = malloc (strlen (str) + strlen (ident) + 10); + sprintf (mixer, "%s/.esddsp_%s", str, ident); + } } } static void mix_init (int *esd, int *player) { - esd_info_t *all_info; - esd_player_info_t *player_info; + esd_info_t *all_info; + esd_player_info_t *player_info; - if (*esd < 0 && (*esd = esd_open_sound (NULL)) < 0) - return; - - if (*player < 0) + if (*esd < 0 && (*esd = esd_open_sound (NULL)) < 0) + return; + + if (*player < 0) { - all_info = esd_get_all_info (*esd); - if (all_info) - { - for (player_info = all_info->player_list; player_info; - player_info = player_info->next) - if (!strcmp(player_info->name, ident)) - { - *player = player_info->source_id; - break; - } + all_info = esd_get_all_info (*esd); + if (all_info) + { + for (player_info = all_info->player_list; player_info; + player_info = player_info->next) + if (!strcmp(player_info->name, ident)) + { + *player = player_info->source_id; + break; + } - esd_free_all_info (all_info); - } + esd_free_all_info (all_info); + } } } static void liboss_init(void) { +#ifndef HAVE_SYS_SYSCALL_H if (!acquired_handle) - { - libSystem_handle = dlopen("/usr/lib/libSystem.dylib",RTLD_LAZY); - acquired_handle = 1; - } + { + libSystem_handle = dlopen("/usr/lib/libSystem.dylib",RTLD_LAZY); + acquired_handle = 1; + } +#endif + dsp_init(); } int liboss_open (const char *pathname, int flags, va_list args) { - static int (*func) (const char *, int, mode_t) = NULL; - mode_t mode; + static int (*func) (const char *, int, mode_t) = NULL; + mode_t mode; - liboss_init (); - - if (!func) - func = (int (*) (const char *, int, mode_t)) dlsym (REAL_LIBC, "_open"); + liboss_init (); +#ifndef HAVE_SYS_SYSCALL_H + if (!func) + func = (int (*) (const char *, int, mode_t)) dlsym (REAL_LIBC, "_open"); +#endif - mode = va_arg (args, int); + mode = va_arg (args, int); - if (!strcmp (pathname, "/dev/dsp") || !strcmp(pathname,"/dev/dspW") || -!strcmp(pathname,"/dev/sound/dsp")) + if (!strcmp (pathname, "/dev/dsp") || !strcmp(pathname,"/dev/dspW") || + !strcmp(pathname,"/dev/sound/dsp")) { - if (!getenv ("ESPEAKER")) - { - int ret; - - flags |= O_NONBLOCK; - if ((ret = (*func) (pathname, flags, mode)) >= 0) - return ret; - } - - DPRINTF ("hijacking /dev/dsp open, and taking it to esd...\n"); - settings = done = 0; - return (sndfd = esd_open_sound (NULL)); + if (!getenv ("ESPEAKER")) + { + int ret; + + flags |= O_NONBLOCK; + if ((ret = (*func) (pathname, flags, mode)) >= 0) + return ret; + } + + DPRINTF ("hijacking /dev/dsp open, and taking it to esd...\n"); + settings = done = 0; + return (sndfd = esd_open_sound (NULL)); } - else if (use_mixer && !strcmp (pathname, "/dev/mixer")) + else if (use_mixer && !strcmp (pathname, "/dev/mixer")) { - DPRINTF ("hijacking /dev/mixer open, and taking it to esd...\n"); - return (mixfd = (*func) (mixer, O_RDWR | O_CREAT, S_IRUSR | S_IWUSR)); + DPRINTF ("hijacking /dev/mixer open, and taking it to esd...\n"); + return (mixfd = (*func) (mixer, O_RDWR | O_CREAT, S_IRUSR | S_IWUSR)); } - else - return (*func) (pathname, flags, mode); + else +#ifndef HAVE_SYS_SYSCALL_H + return (*func) (pathname, flags, mode); +#else + return syscall(SYS_open,pathname,flags,mode); +#endif } static int dspctl (int fd, request_t request, void *argp) { - struct audio_info tmpinfo; + struct audio_info tmpinfo; - static esd_format_t fmt = ESD_BITS16 | ESD_STEREO | ESD_STREAM | ESD_PLAY; - static int speed; + static esd_format_t fmt = ESD_BITS16 | ESD_STEREO | ESD_STREAM | ESD_PLAY; + static int speed; - int *arg = (int *) argp; + int *arg = (int *) argp; - switch (request) + switch (request) { - case SNDCTL_DSP_RESET: - case SNDCTL_DSP_POST: - break; - - case SNDCTL_DSP_SETFMT: - fmt |= (*arg & 0x30) ? ESD_BITS16 : ESD_BITS8; - settings |= 1; - break; - - case SNDCTL_DSP_SPEED: - speed = *arg; - settings |= 2; - break; - - case SNDCTL_DSP_STEREO: - fmt &= ~ESD_MONO; - fmt |= (*arg) ? ESD_STEREO : ESD_MONO; - break; - - case SNDCTL_DSP_GETBLKSIZE: - *arg = ESD_BUF_SIZE; - break; - - case SNDCTL_DSP_SETFRAGMENT: - { - audio_buf_info *bufinfo = (audio_buf_info *) argp; - bufinfo->bytes = ESD_BUF_SIZE; - printf("Setting Fragment to: %d, %d\n", *arg, bufinfo->bytes); - } - break; - - case SNDCTL_DSP_GETFMTS: - *arg = 0x38; - break; - - case SNDCTL_DSP_GETCAPS: - *arg = 0; - break; - - case SNDCTL_DSP_GETISPACE: - { - audio_buf_info *bufinfo = (audio_buf_info *) argp; - bufinfo->bytes = ESD_BUF_SIZE; - printf("Setting ISpace to: %d, %d\n", *arg, bufinfo->bytes); - } - break; - - case SNDCTL_DSP_GETOSPACE: - { - audio_buf_info *bufinfo = (audio_buf_info *) argp; - bufinfo->bytes = ESD_BUF_SIZE; - printf("Setting OSpace to: %d, %d\n", *arg, bufinfo->bytes); - } - break; - - case SNDCTL_DSP_GETTRIGGER: - case SNDCTL_DSP_SETTRIGGER: - /* XXX Do nothing for now. */ - *arg = PCM_ENABLE_OUTPUT; - break; - - - default: - DPRINTF ("unhandled /dev/dsp ioctl (%x - %p)\n", request, argp); - break; + case SNDCTL_DSP_RESET: + case SNDCTL_DSP_POST: + break; + + case SNDCTL_DSP_SETFMT: + fmt |= (*arg & 0x30) ? ESD_BITS16 : ESD_BITS8; + settings |= 1; + break; + + case SNDCTL_DSP_SPEED: + speed = *arg; + settings |= 2; + break; + + case SNDCTL_DSP_STEREO: + fmt &= ~ESD_MONO; + fmt |= (*arg) ? ESD_STEREO : ESD_MONO; + break; + + case SNDCTL_DSP_GETBLKSIZE: + *arg = ESD_BUF_SIZE; + break; + + case SNDCTL_DSP_SETFRAGMENT: + { + audio_buf_info *bufinfo = (audio_buf_info *) argp; + bufinfo->bytes = ESD_BUF_SIZE; + printf("Setting Fragment to: %d, %d\n", *arg, bufinfo->bytes); + } + break; + + case SNDCTL_DSP_GETFMTS: + *arg = 0x38; + break; + + case SNDCTL_DSP_GETCAPS: + *arg = 0; + break; + + case SNDCTL_DSP_GETISPACE: + { + audio_buf_info *bufinfo = (audio_buf_info *) argp; + bufinfo->bytes = ESD_BUF_SIZE; + printf("Setting ISpace to: %d, %d\n", *arg, bufinfo->bytes); + } + break; + + case SNDCTL_DSP_GETOSPACE: + { + audio_buf_info *bufinfo = (audio_buf_info *) argp; + bufinfo->bytes = ESD_BUF_SIZE; + printf("Setting OSpace to: %d, %d\n", *arg, bufinfo->bytes); + } + break; + + case SNDCTL_DSP_GETTRIGGER: + case SNDCTL_DSP_SETTRIGGER: + /* XXX Do nothing for now. */ + *arg = PCM_ENABLE_OUTPUT; + break; + + + default: + DPRINTF ("unhandled /dev/dsp ioctl (%x - %p)\n", request, argp); + break; } - if (settings == 3 && !done) + if (settings == 3 && !done) { - int proto = ESD_PROTO_STREAM_PLAY; + int proto = ESD_PROTO_STREAM_PLAY; - done = 1; + done = 1; - if (write(sndfd, &proto, sizeof (proto)) != sizeof (proto)) - return -1; - if (write(sndfd, &fmt, sizeof (fmt)) != sizeof (fmt)) - return -1; - if (write(sndfd, &speed, sizeof (speed)) != sizeof (speed)) - return -1; - if (write(sndfd, ident, ESD_NAME_MAX) != ESD_NAME_MAX) - return -1; - - fmt = ESD_BITS16 | ESD_STEREO | ESD_STREAM | ESD_PLAY; - speed = 0; - - if (use_mixer) - { - int esd = -1, player = -1; - int left, right; - - while (player < 0) - mix_init (&esd, &player); - - get_volume (&left, &right); - - DPRINTF ("panning %d - %d %d\n", player, left, right); - esd_set_stream_pan (esd, player, left, right); - } + if (real_write(sndfd, &proto, sizeof (proto)) != sizeof (proto)) + return -1; + if (real_write(sndfd, &fmt, sizeof (fmt)) != sizeof (fmt)) + return -1; + if (real_write(sndfd, &speed, sizeof (speed)) != sizeof (speed)) + return -1; + if (real_write(sndfd, ident, ESD_NAME_MAX) != ESD_NAME_MAX) + return -1; + + fmt = ESD_BITS16 | ESD_STEREO | ESD_STREAM | ESD_PLAY; + speed = 0; + + if (use_mixer) + { + int esd = -1, player = -1; + int left, right; + + while (player < 0) + mix_init (&esd, &player); + + get_volume (&left, &right); + + DPRINTF ("panning %d - %d %d\n", player, left, right); + esd_set_stream_pan (esd, player, left, right); + } } - return 0; + return 0; } static int mixctl (int fd, request_t request, void *argp) { - static int esd = -1, player = -1; - static int left, right; + static int esd = -1, player = -1; + static int left, right; - int *arg = (int *) argp; + int *arg = (int *) argp; - switch (request) + switch (request) { - case SOUND_MIXER_READ_DEVMASK: - *arg = 5113; - break; - - case SOUND_MIXER_READ_PCM: - mix_init (&esd, &player); - - if (player > 0) - { - esd_info_t *all_info; - - all_info = esd_get_all_info (esd); - if (all_info) - { - esd_player_info_t *player_info; - - for (player_info = all_info->player_list; player_info; - player_info = player_info->next) - if (player_info->source_id == player) - { - *arg = ESD_VOL_TO_OSS (player_info->left_vol_scale, - player_info->right_vol_scale); - } - - esd_free_all_info (all_info); - } - else - return -1; - } - else - { - get_volume (&left, &right); - *arg = ESD_VOL_TO_OSS (left, right); - } - - break; - - case SOUND_MIXER_WRITE_PCM: - mix_init (&esd, &player); - - left = OSS_VOL_TO_ESD_LEFT (*arg); - right = OSS_VOL_TO_ESD_RIGHT (*arg); - - set_volume (left, right); - - if (player > 0) - { - DPRINTF ("panning %d - %d %d\n", player, left, right); - esd_set_stream_pan (esd, player, left, right); - } - - break; - - default: - DPRINTF ("unhandled /dev/mixer ioctl (%x - %p)\n", request, argp); - break; + case SOUND_MIXER_READ_DEVMASK: + *arg = 5113; + break; + + case SOUND_MIXER_READ_PCM: + mix_init (&esd, &player); + + if (player > 0) + { + esd_info_t *all_info; + + all_info = esd_get_all_info (esd); + if (all_info) + { + esd_player_info_t *player_info; + + for (player_info = all_info->player_list; player_info; + player_info = player_info->next) + if (player_info->source_id == player) + { + *arg = ESD_VOL_TO_OSS (player_info->left_vol_scale, + player_info->right_vol_scale); + } + + esd_free_all_info (all_info); + } + else + return -1; + } + else + { + get_volume (&left, &right); + *arg = ESD_VOL_TO_OSS (left, right); + } + + break; + + case SOUND_MIXER_WRITE_PCM: + mix_init (&esd, &player); + + left = OSS_VOL_TO_ESD_LEFT (*arg); + right = OSS_VOL_TO_ESD_RIGHT (*arg); + + set_volume (left, right); + + if (player > 0) + { + DPRINTF ("panning %d - %d %d\n", player, left, right); + esd_set_stream_pan (esd, player, left, right); + } + + break; + + default: + DPRINTF ("unhandled /dev/mixer ioctl (%x - %p)\n", request, argp); + break; } - return 0; + return 0; } int liboss_ioctl (int fd, request_t request, va_list args) { - static int (*func) (int, request_t, void *) = NULL; - void *argp; + static int (*func) (int, request_t, void *) = NULL; + void *argp; - liboss_init (); - - if (!func) - func = (int (*) (int, request_t, void *)) dlsym (REAL_LIBC, "_ioctl"); - - argp = va_arg (args, void *); - - if (fd == sndfd) - return dspctl (fd, request, argp); - else if (fd == mixfd) { - if(use_mixer) - return mixctl (fd, request, argp); - } else { /* (fd != sndfd && fd != mixfd) */ - return (*func) (fd, request, argp); - } - return 0; + liboss_init (); +#ifndef HAVE_SYS_SYSCALL_H + if (!func) + func = (int (*) (int, request_t, void *)) dlsym (REAL_LIBC, "_ioctl"); +#endif + + argp = va_arg (args, void *); + + if (fd == sndfd) + return dspctl (fd, request, argp); + else if (fd == mixfd) { + if(use_mixer) + return mixctl (fd, request, argp); + } else { /* (fd != sndfd && fd != mixfd) */ +#ifndef HAVE_SYS_SYSCALL_H + return (*func) (fd, request, argp); +#else + return syscall(SYS_ioctl,fd,request,argp); +#endif + } + return 0; } int liboss_close (int fd) { - static int (*func) (int) = NULL; - - if (!func) - func = (int (*) (int)) dlsym (REAL_LIBC, "_close"); - - if (fd == sndfd) - sndfd = -1; - else if (fd == mixfd) - mixfd = -1; - - return (*func) (fd); + static int (*func) (int) = NULL; +#ifndef HAVE_SYS_SYSCALL_H + if (!func) + func = (int (*) (int)) dlsym (REAL_LIBC, "_close"); +#endif + if (fd == sndfd) + sndfd = -1; + else if (fd == mixfd) + mixfd = -1; +#ifndef HAVE_SYS_SYSCALL_H + return (*func) (fd); +#else + return syscall(SYS_close,fd); +#endif } int liboss_write (int play, const void *buf, size_t sz) { - int retval; - short* i; - - for (i = (short*)buf; i < (short*)(buf + sz); ++i) - *i = NXSwapShort(*i); - retval = write(play, buf, sz); - - return retval; +#if 0 + short* i; + for (i = (short*)buf; i < (short*)(buf + sz); ++i) + *i = NXSwapShort(*i); +#endif + return real_write(play,buf,sz); } |
From: Alexander S. <mrv...@us...> - 2003-01-06 21:53:00
|
Update of /cvsroot/liboss/liboss In directory sc8-pr-cvs1:/tmp/cvs-serv4528 Modified Files: configure.in Log Message: Moved esddsp over to syscall() if possible. This should allow us to write an 'esddsp' program equivalent that works. Also disabled endian-swapping in liboss_write(), and moved CFLAGS over to AM_CFLAGS, because automake told me to. ---------------------------------------------------------------------- Index: configure.in =================================================================== RCS file: /cvsroot/liboss/liboss/configure.in,v retrieving revision 1.32 retrieving revision 1.33 diff -u -r1.32 -r1.33 --- configure.in 12 Dec 2002 01:19:34 -0000 1.32 +++ configure.in 6 Jan 2003 21:52:54 -0000 1.33 @@ -116,7 +116,7 @@ dnl Checks for typedefs, structures, and compiler characteristics. dnl AC_C_BIGENDIAN -dnl AC_C_BIGENDIAN triggers an AC_TRY_RUN warning; we can't cross compile +dnl AC_C_BIGENDIAN triggers an AC_RUN_IFELSE([AC_LANG_SOURCE([[]])],[],[],[]) warning; we can't cross compile dnl liboss (oh, well) AC_C_CONST AC_C_INLINE |