ARCH        = OS
SHOBJ       = YES

include $(CDEV)/extensions/cdevGenericServer/include/makeinclude/Makefile.$(ARCH)

APPNAME     = "CDEV CLIP Client/Service"
CXXINCLUDES = -I./

# ******************************************************************************
# * The BINARIES definition names all of the binary files that should be deleted
# * whenever "make clean" is executed.
# ******************************************************************************
BINARIES    = $(BASELIB)/libCLIPService.a \
              $(BASELIB)/CLIPService.so 

ifeq ($(SHOBJ), YES)
        LIBS    = -L$(CDEVLIB) -lcdevGenericServer $(CDEVLIBS) $(OSLIBS)
	TARGETS = $(BASELIB)/CLIPService.so
else
        LIBS    = -L$(CDEVLIB) -lcdevGenericServer $(CDEVLIBS) $(OSLIBS)
	TARGETS = $(BASELIB)/libCLIPService.a
endif

targets : $(TARGETS)
		
$(BASELIB)/CLIPService.so : $(OBJDIR)/CLIPService.o $(OBJDIR)/CLIPRequestObject.o
	$(LINK.so) -o $@ $^ -L$(CDEVLIB) -lcdevGenericServer $(NETLIBS)
	@mkdir -p $(CDEVSHOBJ)/$(CDEVVERSION)
	@cp $@ $(CDEVSHOBJ)/$(CDEVVERSION)/$(@F)
	
