Ethereal-dev: Re: [Ethereal-dev] Hox can we fix cvsversion.h computation?

Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.

From: Joerg Mayer <jmayer@xxxxxxxxx>
Date: Sat, 6 Mar 2004 16:07:46 +0100
On Thu, Mar 04, 2004 at 01:59:54PM +0100, Biot Olivier wrote:
> You can manually add *all* CVS/Entries files to the dependencies of
> cvsversion.h; I don't know whether there's an autotool macro that allows
> replacing "find . -name Entries" with its output for the dependencies.
> Additionally, the 'find' program is some sort of cheap grep on MS Win
> systems.
> 
> Ideally, one woud write a Makefile with something like:
> 
> cvsversion_h_dependencies = `find . -name Entries`

As reported, this doesn't work. Manually listing all files should work though.

Please try the attached patch (I hope it applies, as it is hand edited
to not include the shared libs stuff).

 Ciao
        Jï¿œrg

-- 
Joerg Mayer                                           <jmayer@xxxxxxxxx>
We are stuck with technology when what we really want is just stuff that
works. Some say that should read Microsoft instead of technology.
Index: Makefile.am
===================================================================
RCS file: /usr/local/cvsroot/ethereal/Makefile.am,v
retrieving revision 1.718
diff -p -u -r1.718 Makefile.am
--- Makefile.am	4 Mar 2004 08:26:20 -0000	1.718
+++ Makefile.am	6 Mar 2004 14:59:14 -0000
@@ -275,12 +265,10 @@
 # Common headers
 AM_CPPFLAGS = -I$(top_srcdir) -I$(top_srcdir)/wiretap
 
-.PHONY:	cvsversion.h
-
 #
 # Build the version string
 #
-cvsversion.h:
+cvsversion.h: $(ENTRIES)
 	$(PERL) $(srcdir)/make-version.pl
 
 #
Index: Makefile.common
===================================================================
RCS file: /usr/local/cvsroot/ethereal/Makefile.common,v
retrieving revision 1.28
diff -p -u -r1.28 Makefile.common
--- Makefile.common	5 Mar 2004 10:29:35 -0000	1.28
+++ Makefile.common	6 Mar 2004 14:59:14 -0000
@@ -378,3 +378,42 @@ noinst_HEADERS =	\
 	$(ethereal_INCLUDES) \
 	$(EXTRA_ethereal_INCLUDES)
 
+# All CVS/Entries files
+ENTRIES = \
+	CVS/Entries			\
+	doc/CVS/Entries			\
+	gtk/CVS/Entries			\
+	epan/CVS/Entries		\
+	epan/dfilter/CVS/Entries	\
+	epan/ftypes/CVS/Entries		\
+	help/CVS/Entries		\
+	gtk2/CVS/Entries		\
+	image/CVS/Entries		\
+	image/toolbar/CVS/Entries	\
+	tools/CVS/Entries		\
+	tools/lemon/CVS/Entries		\
+	debian/CVS/Entries		\
+	aclocal-fallback/CVS/Entries	\
+	packaging/CVS/Entries		\
+	packaging/rpm/CVS/Entries	\
+	packaging/rpm/SPECS/CVS/Entries	\
+	packaging/nsis/CVS/Entries	\
+	packaging/svr4/CVS/Entries	\
+	wiretap/CVS/Entries		\
+	plugins/CVS/Entries		\
+	plugins/acn/CVS/Entries		\
+	plugins/rdm/CVS/Entries		\
+	plugins/asn1/CVS/Entries	\
+	plugins/giop/CVS/Entries	\
+	plugins/irda/CVS/Entries	\
+	plugins/mgcp/CVS/Entries	\
+	plugins/pcli/CVS/Entries	\
+	plugins/v5ua/CVS/Entries	\
+	plugins/lwres/CVS/Entries	\
+	plugins/rtnet/CVS/Entries	\
+	plugins/artnet/CVS/Entries	\
+	plugins/docsis/CVS/Entries	\
+	plugins/enttec/CVS/Entries	\
+	plugins/megaco/CVS/Entries	\
+	plugins/gryphon/CVS/Entries
+