1
0
mirror of https://github.com/PDP-10/klh10.git synced 2026-01-13 15:27:10 +00:00
PDP-10.klh10/autogen.sh

33 lines
721 B
Bash
Executable File

#!/bin/sh
#
# autogen.sh
#
# Usage: ../path/to/autogen.sh [args for configure]
#
# (Re)constructs the configure script using the appropriate invocations
# of autoconf etc.
#
# It is strongly recommended to build in a separate directory
# for easy cleanup.
#
# When this is done, it runs configure with the given arguments.
srcdir=$(dirname $0)
test -z "$srcdir" && srcdir=.
builddir=$(pwd)
cd "$srcdir"
srcdir=$(pwd)
autoconf # creates configure from configure.ac
autoheader # creates src/config.h.in from configure.ac
if [ "$srcdir" != "$builddir" ]
then
echo "Now running configure $@ in $builddir"
cd "$builddir"
$srcdir/configure "$@"
else
echo "Not running configure in the source directory."
fi