autoconf
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: PCCTS?


From: Dale E Martin
Subject: Re: PCCTS?
Date: Mon, 15 Oct 2001 09:35:08 -0400
User-agent: Mutt/1.2.5i

> Are there any pre-made macros for testing the availability of pccts?
> 
>   http://www.polhode.com/pccts.html
> 
> Thanks.

I use a couple of things - this first one looks for the binaries:

AC_DEFUN(AC_PROG_PCCTS,
[
AC_SUBST(ANTLR)
AC_SUBST(DLG)

AC_PATH_PROG(ANTLR, antlr, no)
if test $ANTLR = no; then
AC_MSG_ERROR( Configure could not locate the program \"antlr\" in your
path.  This program is needed to build the savant system.  It should
be installed as part of the PCCTS system which is available for free
via anonymous ftp from ftp.parr-research.com in the directory
/pub/pccts.  If you have installed PCCTS please verify that \"antlr\"
is in your path which is currently:
$PATH)
fi

])

And then I look for the headers with:
AC_CHECK_HEADERS(AToken.h pccts/AToken.h)

And I also have a fallback that can use an environment variable PCCTSROOT:

# Check for PCCTS root
if test "${PCCTSROOT-:}" = ":"; then
# The variable isn't defined.
AC_MSG_ERROR(PCCTSROOT is an environment variable that needs to be set
in order to build savant from source code.  It should contain the name
of the directory that the header files that came with PCCTS can be
found in.  Unfortunately there is no convention on where to put these
files so you must set this variable yourself.)
elif test ! -d "$PCCTSROOT"; then
AC_MSG_ERROR(PCCTSROOT should contain the name of the directory that
the header files that came with PCCTS can be found in.  Currently
PCCTSROOT is defined as \"$PCCTSROOT\" which is not a valid directory.)
else
echo "Good. PCCTSROOT is set to a valid directory."
fi

PCCTS is kind of a special case in that it has .cpp files that need to be
compiled but doesn't have any "official" library (static or shared) that
goes with it.  I copy those files into my working dir and build a local
library of them for my own system.

I'm the Debian Linux maintainer of PCCTS - I just adopted it a couple of
weeks back.  I've spoken with Tom Moog a teeny bit about providing changes
to the build system to build shared libraries.  He hasn't done it because
he's more of a Windows guy.  So I've considered doing an autotools/libtool
build and sending the changes upstream.  Anyone have any thoughts about it?

Thanks,
        Dale
-- 
Dale E. Martin, Clifton Labs, Inc.
Senior Computer Engineer
address@hidden
http://www.cliftonlabs.com
pgp key available



reply via email to

[Prev in Thread] Current Thread [Next in Thread]