automake
[Top][All Lists]
Advanced

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

Re: Can't call method "target_hook"...


From: Michael Pruett
Subject: Re: Can't call method "target_hook"...
Date: Sun, 9 Sep 2001 13:17:04 -0700
User-agent: Mutt/1.2.5i

On Sun, Sep 09, 2001 at 07:31:43PM +0100, Richard Boulton wrote:
> I've never seen it, or heard another report of it.
> 
> Could you tell us what the contents of your Makefile.am are, 
> which cause this error.  Or even better, put together a test case along
> the lines of those in the automake/tests directory (you may need to
> download the source of automake to see this), which demonstrates the
> problem.

It turns out that the problem was caused by my mistake in including an
object file in the SOURCES line where I should have included the
corresponding C source file.  But I still think that such a mistake
should result in an error message from automake, not one from Perl.

The following shell script creates a Makefile.am which exhibits the
problem.  I am not really sure what the appropriate test should be as
it might be difficult to differentiate a bad exit status from Perl from
a bad exit status from automake.

Michael

----

#!/bin/sh
# This shell script creates a Makefile.am which exhibits the following
# error with automake 1.5:
#
# Can't call method "target_hook" on an undefined value at
# /usr/freeware/bin/automake line 1943.

: > dumb.c
: > dummy.c

cat > Makefile.am << 'END'
lib_LTLIBRARIES = libdumb.la

libdumb_la_SOURCES = \
        dumb.c \
        dummy.o
END

cat > configure.in << 'END'
AC_INIT(dumb.c)
AM_INIT_AUTOMAKE(dumb, 1.0)
AM_PROG_LIBTOOL

AC_PROG_CC

AC_OUTPUT(Makefile)
END



reply via email to

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