# http2email/Makefile # This file is part of Decimail; see http://decimail.org/ # (C) 2005-2006 Philip Endecott # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. default_target: compile EXECUTABLE=http2email LIBPBE_DIR=../libpbe CPP_FLAGS= GCC_FLAGS=-pthread GCC_FLAGS=-D_REENTRANT COMPILE_FLAGS=$(CPP_FLAGS) $(GCC_FLAGS) -Wall -O C_COMPILE_FLAGS=$(COMPILE_FLAGS) -std=gnu99 CC_COMPILE_FLAGS=$(COMPILE_FLAGS) LINK_FLAGS=$(ROTE_LIBS) \ -pthread \ -lboost_program_options \ -lboost_system \ -lrecode LIBPBE_MAKE_OPTIONS=DISABLE_POSTGRESQL=1 DISABLE_IMAGEMAGICK=1 include ../libpbe.mk C_SRCS=$(wildcard *.c) CC_SRCS=$(wildcard *.cc) OBJS=$(addsuffix .o,$(basename $(C_SRCS) $(CC_SRCS))) %.o: %.cc $(CXX) $(CC_COMPILE_FLAGS) -o $@ -c $< %.o: %.c $(CC) $(C_COMPILE_FLAGS) -o $@ -c $< compile: $(OBJS) $(LIBPBE_LIB) $(CXX) -o $(EXECUTABLE) $(OBJS) $(LINK_FLAGS) %.d: %.cc $(CXX) -MM -MG -MT $@ -MT $(<:%.cc=%.o) $(CPP_FLAGS) $(GCC_FLAGS) -o $@ $< %.d: %.c $(CC) -MM -MG -MT $@ -MT $(<:%.c=%.o) $(CPP_FLAGS) $(GCC_FLAGS) -o $@ $< DEPENDS=$(addsuffix .d,$(basename $(OBJS))) -include $(DEPENDS) clean: FORCE $(RM) -f *.o veryclean: clean $(RM) *.d install: install $(EXECUTABLE) /usr/local/sbin .PHONY: default_target compile install FORCE