#!/usr/bin/make

#####################################################################
#                                                                   #
# This file is free software; you can redistribute it and/or        #
# modify it under the terms of the GNU Library General Public       #
# License as published by the Free Software Foundation; either      #
# version 2 of the License, or (at your option) any later version.  #
#                                                                   #
# This library is distributed in the hope that it will be useful,   #
# but WITHOUT ANY WARRANTY; without even the implied warranty of    #
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU #
# Library General Public License for more details.                  #
#                                                                   #
# You should have received a copy of the GNU Library General Public #
# License along with this library; if not, write to the             #
# Free Software Foundation, Inc., 59 Temple Place - Suite 330,      #
# Boston, MA 02111-1307, USA.                                       #
#                                                                   #
#####################################################################
# This Makefile was writen by Alex Scott (magister@kfa.cx)
# This is for non-library programs.
#####################################################################

#define this to = 1 when compiling on Solaris 2.5 or 2.5.1
# Valid targets are:
# Linux - Linux/Intel
# NT/Unix - NTU
# SOLARIS25 - Solaris/Sparc 2.5/2.5.1
# SOLARIS   - Solaris/Sparc 2.6 or newer
#OSTARGET=NTU  (Cygwin on NT)
OSTARGET=LINUX

ifeq (Makefile.inc,$(wildcard Makefile.inc))
  include Makefile.inc
  CONFIGURED=yes
endif
TESTBIN=$(shell sh -c 'ls /usr/bin/test | grep -v "ls:"')
ifeq ($(TESTBIN), "")
  TESTBIN=/bin/test
endif

########################
# Program info goes here
# ONLY USE ONE DEBUGGIN STRATEGY AT A TIME:  DMALLOC, MEMWATCH, EFENCE
DEBUG=-1
PROFILE=0
DMALLOC=0
MEMWATCH=0
EFENCE=0
LANG_DEBUG=0
OPTIMIZE=0
STATIC=0
prefix=$(shell sh -c 'if $(TESTBIN) -n "$(DESTDIR)"; then echo "$(DESTDIR)"; else echo "/usr/local"; fi')
PROGRAM=tradeclient
MAJOR=0
MINOR=9
BUILD=0
COMPCOUNTFILE=/tmp/$(PROGRAM)$(MAJOR).$(MINOR).$(BUILD).compile.count
COMPILECOUNT=$(shell sh -c 'cat $(COMPCOUNTFILE)')
#VERSION="$(MAJOR).$(MINOR).$(BUILD)-$(COMPILECOUNT)"
VERSION="$(MAJOR).$(MINOR).$(BUILD)"
NEWMAILBACKEND=0
WANTLDAP=1
LDAP_CACHE=0
WANTSSL=0

######################################
# you shouldn't need to edit these ones
DATE=$(shell sh -c 'date +%Y%m%d')
USERID=$(shell sh -c 'set | grep EUID | cut -d = -f 2')
BASEDIR=$(shell 'pwd')

##############################################################
# Stuff needed for 'make bindist' mainly OS and processor info
OS=$(shell sh -c 'uname -s')
PROC=$(shell sh -c 'uname -m')
LIBC=$(shell sh -c 'ls -ad /lib/libc.so*')
LIBCVER=$(shell sh -c "basename $(LIBC) | sed 's/[A-Za-z.]//g'")
ifeq ($(OS), Linux)
  LINUXLIBC=-libc$(LIBCVER)
endif

##############################################################
# you probably don't need to edit these either unless you like 
# it arranged differently
SNAP=$(PROGRAM)-$(DATE)
DIST=$(PROGRAM)-$(VERSION)
BINDISTB=$(PROGRAM)-$(VERSION)-$(OS)-$(PROC)$(LINUXLIBC)
SNAPDIR=$(BASEDIR)/$(SNAP)
DISTDIR=$(BASEDIR)/$(DIST)
BINDISTDIR=$(BASEDIR)/$(BINDIST)
IMAPDIR=$(BASEDIR)/imap
IMAPVER=4.7c
IMAPFILE=$(BASEDIR)/imap-$(IMAPVER).tar.Z
PATCH=/usr/bin/patch -p0 -N
PATCHDIR=$(BASEDIR)/patches
C-CLIENT-PATCH=$(PATCHDIR)/c-client-4.7.patch

# This defines the target that will be made in the imap tree.
# for Intel linux, use 'slx'.  See the IMAP tree for other
# platforms.
ifeq ($(OSTARGET), LINUX)
	IMAPTARGET=slx
endif
ifeq ($(OSTARGET), SOLARIS25)
	IMAPTARGET=gso
endif
ifeq ($(OSTARGET), SOLARIS)
	IMAPTARGET=gso
endif

###############################################################
# Where the sources, includes and document are located in your
# source tree. Leave DOCDIR blank if you dont have one.
SRCDIR=$(BASEDIR)/src
INCLUDE=-I$(BASEDIR)/include -I$(BASEDIR)/c-client
INCLUDEDIR=$(BASEDIR)/include
DOCDIR=$(BASEDIR)/doc

##############################################################
# If you wrote demos or utilities and put them in subdirectory
# put thier names here. executed by  "make utils"
SUBDIRS=

###################################################################
# What dir's to clean when running "make clean" or "make distclean"
CLEANDIRS=$(SUBDIRS) $(SRCDIR)

#####################################################################
# All dirs that you want to include in the distrubiution or snapshot
# usualy its all the CLEANDIRS (includes SUBDIRS) but incase you have
# any more spefiy them here
ALLDIRS=$(CLEANDIRS) $(INCLUDEDIR) $(DOCDIR) $(BASEDIR)/pics $(PATCHDIR)

######################################################
# where the lib files and .h files are to be installed
PROGRAMINSTALLDIR=$(prefix)/bin
DOCINSTALLDIR=$(prefix)/doc/$(PROGRAM)

##########################################
# for pictures and shared program info
OTHERINSTALLDIR=$(prefix)/share/$(PROGRAM)

###########################################################
# the files to install to OTHERINSTALLDIR
OTHERINSTALLFILES=

###########################################################
# where it may have been installed, used by uninstall-more
KNOWNPREFIXES=/usr /usr/local

########################################################################
# when doing a make dist or make snap what files do you want copied into
# the tar.gz
FILESTOSAVE=\
	COPYING \
	CHANGELOG \
	README \
	Makefile \
	$(IMAPFILE) \
	$(ALLDIRS)
BINFILESTOSAVE=\
	COPYING\
	CHANGELOG \
	README \
	Makefile \
	$(PROGRAM)

#################################################
# Compiler and your library spefic options go here
CC=gcc
DEFINES=-DVERSION=\"$(VERSION)\"
COPTIONS=-Wall $(DEFINES) $(OPTCFLAGS)

ifeq ($OSTARGET), LINUX)
	DEFINES+=-DLINUX
endif

ifeq ($(OSTARGET), SOLARIS25)
	DEFINES+=-DSOLARIS25
endif

ifeq ($(OSTARGET), SOLARIS)
	DEFINES+=-DSOLARIS
endif

ifeq ($(STATIC), 1)
	CFLAGS+=-static
	BINDIST=$(BINDISTB)-static
else
	BINDIST=$(BINDISTB)-dyn
endif
ifeq ($(DEBUG),-1)
	CFLAGS+=$(COPTIONS) -O3 -pipe
else
	CFLAGS+=$(COPTIONS) -g3 -pipe
	DEFINES+=-DDEBUG=$(DEBUG)
endif
ifeq ($(PROFILE), 1)
	CFLAGS+= -pg -DPROFILE
endif

# Only offer serious optimizations when running on Intel/gcc and not sparc
# This should ONLY be used on 686 class or better machines and this will
# only work with the OSTARGET is LINUX.  This way, we're not trying to
# generate pentiumpro optimizations on a sparc boxen. 
ifeq ($(OSTARGET), LINUX)
	ifeq ($(OPTIMIZE), 1)
		CFLAGS+=-mpentiumpro -mcpu=pentiumpro -march=pentiumpro
	else
		CFLAGS+=-m486
	endif
endif

ifeq ($(LANG_DEBUG), 1)
  CFLAGS+=$(COPTIONS) -DLANG_DEBUG
endif
LIBS=$(OPTLIBS) $(shell sh -c 'gtk-config --libs') $(BASEDIR)/c-client/c-client.a -lcrypt
INCLUDES=$(INCLUDE) $(shell sh -c 'gtk-config --cflags')

# See if electric fence support is required
ifeq ($(EFENCE), 1)
	LIBS+= -lefence
endif

ifeq ($(DMALLOC), 1)
	LIBS+= -ldmalloc
	DEFINES+=-DDMALLOC
endif

ifneq ($(MEMWATCH),0)
  OBJECTS+=memwatch.o
  DEFINES+=-DMEMWATCH
endif

ifeq ($(WANTLDAP), 1)
	DEFINES+=-DWANTLDAP
	LIBS+= -lldap -llber 
	ifeq ($(LDAP_CACHE), 1)
		DEFINES+=-DLDAP_CACHE
	endif
endif

ifeq ($(WANTSSL), 1)
	DEFINES+=-DWANTSSL
	LIBS+= -lcrypto -lssl
endif

ifeq ($(NEWMAILBACKEND), 1)
	DEFINES+=-DNEWMAILBACKEND
endif

# below is for makedepend
ALLINCLUDES=-I/usr/include/linux $(INCLUDES)\
	$(shell sh -c 'gtk-config --cflags')

###########################################################################
# objects that make up your libaray, you dont have to spefiy the .c or cpp
# file cause it test to see if it exist, i havent implemented .cc files
# but it would not be hard. what happens is it takes off the .o extention
# replaces it with .c test to see if it exist if not it checks if its a
# .cpp file, if neather exist it exits, simple enuff.
OBJECTS=\
	abook-callbacks.o \
	abook-loadsave.o \
	abook-opts.o \
	abook-window.o \
	calender-callbacks.o \
	calender-loadsave.o \
	calender-opts.o \
	calender-window.o \
	callbacks.o \
	clipboard.o \
	conv.o \
	dialogs.o \
	digest-window.o \
	file-selector-callbacks.o \
	file-selector-window.o \
	filter-callbacks.o \
	filter-opts.o \
	filter-windows.o \
	folder-opts.o \
	forking.o \
	gcalendar.o \
	hashtime.o \
	imap-window.o \
	imap-window-callbacks.o \
	ipc.o \
	ipc-proxy.o \
	lang-support.o \
	mail-loadsave.o \
	main.o \
	main-window-callbacks.o \
	main-window.o \
	message-callbacks.o \
	message-fun.o \
	message-window.o \
	mime.o \
	mm.o \
	msearch.o \
	netfolders.o \
	new-folder.o \
	new-message-callbacks.o \
	new-message.o \
	new-message-window.o \
	parser.o \
	pipe.o \
	pixmap.o \
	pop3smtp.o \
	pref-loadsave.o \
	pref-windows-callbacks.o \
	pref-windows.o \
	print.o \
	schedule-widget.o \
	spelling-callbacks.o \
	spelling.o \
	spelling-window.o \
	status-callbacks.o \
	status.o \
	status-window.o\
	support.o \
	tcal.o \
	tcldap.o


# For if you wish to use memwatch (you must supply the .c and .h files)
# make sure you set MEMWATCH to non-0 at the top.
ifneq ($(MEMWATCH),0)
  OBJECTS+=memwatch.o
  DEFINES+=-DMEMWATCH
endif


########################################################
# Variables we want to give Makefile's in subdirectorys
# this is so the other make files can be skeletons
SUBMAKEALL=\
	PROGRAM='$(PROGRAM)'\
	MAJOR='$(MAJOR)'\
	MINOR='$(MINOR)'\
	BUILD='$(BUILD)'\
	VERSION='$(VERSION)'\
	DATE='$(DATE)'\
	USERID='$(USERID)'\
	BASEDIR='$(BASEDIR)'\
	SRCDIR='$(SRCDIR)'\
	INCLUDE='$(INCLUDE)'\
	CC='$(CC)'\
	CFLAGS='$(CFLAGS)'\
	DEFINES='$(DEFINES)'\
	LIBS='$(LIBS)'\
	INCLUDES='$(INCLUDES)'\
	ALLINCLUDES='$(ALLINCLUDES)'\
	OBJECTS='$(OBJECTS)'

############################################################################
# Hope fuly you dont need to edit anyt thing past this point, but if you see
# something down here that dosnt work on your system, then fixit (in ya know
# how) and send me a note <magister@kfa.cx>. Ive tryed to make it as smart
# as i could so we wouldnt need a configure script :).
#******** The makefile should be a dependant.  That way, when it changes,
#******** everything gets recompiled.
############################################################################

.SUFFIXES : .cpp .c

.cpp.o :
	$(CC) $(OPTIONS) $(INCLUDES) -c $<

.c.o :
	$(CC) $(OPTIONS) $(INCLUDES) -c $<

all : $(PROGRAM)

$(PROGRAM) : c-client.a compilecount
	@$(MAKE) -C $(SRCDIR) $(SUBMAKEALL)
	@if $(TESTBIN) "$(DEBUG)" = "-1" ; then \
	  if $(TESTBIN) -e /usr/bin/strip ; then \
	    /usr/bin/strip $(BASEDIR)/$(PROGRAM); \
	  fi \
	fi

ifeq (Makefile.conf,$(wildcard Makefile.conf))
  include Makefile.conf
endif

depend :
	$(MAKE) depend -C $(SRCDIR) $(SUBMAKEALL)

compilecount :
	@# a build counter wanted by Deimos, only tempoary
	@# Mesures all complete and incomplete builds
	@if $(TESTBIN) ! -e $(COMPCOUNTFILE) ; then \
	  echo "the compile cound file does not exist or was deleted, makeing a new one."; \
	  echo "1" > $(COMPCOUNTFILE); \
	else \
	  oldc=`cat  $(COMPCOUNTFILE)`; \
	  let newc=$$oldc+1; \
	  echo "$$newc" >  $(COMPCOUNTFILE); \
	  echo "Current number of builds: $$newc"; \
	fi

numofbuilds :
	@# Its easer to refrance vars when wraped in an if
	@if $(TESTBIN) -e  $(COMPCOUNTFILE) ; then \
	  numofbuilds=`cat  $(COMPCOUNTFILE)`; \
	  echo "Currently at $$numofbuilds builds for $(PROGRAM)"; \
	else \
	  echo "No build history, maby you deleted  $(COMPCOUNTFILE) since you last compile"; \
	fi

dist : distclean 
	cd $(BASEDIR)
	rm -Rf $(DIST)
	mkdir $(DIST)
	cp -pr $(FILESTOSAVE) $(DISTDIR)
	$(MAKE) cvsclean
	tar -cf $(DIST).tar $(DIST)
	gzip -9 $(DIST).tar
	rm -Rf $(DIST)

bindist : all
	cd $(BASEDIR)
	rm -Rf $(BINDIST)
	mkdir $(BINDIST)
	cp -pr $(BINFILESTOSAVE) $(BINDISTDIR)
	$(MAKE) cvsclean
	tar -cf $(BINDIST).tar $(BINDIST)
	gzip -9 $(BINDIST).tar
	rm -Rf $(BINDIST)

snap : distclean
	cd $(BASEDIR)
	rm -Rf $(PROGRAM)
	mkdir $(PROGRAM)
	cp -dpr $(FILESTOSAVE) $(PROGRAM)
	$(MAKE) cvsclean
	tar -cf $(SNAP).tar $(PROGRAM)
	gzip -9 $(SNAP).tar
	rm -Rf $(PROGRAM)

# this is only for making a distrubution with out the CVS directorys
cvsclean :
	@echo "***** Removing the CVS directorys *****"
	@if $(TESTBIN) -d $(BASEDIR)/$(PROGRAM) ; then\
	 cd $(BASEDIR)/$(PROGRAM);\
	 files=`find`;\
	 touch temp.dirs;\
	 for dir in $$files; do\
	  if $(TESTBIN) -d $$dir ; then\
	   echo $$dir >> temp.dirs;\
	  fi;\
	 done;\
	 dirs=`cat temp.dirs | grep CVS`;\
	 rm -f temp.dirs;\
	 for directory in $$dirs; do\
	  if $(TESTBIN) -d $(BASEDIR)/$(PROGRAM)/$$directory ; then\
	   rm -Rf $(BASEDIR)/$(PROGRAM)/$$directory;\
	  fi;\
	 done;\
	else \
	 if $(TESTBIN) -d $(BASEDIR)/$(DIST) ; then\
	  cd $(BASEDIR)/$(DIST);\
	  files=`find`;\
	  touch temp.dirs;\
	  for dir in $$files; do\
	   if $(TESTBIN) -d $$dir ; then\
	    echo $$dir >> temp.dirs;\
	   fi;\
	  done;\
	  dirs=`cat temp.dirs | grep CVS`;\
	  rm -f temp.dirs;\
	  for directory in $$dirs; do\
	   if $(TESTBIN) -d $(BASEDIR)/$(DIST)/$$directory ; then\
	    rm -Rf $(BASEDIR)/$(DIST)/$$directory;\
	   fi;\
	  done;\
	 else\
	  if $(TESTBIN) -d $(BASEDIR)/$(BINDIST) ; then\
	   cd $(BASEDIR)/$(BINDIST);\
	   files=`find`;\
	   touch temp.dirs;\
	   for dir in $$files; do\
	    if $(TESTBIN) -d $$dir ; then\
	     echo $$dir >> temp.dirs;\
	    fi;\
	   done;\
	   dirs=`cat temp.dirs | grep CVS`;\
	   rm -f temp.dirs;\
	   for directory in $$dirs; do\
	    if $(TESTBIN) -d $(BASEDIR)/$(BINDIST)/$$directory ; then\
	     rm -Rf $(BASEDIR)/$(BINDIST)/$$directory;\
	    fi;\
	   done;\
	  fi;\
	 fi;\
	fi


love :
	@echo "Not war?"


distclean : clean imapclean
	rm -Rf Makefile.inc $(DIST)* $(PROGRAM)* $(PROGRAM)*.tar.* $(PATCHDIR)/*.patched
	@for dir in $(CLEANDIRS); do \
	  (cd $$dir ; $(MAKE) distclean); \
	done


clean :
	rm -Rf *.o *~ .*~ core DEADJOE .#*
	@for dir in $(CLEANDIRS); do \
	  (cd $$dir ; $(MAKE) clean); \
	done


imapclean:
	cd $(BASEDIR)/imap
	$(MAKE) -C $(IMAPDIR) clean


c-client.a:  c-client-link c-client-patch
	cd $(BASEDIR)/imap
	$(MAKE) -C $(IMAPDIR) $(IMAPTARGET)


c-client-link: imap-link
	@if $(TESTBIN) ! -L c-client ; then \
		ln -sf $(IMAPDIR)/c-client c-client ; \
	fi


imap-link: untar-imap
	@if $(TESTBIN) ! -L $(IMAPDIR) ; then \
		ln -sf imap-$(IMAPVER) $(IMAPDIR) ; \
	fi


untar-imap:
	@if $(TESTBIN) -d $(IMAPDIR) ; then \
		if $(TESTBIN) ! -L $(IMAPDIR) ; then \
			echo "Deleting old IMAP directory as it really should be a link!" ; \
			rm -rf $(IMAPDIR) ; \
		fi ; \
	fi
	@if $(TESTBIN) ! -d $(IMAPDIR)-$(IMAPVER) ; then \
		echo "Since we need to extract the c-client code, we'll do so now..." ; \
		gzip -dc $(IMAPFILE) | tar xfv - ; \
	fi


c-client-patch:
	cd $(IMAPDIR)-$(IMAPVER)/src/c-client
	@if $(TESTBIN) ! -f $(C-CLIENT-PATCH).patched ; then \
		echo "Patching C-Client version $(IMAPVER) source code..." ; \
		cat $(C-CLIENT-PATCH) | $(PATCH) ; \
		$(MAKE) $(C-CLIENT-PATCH).patched ; \
	fi ;


$(C-CLIENT-PATCH).patched:
	date > $(C-CLIENT-PATCH).patched


install :
	@if $(TESTBIN) ! -f $(BASEDIR)/$(PROGRAM) ; then \
	  echo "*** Warning Proceeding will cause the $(PROGRAM) ***";\
	  echo "***   To be owned by root, Wate 5 seconds to continue or ***"; \
	  echo "***   Ctrl-C to exit.                                    ***"; \
	  sleep 5;\
	  $(MAKE) all; \
	fi
	(cd $(BASEDIR) ; cp -dpRf $(PROGRAM) $(PROGRAMINSTALLDIR))
	@echo "****************************************************"
	@echo "The exec has been placed in $(PROGRAMINSTALLDIR)"
	@echo "****************************************************"
	@echo
	@if $(TESTBIN) -n "$(DOCINSTALLDIR)" ; then \
	  rm -Rf $(DOCINSTALLDIR); \
	  mkdir $(DOCINSTALLDIR); \
	  cp COPYING README $(DOCINSTALLDIR); \
	  if $(TESTBIN) -n "$(DOCDIR)" ; then \
	    cd "$(DOCDIR)"; \
	    cp -dpR * $(DOCINSTALLDIR); \
	  fi; \
	fi
	@echo "**********************************************"
	@echo "Documents have been placed in $(DOCINSTALLDIR)"
	@echo "**********************************************"
	@echo
	@if $(TESTBIN) -n "$(OTHERINSTALLDIR)" ; then \
	  rm -Rf $(OTHERINSTALLDIR); \
	  mkdir $(OTHERINSTALLDIR); \
	  for FILE in $(OTHERINSTALLFILES); do \
	    cp -dpR $$FILE $(OTHERINSTALLDIR); \
	  done; \
	fi
	@echo "*****************************************************"
	@echo "All other files needed to be installed were installed"
	@echo "to: $(OTHERINSTALLDIR)"
	@echo "*****************************************************"

uninstall-less : checkforroot
	@if $(TESTBIN) -z "$(OOW_UNINST_NODELAY)"; then \
	  echo "**** Uninstalling $(PROGRAM), any current or older versions in"; \
	  echo "**** '$(PROGRAMINSTALLDIR)'. This will remove just the binary"; \
	  echo "**** If you want the documentation and the extra files uninstalled"; \
	  echo "**** run 'make uninstall-more'"; \
	  echo " ** pausing for 5 seconds **"; \
	  sleep 5; \
	fi
	rm -fv $(PROGRAMINSTALLDIR)/$(PROGRAM)

uninstall-more : checkforroot
	@echo "**** Uninstalling current $(PROGRAM), Doc's, and Extra's (pics and config files)"
	@echo "**** Make sure you have not modifyed any of the files that were installed"
	@echo "**** Also make sure up have your settings in $(OTHERINSTALLDIR)"
	@echo "**** backed up, THEY WILL BE DELETED"
	@echo "**** If not press Enter, to uninstall. Ctrl-C to quit now."
	@read junk
	@echo "*** Locating and Removing $(PROGRAM) ***"
	@for directory in $(KNOWNPREFIXES); do \
	  if $(TESTBIN) -d $$directory ; then \
	    echo "Checking $$directory for installed $(PROGRAM) files"; \
	    if $(TESTBIN) -f $$directory/bin/$(PROGRAM) ; then \
	      rm -fv $$directory/bin/$(PROGRAM); \
	    fi; \
	    if $(TESTBIN) -d $$directory/doc/$(PROGRAM) ; then \
	      rm -fvr $$directory/doc/$(PROGRAM); \
	    fi; \
	    if $(TESTBIN) -d $$directory/share/$(PROGRAM) ; then \
	      rm -fvr $$directory/share/$(PROGRAM); \
	    fi; \
	  fi; \
	done

uninstall : uninstall-less
	@echo "*========--------uninstallation complet--------========*"

utils :
	@if $(TESTBIN) -n "$(SUBDIRS)"; then \
	  for dir in '$(SUBDIRS)'; do \
	    (cd $$dir ; $(MAKE)); \
	  done \
	fi

fixclockskew :
	find $(BASEDIR) -exec touch {} \;

checkforroot :
	@if $(TESTBIN) $(USERID) != 0 ; then \
	  echo "*****************************************************"; \
	  echo "**** You have to be root to excute this function ****"; \
	  echo "*****************************************************"; \
	  exit 1; \
	fi

allvars :
	@echo "TESTBIN=$(TESTBIN)"
	@echo "DEBUG=$(DEBUG)"
	@echo "prefix=$(prefix)"
	@echo "PROGRAM=$(PROGRAM)"
	@echo "MAJOR=$(MAJOR)"
	@echo "MINOR=$(MINOR)"
	@echo "BUILD=$(BUILD)"
	@echo "VERSION=$(VERSION)"
	@echo "DATE=$(DATE)"
	@echo "USERID=$(USERID)"
	@echo "BASEDIR=$(BASEDIR)"
	@echo "OS=$(OS)"
	@echo "PROC=$(PROC)"
	@echo "MACHINE=$(MACHINE)"
	@echo "LIBC=$(LIBC)"
	@echo "LIBCVER=$(LIBCVER)"
	@echo "LINUXLIBC=$(LINUXLIBC)"
	@echo "SNAP=$(SNAP)"
	@echo "DIST=$(DIST)"
	@echo "BINDISTB=$(BINDISTB)"
	@echo "BINDIST=$(BINDIST)"
	@echo "SNAPDIR=$(SNAPDIR)"
	@echo "DISTDIR=$(DISTDIR)"
	@echo "BINDISTDIR=$(BINDISTDIR)"
	@echo "SRCDIR=$(SRCDIR)"
	@echo "INCLUDE=$(INCLUDE)"
	@echo "DOCDIR=$(DOCDIR)"
	@echo "SUBDIRS=$(SUBDIRS)"
	@echo "CLEANDIRS=$(CLEANDIRS)"
	@echo "ALLDIRS=$(ALLDIRS)"
	@echo "PROGRAMINSTALLDIR=$(PROGRAMINSTALLDIR)"
	@echo "DOCINSTALLDIR=$(DOCINSTALLDIR)"
	@echo "OTHERINSTALLDIR=$(OTHERINSTALLDIR)"
	@echo "OTHERINSTALLFILES=$(OTHERINSTALLFILES)"
	@echo "KNOWNPREFIXES=$(KNOWNPREFIXES)"
	@echo "FILESTOSAVE=$(FILESTOSAVE)"
	@echo "BINFILESTOSAVE=$(BINFILESTOSAVE)"
	@echo "CC=$(CC)"
	@echo "DEFINES=$(DEFINES)"
	@echo "COPTIONS=$(COPTIONS)"
	@echo "CFLAGS=$(CFLAGS)"
	@echo "LIBS=$(LIBS)"
	@echo "INCLUDES=$(INCLUDES)"
	@echo "ALLINCLUDES=$(ALLINCLUDES)"
	@echo "OBJECTS=$(OBJECTS)"
	@echo "SUBMAKEALL=$(SUBMAKEALL)"
	@echo "CONFIGURED=$(CONFIGURED)"
	@echo "OPTLIBS=$(OPTLIBS)"
	@echo "OPTDEFINES=$(OPTDEFINES)"


.PHONEY : all compilecount numofbuilds dist snap cvsclean distclean clean install uninstall-less uninstall-more uninstall utils fixclockskew checkforroot config allvars
# DO NOT DELETE
