automake-patches
[Top][All Lists]
Advanced

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

Patch to fix handling of source files names containing literal '$'


From: Anselm Kruis
Subject: Patch to fix handling of source files names containing literal '$'
Date: Thu, 27 Nov 2003 17:37:54 +0100 (CET)

Hi,

Problem: automake does'nt handle filenames containing literal '$' very
well. Example:

Consider compiling a file named 'filewith$dollar.c". Then Makefile.am
might contain thei line:

my_programm_SOURCES = \
filewith$$dollar.c \
other_source.c \
...

config.status scans the Makefile and doesn't reduce the double '$$' to a
single '$ as make does.

The patch fixes this problem by adding an additional sed expression to the
code, that handles the DEP_FILES definition from the Makefile.

Patch:
Index: m4/depout.m4
===================================================================
RCS file: /cvs/automake/automake/m4/depout.m4,v
retrieving revision 1.15
diff -u -B -r1.15 depout.m4
--- m4/depout.m4        2 Jun 2003 07:08:40 -0000       1.15
+++ m4/depout.m4        27 Nov 2003 16:34:11 -0000
@@ -57,7 +57,7 @@
       p
     }
     /^DEP_FILES = / s/^DEP_FILES = //p' < "$mf" | \
-       sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
+       sed -e 's/\\$\\$/\\$/g' -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 
's/\$U/'"$U"'/g'`; do
     # Make sure the directory exists.
     test -f "$dirpart/$file" && continue
     fdir=`AS_DIRNAME(["$file"])`


ChangeLog:
     * m4/depout.m4: reduce '$$' in file names to '$'.


Best Regards
  Anselm Kruis


---
 Anselm Kruis                                   science + computing ag
 Senior Consultant Professional Services        Ingolst├Ądter Str. 22
 email address@hidden             80807 M├╝nchen, Germany
 phone +49 89 356386 874                        www.science-computing.de
 fax   +49 89 356386 737




reply via email to

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