"Fossies" - the Fresh Open Source Software Archive

Member "imapfilter-2.8.2/src/Makefile" (26 Dec 2023, 2124 Bytes) of package /linux/privat/imapfilter-2.8.2.tar.gz:


As a special service "Fossies" has tried to format the requested text file into HTML format (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file. See also the last Fossies "Diffs" side-by-side code changes report for "Makefile": 2.7.5_vs_2.7.6.

    1 DESTDIR ?=
    2 PREFIX ?= /usr/local
    3 BINDIR = $(PREFIX)/bin
    4 SHAREDIR = $(PREFIX)/share/imapfilter
    5 MANDIR = $(PREFIX)/man
    6 
    7 SSLCAPATH = /etc/ssl/certs
    8 SSLCAFILE = /etc/ssl/cert.pem
    9 
   10 MYCFLAGS =
   11 MYLDFLAGS =
   12 MYLIBS =
   13 
   14 INCDIRS =
   15 LIBDIRS =
   16 
   17 LIBLUA = -llua
   18 LIBPCRE = -lpcre2-8
   19 LIBSSL = -lssl
   20 LIBCRYPTO = -lcrypto
   21 
   22 CFLAGS = -Wall -Wextra -O \
   23 	 -DCONFIG_SHAREDIR='"$(SHAREDIR)"' \
   24 	 -DCONFIG_SSL_CAPATH='"$(SSLCAPATH)"' \
   25 	 -DCONFIG_SSL_CAFILE='"$(SSLCAFILE)"' \
   26 	 $(INCDIRS) $(MYCFLAGS)
   27 LDFLAGS = $(LIBDIRS) $(MYLDFLAGS)
   28 LIBS = -lm -ldl $(LIBLUA) $(LIBPCRE) $(LIBSSL) $(LIBCRYPTO) $(MYLIBS)
   29 
   30 MAN1 = imapfilter.1
   31 MAN5 = imapfilter_config.5
   32 
   33 LUA = common.lua set.lua regex.lua account.lua mailbox.lua message.lua \
   34       options.lua auxiliary.lua
   35 
   36 BIN = imapfilter
   37 OBJ = buffer.o cert.o core.o file.o imapfilter.o list.o log.o lua.o \
   38       memory.o misc.o namespace.o pcre.o regexp.o request.o response.o \
   39       session.o signal.o socket.o system.o
   40 
   41 all: $(BIN)
   42 
   43 $(BIN): $(OBJ)
   44 	$(CC) -o $(BIN) $(LDFLAGS) $(OBJ) $(LIBS)
   45 
   46 $(OBJ): imapfilter.h
   47 buffer.o: buffer.h 
   48 cert.o: pathnames.h session.h
   49 file.o: pathnames.h
   50 imapfilter.o: buffer.h list.h pathnames.h regexp.h session.h version.h
   51 list.o: list.h
   52 log.o: list.h pathnames.h session.h
   53 lua.o: pathnames.h
   54 namespace.o: buffer.h 
   55 regexp.o: regexp.h
   56 request.o: buffer.h session.h
   57 response.o: buffer.h regexp.h session.h
   58 session.o: list.h session.h
   59 socket.o: session.h
   60 
   61 install: $(BIN)
   62 	mkdir -p $(DESTDIR)$(BINDIR) && \
   63 	cp -f $(BIN) $(DESTDIR)$(BINDIR) && \
   64 	chmod 0755 $(DESTDIR)$(BINDIR)/$(BIN)
   65 	mkdir -p $(DESTDIR)$(SHAREDIR) && \
   66 	cp -f $(LUA) $(DESTDIR)$(SHAREDIR) && \
   67 	chmod 0644 $(DESTDIR)$(SHAREDIR)/$(LUA)
   68 	mkdir -p $(DESTDIR)$(MANDIR)/man1 && \
   69 	cp -f ../doc/$(MAN1) $(DESTDIR)$(MANDIR)/man1 && \
   70 	chmod 0644 $(DESTDIR)$(MANDIR)/man1/$(MAN1)
   71 	mkdir -p $(DESTDIR)$(MANDIR)/man5 && \
   72 	cp -f ../doc/$(MAN5) $(DESTDIR)$(MANDIR)/man5 && \
   73 	chmod 0644 $(DESTDIR)$(MANDIR)/man5/$(MAN5)
   74 
   75 uninstall:
   76 	rm -f $(DESTDIR)$(BINDIR)/$(BIN)
   77 	cd $(DESTDIR)$(SHAREDIR) && rm -f $(LUA)
   78 	rm -f $(DESTDIR)$(MANDIR)/man1/$(MAN1)
   79 	rm -f $(DESTDIR)$(MANDIR)/man5/$(MAN5)
   80 
   81 clean:
   82 	rm -f $(OBJ) $(BIN) *~