summaryrefslogtreecommitdiff
path: root/src/third_party
diff options
context:
space:
mode:
authorNick Zolnierz <nicholas.zolnierz@mongodb.com>2017-09-18 14:55:24 -0400
committerNick Zolnierz <nicholas.zolnierz@mongodb.com>2017-09-19 09:51:11 -0400
commit1ebcf4db5b235837c0dac0a5776712af88bda210 (patch)
tree82e63ec41db968f0b56b29345496d3e2e22d7706 /src/third_party
parentc8a630fcaf458ca3324c432341b93996f1377c66 (diff)
downloadmongo-1ebcf4db5b235837c0dac0a5776712af88bda210.tar.gz
SERVER-31104: Timelib's make timezonedb.zip should produce an archive with version information
Diffstat (limited to 'src/third_party')
-rw-r--r--src/third_party/timelib-2017.05beta9/zones/Makefile15
1 files changed, 8 insertions, 7 deletions
diff --git a/src/third_party/timelib-2017.05beta9/zones/Makefile b/src/third_party/timelib-2017.05beta9/zones/Makefile
index fb8af401ddf..b423269eaba 100644
--- a/src/third_party/timelib-2017.05beta9/zones/Makefile
+++ b/src/third_party/timelib-2017.05beta9/zones/Makefile
@@ -10,7 +10,7 @@ download:
clean: release-php-clean
-rm -rf code
- -rm -f timezonedb.idx.php timezonedb.dta timezonedb.idx version-info.txt timezonedb-201*.tgz timezonedb.tgz timezonedb.zip timezonedb-201*.zip
+ -rm -f timezonedb.idx.php timezonedb.dta timezonedb.idx version-info.txt timezonedb-201*.tgz timezonedb.tgz timezonedb*.zip
tzdb: download
-@rm -rf code
@@ -35,16 +35,17 @@ timezonedb.dta: code/zone.tab
timezonedb.idx: timezonedb.idx.php timezonedb.dta
-timezonedb.zip: code/zone.tab
- @echo -n "Making archive..."
- -@cd code/data; zip --quiet -r ../../timezonedb.zip .
- cp timezonedb.zip timezonedb-$(VERSION).zip
- @echo " done"
-
version-info.txt:
find . -name tzdata*.tar.gz | sed 's/.*20/20/' | sed 's/\.tar.*//' > version-info.txt
find . -name tzdata*.tar.gz | php -r "preg_match('@([0-9]{4})([a-z])@', file_get_contents('php://stdin'), \$$a); echo \$$a[1], '.', ord(\$$a[2]) - ord('a') + 1;" >> version-info.txt
+timezonedb.zip: code/zone.tab version-info.txt
+ @echo -n "Making archive..."
+ -@mkdir code/timezonedb-$(VERSION); cp -r code/data/. code/timezonedb-$(VERSION)/; cp version-info.txt code/timezonedb-$(VERSION)/
+ -@cd code; zip --quiet -r ../timezonedb.zip timezonedb-$(VERSION)
+ cp timezonedb.zip timezonedb-$(VERSION).zip
+ @echo " done"
+
timezonedb.h: timezonedb.idx version-info.txt create_dot_h_file.php
php create_dot_h_file.php
cp timezonedb.h ..