[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: excluding intermediate flex test suite files from distribution?
From: |
Will Estes |
Subject: |
Re: excluding intermediate flex test suite files from distribution? |
Date: |
Thu, 12 Nov 2015 17:23:19 -0500 |
User-agent: |
Mutt/1.5.23 (2014-03-12) |
On Thursday, 12 November 2015, 9:41 pm +0000, Gavin Smith <address@hidden>
wrote:
> On 12 November 2015 at 19:19, Will Estes <address@hidden> wrote:
> > and Makefile.am:
> >
> > check_PROGRAMS = test
> >
> > test_SOURCES = test.l
> > nodist_test_SOURCES = test.c
> >
> > I had to manually create the m4/ directory, but then:
> >
> > autoreconf -if && ./configure && make && make dist
> >
> > produces a tar ball with test.c in it. despite the nodist_test_SOURCES line.
> >
> > So what am I missing?
> >
>
> I'd guess that nodit_test_SOURCES = test.c is wrong, because of this:
>
> "You should never explicitly mention the intermediate (C or C++) file
> in any SOURCES variable; only list the source file."
>
> http://www.gnu.org/software/automake/manual/html_node/Yacc-and-Lex.html
>
> I changed Makefile.am to
>
> check_PROGRAMS = test
>
> nodist_test_SOURCES = test.l
> #nodist_test_SOURCES = test.c
>
> then after "make dist":
>
> $tar tf basketcase-0.0.1.tar.gz
> basketcase-0.0.1/
> basketcase-0.0.1/Makefile.in
> basketcase-0.0.1/aclocal.m4
> basketcase-0.0.1/configure
> basketcase-0.0.1/Makefile.am
> basketcase-0.0.1/configure.ac
> basketcase-0.0.1/build-aux/
> basketcase-0.0.1/build-aux/depcomp
> basketcase-0.0.1/build-aux/install-sh
> basketcase-0.0.1/build-aux/missing
> basketcase-0.0.1/build-aux/ylwrap
> basketcase-0.0.1/build-aux/compile
>
> I guess that's not what you want, because test.l isn't distributed there.
>
> Following Nick's suggestion to use dist-hook, the following appeared
> to give good results:
>
> check_PROGRAMS = test
>
> test_SOURCES = test.l
>
> dist-hook:
> rm -f ${distdir}/test.c
>
> With that, test.l is distributed but test.c isn't.
>
Thanks. That does what I'm looking for and I can scale that up to the entire
test suite with a bit of effort.
--
Will Estes
address@hidden