Hello,
Romain Beauxis, le Thu 15 Jul 2010 00:16:15 -0500, a écrit :
The latest oss4 release is 4.2-build2003. The version of
libsalsa provided there seems to have improved, in particular
it now has a symbol that was missing when building ocaml-alsa
on kfreebsd using libsalsa..
(symbol: snd_pcm_hw_params_get_buffer_size_min)
Ah, good.
I also take this opportunity to reiterate my proposition
to merge oss4 and libsalsa packaging effort into one.
Right. The only barrier I can see is that in oss-libsalsa, we include
some alsa headers to be able to provide them in liboss-salsa-dev, and
we apply some dirty fixes for hurd-i386, see the attached diff. If
that's fine with oss4 packaging, then it's all good, I'll have a look at
integrating liboss-salsa in oss4.
Samuel
--- oss-libsalsa-4.1-build1052b.orig/include/soundcard.h
+++ oss-libsalsa-4.1-build1052b/include/soundcard.h
@@ -15,6 +15,10 @@
#ifndef SOUNDCARD_H
#define SOUNDCARD_H
+/* Note: GNU/Hurd: the _IOT__IOTBASE_* definitions will not work, that's ok
+ * since we do not support sound yet anyway, and we do not export this to other
+ * packages. */
+
/*
* This file is part of Open Sound System
*
@@ -106,6 +110,7 @@
#define OSS_ID_SIZE16
#define OSS_HANDLE_SIZE32
typedef char oss_longname_t[OSS_LONGNAME_SIZE];
+#define _IOT__IOTBASE_oss_longname_t _IOT (0, 0, 0, 0, 0, 0)
typedef char oss_label_t[OSS_LABEL_SIZE];
typedef char oss_devnode_t[OSS_DEVNODE_SIZE];
typedef char oss_devname_t[OSS_DEVNAME_SIZE];
@@ -1085,6 +1090,7 @@
int bytes; /* Available space in bytes (includes partially
used fragments) */
/* Note! 'bytes' could be more than fragments*fragsize */
} audio_buf_info;
+#define _IOT__IOTBASE_audio_buf_info _IOT (0, 0, 0, 0, 0, 0)
#define SNDCTL_DSP_GETOSPACE __SIOR ('P',12, audio_buf_info)
#define SNDCTL_DSP_GETISPACE __SIOR ('P',13, audio_buf_info)
@@ -1759,6 +1765,7 @@
char revision_info[256]; /* For internal use */
int filler[172]; /* For future expansion */
} oss_sysinfo;
+#define _IOT__IOTBASE_oss_sysinfo _IOT (0, 0, 0, 0, 0, 0)
typedef struct oss_mixext
{
@@ -1846,6 +1853,7 @@
int rgbcolor;/* 0 means default color (not black) .
Otherwise 24 bit RGB color */
int filler[6];
} oss_mixext;
+#define _IOT__IOTBASE_oss_mixext _IOT (0, 0, 0, 0, 0, 0)
/*
* Recommended colors to be used in the rgbcolor field. These match the
@@ -1877,6 +1885,7 @@
int timestamp; /* Must be set to oss_mixext.timestamp */
int filler[8]; /* Reserved for future use. Initialize to 0 */
} oss_mixer_value;
+#define _IOT__IOTBASE_oss_mixer_value _IOT (0, 0, 0, 0, 0, 0)
#define OSS_ENUM_MAXVALUE 255
#define OSS_ENUM_STRINGSIZE3000
@@ -1925,6 +1934,7 @@
int next_rec_engine; /* Read the documentation for more info */
int filler[184];
} oss_audioinfo;
+#define _IOT__IOTBASE_oss_audioinfo _IOT (0, 0, 0, 0, 0, 0)
typedef struct oss_mixerinfo
{
@@ -1954,6 +1964,7 @@
int legacy_device;
int filler[245]; /* Reserved */
} oss_mixerinfo;
+#define _IOT__IOTBASE_oss_mixerinfo _IOT (0, 0, 0, 0, 0, 0)
typedef struct oss_midi_info
{
@@ -1999,6 +2010,7 @@
int intr_count, ack_count;
int filler[154];
} oss_card_info;
+#define _IOT__IOTBASE_oss_card_info _IOT (0, 0, 0, 0, 0, 0)
#define SNDCTL_SYSINFO __SIOR ('X', 1, oss_sysinfo)
#define OSS_SYSINFOSNDCTL_SYSINFO /* Old name */
--- oss-libsalsa-4.1-build1052b.orig/lib/libsalsa/seqmid.c
+++ oss-libsalsa-4.1-build1052b/lib/libsalsa/seqmid.c
@@ -38,7 +38,7 @@
int result;
dbg_printf
-(snd_seq_create_simple_port(seq=%x, name='%s', caps=%x, type=%x)\n, seq,
+(snd_seq_create_simple_port(seq=%p, name='%s', caps=%x, type=%x)\n, seq,
name, caps, type);
memset (pinfo, 0, sizeof (pinfo));
--- oss-libsalsa-4.1-build1052b.orig/lib/libsalsa/Makefile
+++ oss-libsalsa-4.1-build1052b/lib/libsalsa/Makefile
@@ -2,7 +2,7 @@
OSSLIBDIR=/usr/lib/oss
-CFLAGS=-O -I../../include -I../libOSSlib
+CFLAGS+=-I../../include -I../libOSSlib
LIBTOOL=libtool --tag=CC
all: libsalsa.la
@@ -46,7 +46,7 @@
$(LIBTOOL) --mode=compile gcc $(CFLAGS) -c rawmidi.c
libsalsa.la: $(LOBJECTS)
- $(LIBTOOL) --mode=link gcc -rpath /usr/lib
-Wl,--version-script=Versions -version-info 2:0:0 -o libsalsa.la $(LOBJECTS)
-L../libOSSlib -lOSSlib
+ $(LIBTOOL) --mode=link gcc -rpath /usr/lib -R
/usr/lib/oss-libsalsa -Wl,--version-script=Versions -version-info 2:0:0 -o
liboss-salsa.la $(LOBJECTS) -L../libOSSlib -lOSSlib
install: libsalsa.la
$(LIBTOOL) cp libsalsa.la /usr/lib
--- oss-libsalsa-4.1-build1052b.orig/lib/libsalsa/seq.c
+++ oss-libsalsa-4.1-build1052b/lib/libsalsa/seq.c
@@ -111,7 +111,7 @@
if ((seq = malloc (sizeof (*seq))) == NULL)
return -ENOMEM;
- dbg_printf (Created sequencer seq=%x\n, seq);
+