Changeset 3135:af6a10f1b0ab in roaraudio


Ignore:
Timestamp:
01/15/10 10:23:04 (10 years ago)
Author:
phi
Branch:
default
Message:

done a lot stuff for testing, plugin now loads but libasound2 segfaults

Location:
plugins
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • plugins/alsa/Makefile

    r3134 r3135  
    99 
    1010#DEFINES=-DDEBUG 
     11DEFINES=-DPACKAGE_NAME=\"\" -DPACKAGE_TARNAME=\"\" -DPACKAGE_VERSION=\"\" -DPACKAGE_STRING=\"\" -DPACKAGE_BUGREPORT=\"\" -DPACKAGE=\"alsa-plugins\" -DVERSION=\"1.0.13\" -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_DLFCN_H=1 -DSTDC_HEADERS=1 -DHAVE_LIBASOUND=1 -D_REENTRANT -DDEBUG 
    1112CFLAGS += -g -Wall -O2 -I../../include $(DEFINES) $(INCLUDE) $(INCPATH) $(SHARED_CF) $(fPIC) -I/usr/include/alsa -D_GNU_SOURCE 
    12 LDFLAGS = -g $(SHARED) $(LDPATH) -L../../lib -module -avoid-version -export-dynamic 
    13 LIBS    = $(LIBROAR) -lasound 
     13LDFLAGS = -g $(SHARED) $(LDPATH) -L../../lib  
     14LIBS    = $(LIBROAR) -lm -ldl /usr/lib/libasound.so 
    1415 
    1516all: ${TARGET} 
     
    2627 
    2728$(SLIB): $(OBJS) 
    28         $(CC) $(LDFLAGS) -Wl,-soname,$(SLIB) -o $(SLIB) $(OBJS) $(LIBS) 
     29        $(CC) $(LDFLAGS) -Wl,-soname -Wl,$(SLIB) -o $(SLIB) $(OBJS) $(LIBS) 
  • plugins/alsa/pcm.c

    r3134 r3135  
    5050 int ret; 
    5151 
     52 ROAR_DBG("roar_hw_constraint(*) = ?"); 
     53 
    5254 if ( (ret = snd_pcm_ioplug_set_param_list(io, SND_PCM_IOPLUG_HW_ACCESS, 
    5355        _as(access_list), access_list)) < 0 ) 
     
    7476  return ret; 
    7577 
     78 ROAR_DBG("roar_hw_constraint(*) = 0"); 
     79 
    7680 return 0; 
    7781} 
    7882 
    7983static int roar_pcm_dummy (snd_pcm_ioplug_t * io) { 
     84 ROAR_DBG("roar_pcm_dummy(*) = ?"); 
    8085 return 0; 
    8186} 
    8287 
    8388static snd_pcm_sframes_t roar_pcm_pointer(snd_pcm_ioplug_t *io) { 
     89 ROAR_DBG("roar_pcm_pointer(*) = ?"); 
    8490 return 0; 
    8591} 
     
    9399 char * buf; 
    94100 
     101 ROAR_DBG("roar_pcm_transfer(*) = ?"); 
     102 
    95103 buf = (char *)areas->addr + (areas->first + areas->step * offset) / 8; 
    96104 
     
    101109 
    102110static int roar_pcm_delay(snd_pcm_ioplug_t *io, snd_pcm_sframes_t *delayp) { 
     111 ROAR_DBG("roar_pcm_delay(*) = ?"); 
    103112 return 0; 
    104113} 
     
    106115static int roar_pcm_prepare(snd_pcm_ioplug_t *io) { 
    107116 struct roar_alsa_pcm * self = io->private_data; 
     117 
     118 ROAR_DBG("roar_pcm_prepare(*) = ?"); 
    108119 
    109120 if ( self->stream_opened ) { 
     
    127138static int roar_pcm_hw_params(snd_pcm_ioplug_t *io, snd_pcm_hw_params_t *params) { 
    128139 struct roar_alsa_pcm * self = io->private_data; 
     140 
     141 ROAR_DBG("roar_pcm_hw_params(*) = ?"); 
    129142 
    130143 self->info.channels = io->channels; 
     
    161174static int roar_pcm_close (snd_pcm_ioplug_t * io) { 
    162175 struct roar_alsa_pcm * self = io->private_data; 
     176 
     177 ROAR_DBG("roar_pcm_close(*) = ?"); 
    163178 
    164179 roar_disconnect(&(self->roar.con)); 
     
    192207 int            ret; 
    193208 
    194  printf("TEST!\n"); 
     209 ROAR_DBG("SND_PCM_PLUGIN_DEFINE_FUNC(roar) = ?"); 
    195210 
    196211 snd_config_for_each(i, next, conf) { 
     
    245260 } 
    246261 
     262 ROAR_DBG("SND_PCM_PLUGIN_DEFINE_FUNC(roar) = 0"); 
     263 
    247264 return 0; 
    248265} 
     
    250267SND_PCM_PLUGIN_SYMBOL(roar); 
    251268 
     269int __snd_pcm_roar_open_dlsym_pcm_001 (void) { 
     270 return 0; 
     271} 
     272 
    252273//ll 
  • plugins/alsa/roar.c

    r3133 r3135  
    3535#include "roar.h" 
    3636 
     37struct snd_dlsym_link *snd_dlsym_start; 
     38 
    3739//ll 
  • plugins/alsa/roar.h

    r3134 r3135  
    3939#include <errno.h> 
    4040#include <alsa/asoundlib.h> 
     41#include <alsa/global.h> 
    4142#include <alsa/pcm_external.h> 
    4243#include <alsa/control_external.h> 
  • plugins/alsavs/Makefile

    r3134 r3135  
    99 
    1010#DEFINES=-DDEBUG 
     11DEFINES=-DPACKAGE_NAME=\"\" -DPACKAGE_TARNAME=\"\" -DPACKAGE_VERSION=\"\" -DPACKAGE_STRING=\"\" -DPACKAGE_BUGREPORT=\"\" -DPACKAGE=\"alsa-plugins\" -DVERSION=\"1.0.13\" -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_DLFCN_H=1 -DSTDC_HEADERS=1 -DHAVE_LIBASOUND=1 -D_REENTRANT -DDEBUG 
    1112CFLAGS += -g -Wall -O2 -I../../include $(DEFINES) $(INCLUDE) $(INCPATH) $(SHARED_CF) $(fPIC) -I/usr/include/alsa -D_GNU_SOURCE 
    12 LDFLAGS = -g $(SHARED) $(LDPATH) -L../../lib -module -avoid-version -export-dynamic 
    13 LIBS    = $(LIBROAR) -lasound 
     13LDFLAGS = -g $(SHARED) $(LDPATH) -L../../lib  
     14LIBS    = $(LIBROAR) -lm -ldl /usr/lib/libasound.so 
    1415 
    1516all: ${TARGET} 
     
    2627 
    2728$(SLIB): $(OBJS) 
    28         $(CC) $(LDFLAGS) -Wl,-soname,$(SLIB) -o $(SLIB) $(OBJS) $(LIBS) 
     29        $(CC) $(LDFLAGS) -Wl,-soname -Wl,$(SLIB) -o $(SLIB) $(OBJS) $(LIBS) 
  • plugins/alsavs/roar.c

    r3133 r3135  
    3535#include "roar.h" 
    3636 
     37struct snd_dlsym_link *snd_dlsym_start; 
     38 
    3739//ll 
  • plugins/alsavs/roar.h

    r3134 r3135  
    3939#include <errno.h> 
    4040#include <alsa/asoundlib.h> 
     41#include <alsa/global.h> 
    4142#include <alsa/pcm_external.h> 
    4243#include <alsa/control_external.h> 
Note: See TracChangeset for help on using the changeset viewer.