[sr-dev] git:master: srdb1/schema: sort files used to generate versions

Timo Teras timo.teras at iki.fi
Tue May 22 13:04:00 CEST 2012


Module: sip-router
Branch: master
Commit: 0e758a5e2b7ca005278fce878aad332f3b20770b
URL:    http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=0e758a5e2b7ca005278fce878aad332f3b20770b

Author: Timo Teräs <timo.teras at iki.fi>
Committer: Timo Teräs <timo.teras at iki.fi>
Date:   Tue May 22 13:55:05 2012 +0300

srdb1/schema: sort files used to generate versions

This ensures that the versions does not change if just file
ordering in file system changes. At least on some systems the
$(wildcard) function return unsorted results.

---

 lib/srdb1/schema/Makefile |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/lib/srdb1/schema/Makefile b/lib/srdb1/schema/Makefile
index 5fbeecd..003a48f 100644
--- a/lib/srdb1/schema/Makefile
+++ b/lib/srdb1/schema/Makefile
@@ -111,7 +111,7 @@ dbtext:
 	done
 	TMPFILE=`mktemp -t kamailio-test.XXXXXXXXXX`
 	# small hack to create the version table entries, this is here easier as with XSL
-	for FILE in  $(wildcard $(SCHEME)/dbtext/kamailio/*) ; do \
+	for FILE in $(sort $(wildcard $(SCHEME)/dbtext/kamailio/*)) ; do \
 		if [ -f "$$FILE" ]; then \
 			if [  "$$FILE" != "$(SCHEME)/dbtext/kamailio/version" ]; then \
 				tail -n 1 "$$FILE" >> "$(SCHEME)/dbtext/kamailio/version" ; \
@@ -136,7 +136,7 @@ db_berkeley:
 	done
 	TMPFILE=`mktemp -t kamailio-test.XXXXXXXXXX`
 	# small hack to create the version table entries, this is here easier as with XSL
-	for FILE in  $(wildcard $(SCHEME)/db_berkeley/kamailio/*) ; do \
+	for FILE in $(sort $(wildcard $(SCHEME)/db_berkeley/kamailio/*)) ; do \
 		if [ -f "$$FILE" ]; then \
 			if [  "$$FILE" != "$(SCHEME)/db_berkeley/kamailio/version" ]; then \
 				tail -n 2 "$$FILE" >> "$(SCHEME)/db_berkeley/kamailio/version" ; \




More information about the sr-dev mailing list