[patch] update for (kbuild: correctly skip tilded backups in localversion files)

!MAILaRCHIVE_VOTE_RePLACE
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: LKML <linux-kernel@...>
Cc: Roman Zippel <zippel@...>, Bastian Blank <bastian@...>, Sam Ravnborg <sam@...>, Andrew Morton <akpm@...>
Date: Wednesday, January 31, 2007 - 5:35 am

kbuild: finally correctly skip tilded backups in localversion files


Signed-off-by: Oleg Verych <olecom@flower.upol.cz>
---

 Final addition. Why i want to maximize usage of shell, rather, than
 `make'? Just because i think, it's more portable, clear way.

 Thanks.

--- linux-2.6.20-rc6/Makefile~4tilde-backups~	2007-01-31 07:46:18.696404500 +0100
+++ linux-2.6.20-rc6/Makefile	2007-01-31 10:19:18.406100500 +0100
@@ -788,10 +788,10 @@ $(vmlinux-dirs): prepare scripts
 # scripts/setlocalversion and add the appropriate checks as needed.
 
-localversion = $(objtree)/localversion	    $(srctree)/localversion
-ext_versions = $(objtree)/localversion[^~]* $(srctree)/localversion[!~]*
-versions = $(localversion) $(ext_versions)
-localver = $(subst $(space),, \
-	   $(shell cat /dev/null $(sort $(wildcard $(versions)))) \
-	   $(patsubst "%",%,$(CONFIG_LOCALVERSION)))
+pattern = ".*/localversion[^~]*"
+string  = $(shell cat /dev/null \
+	   `find $(objtree) $(srctree) -maxdepth 1 -regex $(pattern) | sort`)
+
+localver = $(subst $(space),, $(string) \
+			      $(patsubst "%",%,$(CONFIG_LOCALVERSION)))
 
 # If CONFIG_LOCALVERSION_AUTO is set scripts/setlocalversion is called
-
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[patch] update for (kbuild: correctly skip tilded backups in..., Oleg Verych, (Wed Jan 31, 5:35 am)