##################################################################
#   Copyright  2004, Sebastian Heutling. All rights reserved.
#   $Id: Makefile,v 1.13 2004/11/05 23:07:51 basti Exp $
#
#   Descr. : Makefile for the daemon
#   Authors: Sebastian Heutling, sheutlin@gmx.de
##################################################################
TOP     :=../
include $(TOP)/config/make.tmpl
include $(TOP)/config/make.cfg
LD=$(CXX)
FILES   := pluginretrieve

EXE      := pluginretrieve
OBJECTS  :=$(foreach f, $(FILES), .$(f).o)
DEPENDS  := $(foreach f, $(FILES), .$(f).d)

INCLUDES := -I$(TOP)/server/include
CXXFLAGS += $(INCLUDES) $(DEFINES) -g -O0
LDLIBS   := -ldl -lstdc++ -lxerces-c
LDFLAGS  := $(LDLIBS)

.PHONY: all

all: $(EXE)
	@$(call multimake,$(subdirs))

#WARNINGWARNINGWARNINGWARNINGWARNINGWARNINGWARNINGWARNINGWARNING
# remove this if GNU's make is finally fixed!
#$(EXE): $(OBJECTS)
#WARNINGWARNINGWARNINGWARNINGWARNINGWARNINGWARNINGWARNINGWARNING
$(eval $(call link,$(EXE),$(OBJECTS),$(LDFLAGS)))
$(eval $(call compile_source,cpp,Makefile,$(CXXFLAGS)))
$(eval $(call build_depends,cpp,Makefile,$(CXXFLAGS)))
$(eval $(call clean,$(subdirs),$(cleanobjects)))
$(eval $(call distclean,$(subdirs),$(cleanobjects)))

ifeq (,$(filter clean distclean depend install,$(MAKECMDGOALS)))
-include $(DEPENDS)
endif

