pkgsrc/audio/portaudio/patches/patch-ac
2010-10-12 21:50:49 +00:00

58 lines
1.9 KiB
Text

$NetBSD: patch-ac,v 1.8 2010/10/12 21:50:49 joerg Exp $
--- Makefile.in.orig 2003-02-11 14:24:56.000000000 +0000
+++ Makefile.in
@@ -5,14 +5,14 @@
#
PREFIX = @prefix@
-CC = @CC@
+CC = ${LIBTOOL} --mode=compile @CC@
CFLAGS = @CFLAGS@ -Ipa_common
-LIBS = @LIBS@
+LIBS = ${LIBOSSAUDIO} ${RT_LIB_SCHED} -L@prefix@/lib ${COMPILER_RPATH_FLAG}@prefix@/lib @LIBS@
AR = @AR@
RANLIB = @RANLIB@
INSTALL = @INSTALL@
SHARED_FLAGS = @SHARED_FLAGS@
-DLL_LIBS = @DLL_LIBS@
+DLL_LIBS = @DLL_LIBS@ ${LIBOSSAUDIO} ${RT_LIB_SCHED}
OTHER_OBJS = @OTHER_OBJS@
@@ -57,20 +57,16 @@ all: lib/$(PALIB) lib/$(PADLLV) tests
tests: bin/ $(TESTS)
lib/$(PALIB): lib/ $(OBJS) Makefile $(PAINC)
- $(AR) ruv lib/$(PALIB) $(OBJS)
- $(RANLIB) lib/$(PALIB)
+ ${LIBTOOL} --mode=link @CC@ -o lib/${PALIB:.a=.la} ${OBJS:.o=.lo} -rpath ${PREFIX}/lib -version-info 0:18:0 $(DLL_LIBS)
lib/$(PADLLV): lib/ $(OBJS) Makefile $(PAINC)
- $(CC) $(SHARED_FLAGS) -o lib/$(PADLLV) $(OBJS) $(DLL_LIBS)
$(TESTS): bin/%: lib/$(PALIB) Makefile $(PAINC) pa_tests/%.c
- $(CC) -o $@ $(CFLAGS) pa_tests/$*.c lib/$(PALIB) $(LIBS)
+ ${LIBTOOL} --mode=link @CC@ -o $@ $(CFLAGS) pa_tests/$*.c lib/${PALIB:.a=.la} $(LIBS)
install: lib/$(PALIB) lib/$(PADLLV)
- $(INSTALL) -m 644 lib/$(PADLLV) $(PREFIX)/lib/$(PADLLV)
- $(INSTALL) -m 644 lib/$(PALIB) $(PREFIX)/lib/$(PALIB)
- cd $(PREFIX)/lib && rm -f $(PADLL) && ln -s $(PADLLV) $(PADLL)
- $(INSTALL) -m 644 pa_common/portaudio.h $(PREFIX)/include/portaudio.h
+ ${LIBTOOL} --mode=install $(INSTALL) -m 644 lib/${PALIB:.a=.la} $(DESTDIR)$(PREFIX)/lib/
+ $(INSTALL) -m 644 pa_common/portaudio.h $(DESTDIR)$(PREFIX)/include/portaudio.h
@echo ""
@echo "------------------------------------------------------------"
@echo "PortAudio was successfully installed."
@@ -89,8 +86,8 @@ clean:
%.o: %.c Makefile $(PAINC)
$(CC) -c $(CFLAGS) $< -o $@
-bin:
+bin/:
mkdir bin
-lib:
+lib/:
mkdir lib