# -*- Makefile -*-
#----------------------------------------------------------------------------
#       GNU Makefile
#
# @file GNUmakefile.Service_Config_DLL
#
# gnu.mpd,v 1.95 2004/07/01 19:00:58 elliott_c Exp
#
# This file was automatically generated by MPC.  Any changes made directly to
# this file will be lost the next time it is generated.
#
#----------------------------------------------------------------------------
MAKEFILE         = GNUmakefile.Service_Config_DLL
DEPENDENCY_FILE  = .depend.Service_Config_DLL

## LIB may be set to empty later on in this file
LIB_UNCHECKED    = libService_Config_DLL.a
LIB              = $(LIB_UNCHECKED)

## SHLIB may be set to empty later on in this file
SHLIB_UNCHECKED  = libService_Config_DLL.$(SOEXT)
SHLIB            = $(SHLIB_UNCHECKED)

FILES = \
  Service_Config_DLL

#----------------------------------------------------------------------------
#       Include macros and targets
#----------------------------------------------------------------------------
ACE_SHLIBS = -lACE

include $(ACE_ROOT)/include/makeinclude/wrapper_macros.GNU
## We don't need the ACELIB setting from wrapper_macros.GNU
ACELIB =

# To build multiple targets in the same directory on AIX, it works
# best to have a template directory per project.
# The compiler/linker isn't too smart about instantiating templates...
ifdef TEMPINCDIR
TEMPINCDIR := $(TEMPINCDIR)/Service_Config_DLL

all: $(TEMPINCDIR)

endif

INSLIB ?= ../lib
ifeq ($(INSLIB),.)
  ifeq ($(PWD),)
    PWD=$(shell pwd)
  endif
  INSLIB = $(PWD)
endif
OUTPUT_DIRECTORY = $(INSLIB)
all: $(OUTPUT_DIRECTORY)

$(OUTPUT_DIRECTORY):
	-@mkdir -p "$(OUTPUT_DIRECTORY)"

# turn off libcheck if doing a dry run
ifeq ($(findstring n, $(MAKEFLAGS)),n)
  LIBCHECK = 1
else
  # turn off libcheck if keep going was passed too
  ifeq ($(findstring k, $(MAKEFLAGS)),k)
    LIBCHECK = 1
  else
    LIBCHECK ?= $(filter-out $(foreach lib,ACE,$(findstring $(lib),$(foreach libpath,../lib $(INSLIB),$(wildcard $(libpath)/lib$(lib).* $(libpath)/$(lib).lib)))),ACE)
    ifeq ($(LIBCHECK),)
      LIBCHECK = 1
    endif
  endif
endif
ifneq ($(LIBCHECK), 1)
  LIB   =
  SHLIB =
  all: lib_warning
endif

ifneq (,$(RC))
  FILES += $(RESOURCES)
endif

LSRC   = $(addsuffix .cpp, $(FILES))

include $(ACE_ROOT)/include/makeinclude/macros.GNU
include $(ACE_ROOT)/include/makeinclude/rules.common.GNU
include $(ACE_ROOT)/include/makeinclude/rules.nonested.GNU
include $(ACE_ROOT)/include/makeinclude/rules.lib.GNU
include $(ACE_ROOT)/include/makeinclude/rules.local.GNU

LDFLAGS      += -L../lib
CPPFLAGS     += -I..
ifeq ($(shared_libs),1)
  ifneq ($(SHLIB),)
    CPPFLAGS += -DSERVICE_CONFIG_DLL_BUILD_DLL
  endif
endif
ifeq ($(static_libs),1)
  CPPFLAGS += -DACE_AS_STATIC_LIBS
endif

#----------------------------------------------------------------------------
#       Local targets
#----------------------------------------------------------------------------
lib_warning:
	@echo This project will not be built due to the following missing library:
	@echo $(LIBCHECK)


realclean: clean
ifneq ($(GENERATED_DIRTY),)
	-$(RM) -r $(GENERATED_DIRTY)
endif

