[Bug 267181] audio/portaudio: Add missing example headers preventing compilation

From: <bugzilla-noreply_at_freebsd.org>
Date: Thu, 20 Oct 2022 06:18:31 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=267181

--- Comment #5 from Tatsuki Makino <tatsuki_makino@hotmail.com> ---
(In reply to Hans Petter Selasky from comment #3)

Add a few more.

> clang -L/usr/local/lib -lm -lpthread -lportaudio -I/usr/local/include pa_unix*.c pa_allocation.c pa_ringbuffer.c pa_debugprint.c pa_front.c paex_ocean_shore.c

It seems a little better to link with libportaudio.a instead of -lportaudio.

cc -I/usr/local/include -I /tmp/directory_for_pa_ringbuffer.h_and_pa_util.h -lm
-pthread /usr/local/lib/libportaudio.a
/usr/local/share/examples/portaudio/paex_ocean_shore.c

However, libportaudio.a does not contain anything that can resolve the
PaUtil_*RingBuffer* symbol.

The reason for this is that libportaudio links COMMON_OBJS and OTHER_OBJS in
${WRKSRC}/Makefile.in, but OTHER_OBJS is a variable provided from
${WRKSRC}/configure.in.
In configure.in, OTHER_OBJS is added by the add_objects function, and
pa_ringbuffer.o is also added here.
In order for ringbuffer to be included on FreeBSD ports, JACK option must be
set.

-- 
You are receiving this mail because:
You are on the CC list for the bug.