# The distdef header will be created by the Autodist. It need to be included
# in the source code in order for the preprocessor to respect distdef
-# conditionals in source code. Example:
+# conditionals in source code. If your project doesn't need distdefs you
+# can comment this out. Example:
#
# DISTDEFS="include/distdefs.h"
#
| grep "define " | cut -d' ' -f2 | sort | uniq`
if test "$inhs" = "" && test "$defs" = ""; then
- ad_fatal "Distribution '$1' does not define anything"
+ if test "$1" != "default"; then
+ ad_fatal "Distribution '$1' does not define anything"
+ fi
fi
# Get undefined distdefs
do
echo $i >>autodist.tmp.defs
done
- distdefs=`sort < autodist.tmp.defs | uniq`
+ if test -f autodist.tmp.defs; then
+ distdefs=`sort < autodist.tmp.defs | uniq`
+ fi
distdefs=`echo $distdefs`
rm -f autodist.tmp.defs
###############################################################################
# Autodist code
-usage="Usage: autodist [options] [distribution] [version] [params]"
+usage="Usage: autodist [OPTIONS] [DISTRIBUTION] [VERSION] [PARAMS]"
help="\
Autodist prepares source tree for configuration, compilation and
distribution. Generates Automake.am files from Automake.ad files,
#
if test "$DISTDEFS"; then
ad_create_distdefs_h
-else
- ad_fatal "DISTDEFS not defined in $distdir/autodist.conf"
fi
# Get extra parameters from command line