summaryrefslogblamecommitdiffstats
path: root/Makefile
blob: 13b29b2dca3a39bb707b52b154581de57c27c77a (plain) (tree)
1
2
3
4
5
6
7
8
9





                      
                
                   
               




                
          




                                               
             

                                     
              

                                                  

                                                    

          

                                                       


                                                                          
                       




                                   
.POSIX:

CONFIGFILE = config.mk
include $(CONFIGFILE)

OBJ =\
	makel.o\
	makefile.o\
	text.o\
	ui.o

HDR =\
	common.h

all: makel
$(OBJ): $(HDR)

.c.o:
	$(CC) -c -o $@ $< $(CFLAGS) $(CPPFLAGS)

makel: $(OBJ)
	$(CC) -o $@ $(OBJ) $(LDFLAGS)

install: makel
	mkdir -p -- "$(DESTDIR)$(PREFIX)/bin"
	mkdir -p -- "$(DESTDIR)$(MANPREFIX)/man1/"
	cp -- makel "$(DESTDIR)$(PREFIX)/bin/"
	cp -- makel.1 "$(DESTDIR)$(MANPREFIX)/man1/"

uninstall:
	-rm -f -- "$(DESTDIR)$(PREFIX)/bin/makel"
	-rm -f -- "$(DESTDIR)$(MANPREFIX)/man1/makel.1"

clean:
	-rm -f -- *.o *.a *.lo *.su *.so *.so.* *.gch *.gcov *.gcno *.gcda
	-rm -f -- makel

.SUFFIXES:
.SUFFIXES: .o .c

.PHONY: all install uninstall clean