This is the mail archive of the automake@gnu.org mailing list for the automake project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: `make dist' with srcdir != builddir


>>> "Tom" == Tom Tromey <tromey@redhat.com> writes:

[...]

 Tom> I think what we want is for the positioning of the .c file not to
 Tom> matter for the developer, but for the file to end up in the
 Tom> distribution made by `make dist'.

The following is how I intended to fix this.  I'm not sure
it's what you want.  Anyway the patch below won't apply since
it predates Akim's sourcequake; I have yet to figure where the
relevent passage has been moved :)

2001-01-05  Alexandre Duret-Lutz  <duret_g@epita.fr>

	* automake.in (handle_dist_worker): When building the distdir,
	copy files from the build directory in preference to the source
	directory; that way the distribution is always built from the
	latest version of generated files.

--- automake.in.old	Fri Jan  5 19:30:53 2001
+++ automake.in	Fri Jan  5 20:50:01 2001
@@ -2689,6 +2689,10 @@
 		      . "\t    || exit 1; \\\n"
 		      . "\t  else \\\n"
 		      . "\t    test -f \$(distdir)/\$\$file \\\n"
+		      # First, look for $$files in the build directory,
+		      # and else get it from the source directory.
+		      . "\t    || (test -f \$\$file && "
+		      .           "cp -p \$\$file \$(distdir)/\$\$file) \\\n"
 		      . "\t    || cp -p \$\$d/\$\$file \$(distdir)/\$\$file \\\n"
 		      . "\t    || exit 1; \\\n"
 		      . "\t  fi; \\\n"

[...]

-- 
Alexandre Duret-Lutz


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]