PJSIP with JACK Audio Connection Kit?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2/25/08, Matthias Geier <matthias.geier at gmail.com> wrote:
> Hello all!
>
[snip]
>  The thing is: Portaudio originally supports JACK which can be activated with
>  ./configure --with-jack
>  It is even switched on by default (I think).
>
>  Sadly, PJSIP uses its own build-process and this feature was somehow lost.
>

Yeah sorry about that, but there are some benefits of having our own
build system (such as having consistent setting).


>  I tried to re-activate it with the following changes:
>
>  1) I created a user.mak with following contents:
>  export AC_PA_USE_ALSA = 0
>  export AC_PA_USE_OSS = 0
>  export CFLAGS += -DPA_USE_JACK=1
>  export APP_LDLIBS += -ljack
>  export LDFLAGS += -ljack
>  export PORTAUDIO_OBJS += pa_jack.o pa_ringbuffer.o
>
>  2) I created a third_party/build/portaudio/src/pa_jack.c with
>  following contents:
>  #include "../../../portaudio/src/hostapi/jack/pa_jack.c"
>
>  3) I temporarily disabled the file /usr/include/alsa/version.h by
>  renaming it. Without that, the configure script tries to build the
>  ALSA driver and the JACK driver doesn't work
>
>  After these 3 steps it worked.
>

Okay.

>  Then, when I tried it again several days (maybe some weeks?) later, I
>  got the following error from the linker:
>
>  [...]/pjproject-0.8.0/third_party/lib/libportaudio-i686-pc-linux-gnu.a(pa_jack.o):
>  In function `RealStop':
>  pa_jack.c:(.text+0x1b7f): undefined reference to `jack_port_unlock'
>  pa_jack.c:(.text+0x1bb4): undefined reference to `jack_port_lock'
>  pa_jack.c:(.text+0x1c4f): undefined reference to `jack_port_unlock'
>  pa_jack.c:(.text+0x1c88): undefined reference to `jack_port_lock'
>  collect2: ld returned 1 exit status
>  make[2]: *** [../bin/pjsua-i686-pc-linux-gnu] Error 1
>  make[2]: Leaving directory `[...]/pjproject-0.8.0/pjsip-apps/build'
>
>  I did a web-search and found the explanation that those two functions
>  jack_port_lock and jack_port_unlock are deprecated and were removed
>  from JACK.
>  So I guess in a recent system update (btw: I'm using Debian) JACK was
>  updated and these functions got deactivated.
>  I don't know if that's true, but at least it's an explanation ;-)
>

That is quite strange, since we have our own copy of PortAudio in our
SVN (pulled directly from PA SVN), and this copy is locked to a
specific revision (do "svn pget svn:externals" in third_party
directory). So unless you removed this specific revision number in
your SVN flag, system update should not affect the build.

>  So now I'm kind of stuck.
>  It would be great if someone could help me out.
>
>  Is there another (better) way to activate JACK?
>
>  Would it work if libportaudio were linked dynamically? There is a
>  Debian packet "libportaudio19-dev" which I could probably use.
>

You can probably do that, by:
 1) copying libportaudio.a from your /usr/lib to third_party/lib, and
renaming the filename to libportaudio-${TARGET}.a
 2) modify third_party/build/portaudio to do nothing
 3) Add "CFLAGS += -I/portaudio/inc/dir" in user.mak to let pasound.c
find the new PortAudio

Good luck! :)

cheers,
 -benny


>  Or do I have to downgrade JACK?
>
>  If you need more information about my system I will gladly provide it,
>  I just didn't want to make this post even longer.
>
>  TIA
>  Matthias



[Index of Archives]     [Asterisk Users]     [Asterisk App Development]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [Linux API]
  Powered by Linux