VPATH	 = @srcdir@
srcdir   = @srcdir@

CC 	     = @CC@
CDEBUG_FLAGS = @CDEBUG_FLAGS@
CFLAGS	     = -I$(srcdir) -I../include -I$(srcdir)/../include @CFLAGS@ $(CDEBUG_FLAGS) @DEFS@
MAKED	     = @MAKED@
INSTALL	     = @INSTALL@
BINRM        = @BINRM@
LDFLAGS	     = @LDFLAGS@
LIBS	     = @LIBS@

SRCS = $(srcdir)/getserv.c $(srcdir)/connect.c $(srcdir)/accept.c $(srcdir)/pipe_otp.c

all: accept connect getserv pipe_otp

Makefile: Makefile.in ../config.status
	(cd ..; CONFIG_FILES=test/Makefile CONFIG_HEADERS= ./config.status)

accept: accept.o
	$(CC) $(CFLAGS) $(LDFLAGS) -o accept accept.o $(LIBS)

connect: connect.o
	$(CC) $(CFLAGS) $(LDFLAGS) -o connect connect.o $(LIBS)

getserv: getserv.o
	$(CC) $(CFLAGS) $(LDFLAGS) -o getserv getserv.o $(LIBS)

async2: async2.c
	$(CC) $(CFLAGS) $(LDFLAGS) -o async2 $(srcdir)/async2.c $(LIBS) 

pipe_otp: pipe_otp.c ../lib/libsocks5.a
	$(CC) $(CFLAGS) -I$(srcdir)/../lib $(LDFLAGS) -o pipe_otp $(srcdir)/pipe_otp.c ../lib/libsocks5.a $(LIBS)

install:
	echo "Files in test directory do get not installed"

clean:
	-$(BINRM) connect accept getserv pipe_otp *.o core

distclean: clean
	-$(BINRM) Makefile *~ #*# *.bak

depend: Makefile.nodepend $(SRCS)
	$(MAKED) -- $(CFLAGS) -- $(SRCS)

# DO NOT DELETE 

