######################################################################
#
#	$Id: Makefile,v 1.7 2007/02/14 18:24:16 pkrawitz Exp $
#
#    Child Makefile used to build the POSIX library.
#
######################################################################

# Root directory for netos.
BASEDIR=../..

# Include the parent makefile.
all: localall
-include $(BASEDIR)/Makefile.inc

# Add stuff here for additional cleanup
localclean: clean_my_objs

component_clobber: clean_my_libs

# Location of object files.
OBJS = ./objs/$(PROCESSOR)/$(ENDIANDIR)/$(TOOLSET)

#
# The list of source directories.
#
SRCDIR=$(BASEDIR)/src/posix

#
# The name and path of the library to be built.
#
ifeq ($(DEBUG), on)
LOCAL_LIB = $(BASEDIR)/$(LIBDIR)/libposixdbg.a
else
LOCAL_LIB = $(BASEDIR)/$(LIBDIR)/libposix.a
endif


#
# Search path for source header files, specific to this library
#
INCDIRS += -I./../../h -I./../../h/threadx -I./../../h/tcpip -I ./../../src/bsp/customize

ifeq '$(TOOLSET)' 'ghs'
INCDIRS	+= -Ic:/ghs/arm361/ansi
endif

#
# List of C object files for this library.
#
C_OBJ=	$(OBJS)/posqueue.o\
	$(OBJS)/posix_semaphore.o\
	$(OBJS)/posix_thread.o\
	$(OBJS)/posix_time.o

#
# List of C++ object files.
#
CC_OBJ=

#
# List of assembly object files.
#
S_OBJ=	

#
# Any extra compilier flags.
#
MY_CFLAGS =

#
# Any extra defines go here
#
MY_DEFINES =

ifeq '$(TOOLSET)' 'gnu'
MY_DEFINES = -D_POSIX_SOURCE
endif

-include $(BASEDIR)/Makefile.bld


