summaryrefslogtreecommitdiff
path: root/v4l2-apps/libv4l/libv4l1/Makefile
diff options
context:
space:
mode:
authorMichael Krufky <mkrufky@kernellabs.com>2009-09-15 11:14:17 -0400
committerMichael Krufky <mkrufky@kernellabs.com>2009-09-15 11:14:17 -0400
commitb0d1e983e98ec9b72146c16d08b3409a418c62df (patch)
treeb61e50f54f11599f31b476c477a69883597f5fad /v4l2-apps/libv4l/libv4l1/Makefile
parent2c16279409d239adbbc884a308e71264ea02ef46 (diff)
parent219fe38bd79dab42db83cacc1f5444d0e27fa8ea (diff)
downloadmediapointer-dvb-s2-b0d1e983e98ec9b72146c16d08b3409a418c62df.tar.gz
mediapointer-dvb-s2-b0d1e983e98ec9b72146c16d08b3409a418c62df.tar.bz2
merge: ~mkrufky/tda18271
From: Michael Krufky <mkrufky@kernellabs.com> Priority: normal Signed-off-by: Michael Krufky <mkrufky@kernellabs.com>
Diffstat (limited to 'v4l2-apps/libv4l/libv4l1/Makefile')
-rw-r--r--v4l2-apps/libv4l/libv4l1/Makefile16
1 files changed, 9 insertions, 7 deletions
diff --git a/v4l2-apps/libv4l/libv4l1/Makefile b/v4l2-apps/libv4l/libv4l1/Makefile
index 27848477e..e6d306055 100644
--- a/v4l2-apps/libv4l/libv4l1/Makefile
+++ b/v4l2-apps/libv4l/libv4l1/Makefile
@@ -3,7 +3,7 @@ override CPPFLAGS += -I../include -I../../../include -fvisibility=hidden
CFLAGS := -g -O1
CFLAGS += -Wall -Wno-unused -Wpointer-arith -Wstrict-prototypes -Wmissing-prototypes
-LIBS = -lpthread
+LIBS_libv4l1 = -lpthread
V4L1_OBJS = libv4l1.o log.o
V4L1COMPAT = v4l1compat.so
@@ -13,9 +13,10 @@ INCLUDES = ../include/libv4l1.h
ifeq ($(LINKTYPE),static)
V4L1_LIB = libv4l1.a
+V4L1_DEPS = $(V4L1_OBJS)
else
V4L1_LIB = libv4l1.so
-V4L1_OBJS += ../libv4l2/libv4l2.so
+V4L1_DEPS += $(V4L1_OBJS) ../libv4l2/libv4l2.so
TARGETS += $(V4L1COMPAT)
override CPPFLAGS += -fPIC
endif
@@ -34,8 +35,9 @@ endif
all: $(TARGETS)
+-include $(V4L1_OBJS:.o=.d)
-$(V4L1_LIB): $(V4L1_OBJS)
+$(V4L1_LIB): $(V4L1_DEPS)
$(V4L1COMPAT): $(V4L1COMPAT_O) $(V4L1_LIB)
@@ -46,7 +48,7 @@ libv4l1.pc:
@echo 'Name: libv4l1' >> libv4l1.pc
@echo 'Description: v4l1 compatibility library' >> libv4l1.pc
@echo 'Version: '$(V4L2_LIB_VERSION) >> libv4l1.pc
- @echo 'Requires: libv4l2' >> libv4l1.pc
+ @echo 'Requires.private: libv4l2' >> libv4l1.pc
@echo 'Libs: -L$${libdir} -lv4l1' >> libv4l1.pc
@echo 'Libs.private: -lpthread' >> libv4l1.pc
@echo 'Cflags: -I$${prefix}/include' >> libv4l1.pc
@@ -69,13 +71,13 @@ endif
install -m 644 libv4l1.pc $(DESTDIR)$(LIBDIR)/pkgconfig
clean::
- rm -f *.a *.so* *.o *.d libv4l1.pc log *~
+ rm -f *.a *.so* *.o *.d libv4l1.pc log *~ *.orig *.rej DEADJOE
%.o: %.c
- $(CC) -c -MMD $(CPPFLAGS) $(CFLAGS) -o $@ $<
+ $(CC) -Wp,-MMD,"$*.d",-MQ,"$@",-MP -c $(CPPFLAGS) $(CFLAGS) -o $@ $<
%.so:
- $(CC) -shared $(LDFLAGS) -Wl,-soname,$@.$(LIB_RELEASE) -o $@.$(LIB_RELEASE) $^ $(LIBS)
+ $(CC) -shared $(LDFLAGS) -Wl,-soname,$@.$(LIB_RELEASE) -o $@.$(LIB_RELEASE) $^ $(LIBS_$*)
ln -f -s $@.$(LIB_RELEASE) $@
%.a: