adx: remove useless comments
[libav.git] / common.mak
... / ...
CommitLineData
1#
2# common bits used by all libraries
3#
4
5# first so "all" becomes default target
6all: all-yes
7
8OBJS-$(HAVE_MMX) += $(MMX-OBJS-yes)
9
10OBJS += $(OBJS-yes)
11FFLIBS := $(FFLIBS-yes) $(FFLIBS)
12TESTPROGS += $(TESTPROGS-yes)
13
14FFEXTRALIBS := $(FFLIBS:%=-l%$(BUILDSUF)) $(EXTRALIBS)
15
16EXAMPLES := $(EXAMPLES:%=$(SUBDIR)%-example$(EXESUF))
17OBJS := $(sort $(OBJS:%=$(SUBDIR)%))
18TESTOBJS := $(TESTOBJS:%=$(SUBDIR)%) $(TESTPROGS:%=$(SUBDIR)%-test.o)
19TESTPROGS := $(TESTPROGS:%=$(SUBDIR)%-test$(EXESUF))
20HOSTOBJS := $(HOSTPROGS:%=$(SUBDIR)%.o)
21HOSTPROGS := $(HOSTPROGS:%=$(SUBDIR)%$(HOSTEXESUF))
22TOOLS += $(TOOLS-yes)
23TOOLOBJS := $(TOOLS:%=tools/%.o)
24TOOLS := $(TOOLS:%=tools/%$(EXESUF))
25
26DEP_LIBS := $(foreach NAME,$(FFLIBS),lib$(NAME)/$($(CONFIG_SHARED:yes=S)LIBNAME))
27
28ALLHEADERS := $(subst $(SRC_DIR)/,$(SUBDIR),$(wildcard $(SRC_DIR)/*.h $(SRC_DIR)/$(ARCH)/*.h))
29SKIPHEADERS += $(ARCH_HEADERS:%=$(ARCH)/%) $(SKIPHEADERS-)
30SKIPHEADERS := $(SKIPHEADERS:%=$(SUBDIR)%)
31checkheaders: $(filter-out $(SKIPHEADERS:.h=.ho),$(ALLHEADERS:.h=.ho))
32
33alltools: $(TOOLS)
34
35$(HOSTOBJS): %.o: %.c
36 $(HOSTCC) $(HOSTCFLAGS) -c -o $@ $<
37
38$(HOSTPROGS): %$(HOSTEXESUF): %.o
39 $(HOSTCC) $(HOSTLDFLAGS) -o $@ $< $(HOSTLIBS)
40
41$(OBJS): | $(sort $(dir $(OBJS)))
42$(HOSTOBJS): | $(sort $(dir $(HOSTOBJS)))
43$(TESTOBJS): | $(sort $(dir $(TESTOBJS)))
44$(TOOLOBJS): | tools
45
46OBJDIRS := $(OBJDIRS) $(dir $(OBJS) $(HOSTOBJS) $(TESTOBJS))
47
48CLEANSUFFIXES = *.d *.o *~ *.ho *.map *.ver
49DISTCLEANSUFFIXES = *.pc
50LIBSUFFIXES = *.a *.lib *.so *.so.* *.dylib *.dll *.def *.dll.a *.exp
51
52-include $(wildcard $(OBJS:.o=.d) $(TESTOBJS:.o=.d))