$NetBSD: patch-ad,v 1.2 2004/05/25 21:49:26 wiz Exp $ --- libavformat/Makefile.orig 2003-09-28 17:26:40.000000000 +0200 +++ libavformat/Makefile @@ -69,12 +69,14 @@ endif SRCS := $(OBJS:.o=.c) $(PPOBJS:.o=.cpp) +install: all + $(LIBTOOL) --mode=install $(BSD_INSTALL_DATA) $(LIB:.a=.la) $(prefix)/lib + all: $(LIB) $(SLIB) $(LIB): $(OBJS) $(PPOBJS) rm -f $@ - $(AR) rc $@ $(OBJS) $(PPOBJS) - $(RANLIB) $@ + $(LIBTOOL) --mode=link $(CC) -o $(LIB:.a=.la) $(OBJS:.o=.lo) $(PPOBJS:.o=.lo) -rpath $(prefix)/lib $(LIBOSSAUDIO) $(SLIB): $(OBJS) ifeq ($(CONFIG_WIN32),yes) @@ -84,9 +86,6 @@ else $(CC) $(SHFLAGS) -o $@ $(OBJS) $(PPOBJS) $(EXTRALIBS) endif -depend: $(SRCS) - $(CC) -MM $(CFLAGS) $^ 1>.depend - ifeq ($(BUILD_SHARED),yes) install: all install-headers ifeq ($(CONFIG_WIN32),yes) @@ -112,11 +111,11 @@ install-headers: "$(prefix)/include/ffmpeg" %.o: %.c - $(CC) $(CFLAGS) -c -o $@ $< + $(LIBTOOL) --mode=compile $(CC) $(CFLAGS) -c -o $@ $< # BeOS: remove -Wall to get rid of all the "multibyte constant" warnings %.o: %.cpp - g++ $(subst -Wall,,$(CFLAGS)) -c -o $@ $< + $(LIBTOOL) --mode=compile $(CXX) $(subst -Wall,,$(CFLAGS)) -c -o $@ $< clean: rm -f *.o *.d .depend *~ *.a $(LIB)