svn commit: samba r22040 - in branches/SAMBA_4_0/source: .

jpeach at samba.org jpeach at samba.org
Mon Apr 2 18:43:31 GMT 2007


Author: jpeach
Date: 2007-04-02 18:43:31 +0000 (Mon, 02 Apr 2007)
New Revision: 22040

WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=22040

Log:
Use $< to specify the immediate prerequisit instead of $*. This is
needed for VPATH to find the correct files when srcdir != builddir.

This checkin is a test to see which platforms this change will break.

Modified:
   branches/SAMBA_4_0/source/main.mk


Changeset:
Modified: branches/SAMBA_4_0/source/main.mk
===================================================================
--- branches/SAMBA_4_0/source/main.mk	2007-04-02 18:42:56 UTC (rev 22039)
+++ branches/SAMBA_4_0/source/main.mk	2007-04-02 18:43:31 UTC (rev 22040)
@@ -377,23 +377,27 @@
 # if it also exists. So better use $* which is foo/bar
 # and append .c manually to get foo/bar.c
 #
+# But if srcdir != builddir, $* does not contain the filename
+# that was found be traversing VPATH. So we are back to $<.
+#	-- jpeach
+#
 
 # Run a static analysis checker
 CHECK = $(CC_CHECKER) `$(PERL) $(srcdir)/script/cflags.pl $@` \
-    $(CFLAGS) $(PICFLAG) -c $*.c -o $@
+    $(CFLAGS) $(PICFLAG) -c $< -o $@
 
 # Run the configured compiler
 COMPILE = $(CC) `$(PERL) $(srcdir)/script/cflags.pl $@` \
-    $(CFLAGS) $(PICFLAG) -c $*.c -o $@
+    $(CFLAGS) $(PICFLAG) -c $< -o $@
 
 # Run the compiler for the build host
 HCOMPILE = $(HOSTCC) `$(PERL) $(srcdir)/script/cflags.pl $@` \
-    $(HOSTCC_CFLAGS) -c $*.c -o $@
+    $(HOSTCC_CFLAGS) -c $< -o $@
 
 # Precompile headers
 PCHCOMPILE = @$(CC) -Ilib/replace \
     `$(PERL) $(srcdir)/script/cflags.pl $@` \
-    $(CFLAGS) $(PICFLAG) -c $*.c -o $@
+    $(CFLAGS) $(PICFLAG) -c $< -o $@
 
 .c.o:
 	@if test -n "$(CC_CHECKER)"; then \



More information about the samba-cvs mailing list