#
# This warning gets printed at the top of each Makefile
#

$DontEditMake = <<"END";
# This Makefile is automatically generated.  Do NOT edit it here.
END

#
# Which source subdirectories you want
#

@WantDirs=("include","lib","qi","util","ph","whoi");

#
# Where the source directory lives
#

$_ = `pwd`; chop;
$SrcDir = $_;

#
# Features you want enabled
#
# PRE_ENCRYPT	passwords kept encrypted
# ID_FALLBACK	if no password, use last 8 chars of id field
# DO_TILDE	field~value means field is empty or contains value
# EMAIL_AUTH	allow authorization by email field
# RESTRICTED	allow local queries only; be sure to set @OkAddrs
# NO_READ_LOCK	do not lock for reading; helps on loaded systems, but
#		may give wrong results every once in a blue moon
# FCNTL_FLOCK	use fcntl() calls for locking if flock() not available.
# LOCKF_FLOCK	use lockf() calls for locking if flock() and fcntl() not
#		available.
#
# eg: @Features = ("ID_FALLBACK","EMAIL_AUTH");

@Features = ();

#
# The set of targets you want in the toplevel makefile
#

@TopTargets=("all","install","depend","clean","tape","rcs");

#
# The directory containing the nameserver's libraries.
#

$LibDir = "$SrcDir/lib";

#
# compilers, et al.
#

# Add to Cflags as needed
# -DFCNTL_FLOCK	use fcntl() calls for locking if flock() not available.
# -DLOCKF_FLOCK	use lockf() calls for locking if flock() and fcntl() not
#		available.

$Cflags = "-I$SrcDir/include";
$Lflags = "";
$Para = "";		# Set this to "&" for sequent's parallel make
$CC = "cc";		# ANSI or not, doesn't matter
$Depend = "-M";		# get .h file dependencies
			# Ultrix -Em
			# Convex -k
			# Normal -M
			# gcc living dangerously -MM
$Ci = "ci";		# for rcs
$Perl = "perl";		# what perl to use
$Lex = "lex";		# what lex to use
$Ranlib = "ranlib";	# ranlib for BSD, echo for SYSV
$Install = "install -c";	# if only there were an alternative...
$Mode = "0755";			# mode for binaries
$Owner = "nameserv";		# owner for binaries
$Group = "nameserv";		# group for binaries

$NsLib = "$LibDir/libu.a";	# library routines
$QiLib = "$LibDir/libqi.a";	# qi as a library; used by some utils
$MoreLib = "-ll";		# need the lex library
$DbmLib = "";			# need the dbm library if not in libc.a

#
# Directory for executables
#

$QiExecDir = "$SrcDir/../bin";
$PhExecDir = "/usr/local/bin";

#
# Make these links to ph (for easy lookup by type)
#
@PhLinks = ("timetable", "food", "phone", "unit", "areacode", "person",
           "weather", "spring", "summer", "fall");

#
# Items for conf.h and conf.c
#

# These string-valued things are overridable at runtime, by specifying
# (eg) qi -DATABASE=/some/dir/data
%DefineStrings=(
  "DATABASE",	"$SrcDir/../db/prod",	# Where the database lives, by default
  "MAILDOMAIN",	"uiuc.edu",		# Mail domain for phquery
  "ADMIN",	"p-pomes@uiuc.edu",	# Database administrator
  "PASSW",	"nameserv@uiuc.edu",	# Mail here for passwords (deprecated)
  "RUNDIR",	"$SrcDir/qi",		# Where QI should run
  "HELPDIR",	"$SrcDir/help",		# Where the help lives
  "NATIVESUBDIR","native",		# non-client-specific help
  "NOHELP",	"nohelp",		# file printed when no help topic
  "TEMPFILE",	"/tmp/qiXXXXXX",	# temporary file template
);

# These will be used as normal defines.  The keys will be converted to
# all upper-case.
%OtherDefines=(
  "Log_Qilog",	"LOG_LOCAL0",		# Syslog facility
  "Sig_Type",	"void",			# signal() return type
  "Mem_Type",	"char",			# *malloc() return type
  "Cpu_Limit",	"20",			# limit for CPU time
  "Drecsize",	384,			# size of .dir record
  "Dovrsize",	384,			# size of .dov record
  "Max_Key_len",16,			# max # chars to index
  "NIChars",	32,			# size of .idx record
  "NOChars",	1024,			# size of .iov record
  "PersonLimit","25",			# max # of people to return
#  "Use_Uid",	"10",			# setuid to this
#  "Use_Gid",	"15",			# setgid to this
);

#
# flags that are used only in the ph client
#
%PhFlags=(
  "NsService",	"ns",			# name of ns service
  "FallBackAddr","128.174.5.58",	# ns host ip address
  "FallBackPort","105",			# ns port number
  "MailDomain",	$DefineStrings{"MAILDOMAIN"},	# same as above
  "Host",	"ns.uiuc.edu",		# default qi host
  "Email_Auth",	"1",			# Use email authorization
);
