tapas

A small program used for compiling refer output into the APA reference format.
git clone git://git.noxz.tech/tapas
Log | Files | Refs | README | LICENSE

Makefile (1018B)


      1 .POSIX:
      2 
      3 include config.mk
      4 
      5 SRC = tapas.c
      6 OBJ = $(SRC:.c=.o)
      7 
      8 all: options tapas
      9 
     10 options:
     11 	@echo tapas build options:
     12 	@echo "VERSION = $(VERSION)"
     13 	@echo "CFLAGS  = $(STCFLAGS)"
     14 	@echo "LDFLAGS = $(STLDFLAGS)"
     15 	@echo "CC      = $(CC)"
     16 
     17 .c.o:
     18 	@echo CC $<
     19 	@$(CC) $(STCFLAGS) -c $<
     20 
     21 ${OBJ}: config.h config.mk
     22 
     23 config.h:
     24 	@echo creating $@ from config.def.h
     25 	@cp config.def.h $@
     26 
     27 tapas: $(OBJ)
     28 	@echo CC -o $@
     29 	@$(CC) -o $@ $(OBJ) $(STLDFLAGS)
     30 
     31 clean:
     32 	@echo cleaning
     33 	@rm -f tapas $(OBJ)
     34 
     35 install: tapas
     36 	@echo installing executables to ${PREFIX}/bin
     37 	@mkdir -p ${PREFIX}/bin
     38 	@cp -f tapas ${PREFIX}/bin
     39 	@chmod 755 ${PREFIX}/bin/tapas
     40 #	@echo installing manual page to ${MANPREFIX}/man1
     41 #	@mkdir -p ${MANPREFIX}/man1
     42 #	@cp -f tapas.1 ${MANPREFIX}/man1
     43 #	@chmod 644 ${MANPREFIX}/man1/tapas.1
     44 
     45 uninstall:
     46 	@echo removing executable files from ${PREFIX}/bin
     47 	@rm -f ${PREFIX}/bin/tapas
     48 #	@echo removing manual page from ${MANPREFIX}/man1
     49 #	@rm -f ${MANPREFIX}/man1/tapas.1
     50 
     51 .PHONY: all options clean install uninstall