1 ###############################################################################
2 # $Id: Makefile.in,v 1.28 2009/03/03 15:50:14 faust Exp $
3 ###############################################################################
5 include ../../Makefile.conf
7 PROG = lib$(LIB_NAME).a
9 SEARCH_DIRS = -I $(DIR_INCLUDE) -I . -I ./include
11 ifeq ($(STG_TIME), yes)
20 SEARCH_DIRS += $(LIB_INCS)
23 OBJS = $(notdir $(patsubst %.cpp, %.o, $(patsubst %.c, %.o, $(SRCS))))
25 #INST_INCS = $(addprefix $(DIR_INCLUDE)/, $(notdir $(INCS)))
26 #INST_LIBS = $(DIR_LIB)/lib$(LIB_NAME)
35 $(PROG): $(OBJS) $(STGLIBS)
36 ar rc lib$(LIB_NAME).a $(OBJS)
37 ranlib lib$(LIB_NAME).a
41 # cp -p $(INCS) $(DIR_INCLUDE)/stg
44 rm -f deps $(PROG) *.o *.a *.so tags *.*~
45 #for file in $(INCS); do \
46 # rm -f $(DIR_INCLUDE)/stg/$$file; \
50 mkdir -m $(DIR_MODE) -p $(PREFIX)/usr/lib/stg
51 install -m $(BIN_MODE) -o $(OWNER) -s $(PROG) $(PREFIX)/usr/lib/stg/$(PROG)
52 mkdir -m $(DIR_MODE) -p $(PREFIX)/usr/include/stg
53 install -m $(DATA_MODE) -o $(OWNER) $(INCS) $(PREFIX)/usr/include/stg/
56 rm -f $(PREFIX)/usr/lib/stg/$(PROG)
57 for file in $(INCS); do \
58 rm -f $(PREFIX)/usr/include/stg/$$file; \
61 ifneq ($(MAKECMDGOALS),includes)
62 ifneq ($(MAKECMDGOALS),clean)
63 ifneq ($(MAKECMDGOALS),uninstall)
69 deps: $(SRCS) ../../Makefile.conf
71 for file in $(SRCS); do\
72 echo "$$file" | grep ".c$$" > /dev/null;\
75 echo "`$(CC) $(CFLAGS) $(SEARCH_DIRS) $(DEFS) -MM $$file` Makefile ../../Makefile.conf" >> deps ;\
76 echo -e '\t$$(CC) $(CFLAGS) $(SEARCH_DIRS) $(DEFS) -c $$<' >> deps ;\
78 echo "`$(CXX) $(CXXFLAGS) $(SEARCH_DIRS) $(DEFS) -MM $$file` Makefile ../../Makefile.conf" >> deps ;\
79 echo -e '\t$$(CXX) $(CXXFLAGS) $(SEARCH_DIRS) $(DEFS) -c $$<' >> deps ;\