mirror of
https://frontier.innolan.net/rainlance/amiga-tz.git
synced 2025-11-21 22:04:29 +00:00
Use a single version number for both code and data.
* Makefile (VERSION): New macro, superseding ... (TZCODE_VERSION, TZDATA_VERSION): Remove. All uses changed. (version.h): Call the variable TZVERSION, not TZCODE_VERSION. All uses changed. (tzselect): Interpolate TZVERSION, not TZCODE_VERSION. (public): Adjust to new versioning scheme. * tzselect.ksh (TZVERSION): Rename from TZCODE_VERSION. * zdump.c, zic.c (main): Use TZVERSION, not TZCODE_VERSION.
This commit is contained in:
11
Makefile
11
Makefile
@ -3,8 +3,7 @@
|
|||||||
# 2009-05-17 by Arthur David Olson.
|
# 2009-05-17 by Arthur David Olson.
|
||||||
|
|
||||||
# Version numbers of the code and data distributions.
|
# Version numbers of the code and data distributions.
|
||||||
TZCODE_VERSION = tzcode2012c
|
VERSION = 2012d
|
||||||
TZDATA_VERSION = tzdata2012d
|
|
||||||
|
|
||||||
# Change the line below for your time zone (after finding the zone you want in
|
# Change the line below for your time zone (after finding the zone you want in
|
||||||
# the time zone files, or adding it to a time zone file).
|
# the time zone files, or adding it to a time zone file).
|
||||||
@ -327,7 +326,7 @@ INSTALL: ALL install date.1
|
|||||||
|
|
||||||
version.h:
|
version.h:
|
||||||
echo >$@ \
|
echo >$@ \
|
||||||
'static char const TZCODE_VERSION[]="$(TZCODE_VERSION)";'
|
'static char const TZVERSION[]="tz$(VERSION)";'
|
||||||
|
|
||||||
zdump: $(TZDOBJS)
|
zdump: $(TZDOBJS)
|
||||||
$(CC) $(CFLAGS) $(LFLAGS) $(TZDOBJS) $(LDLIBS) -o $@
|
$(CC) $(CFLAGS) $(LFLAGS) $(TZDOBJS) $(LDLIBS) -o $@
|
||||||
@ -379,7 +378,7 @@ tzselect: tzselect.ksh
|
|||||||
sed \
|
sed \
|
||||||
-e 's|AWK=[^}]*|AWK=$(AWK)|g' \
|
-e 's|AWK=[^}]*|AWK=$(AWK)|g' \
|
||||||
-e 's|TZDIR=[^}]*|TZDIR=$(TZDIR)|' \
|
-e 's|TZDIR=[^}]*|TZDIR=$(TZDIR)|' \
|
||||||
-e 's|\(TZCODE_VERSION\)=.*|\1=$(TZCODE_VERSION)|' \
|
-e 's|\(TZVERSION\)=.*|\1=tz$(VERSION)|' \
|
||||||
<$? >$@
|
<$? >$@
|
||||||
chmod +x $@
|
chmod +x $@
|
||||||
|
|
||||||
@ -437,10 +436,10 @@ public: $(ENCHILADA) set-timestamps
|
|||||||
$(AWK) -f checktab.awk $(PRIMARY_YDATA)
|
$(AWK) -f checktab.awk $(PRIMARY_YDATA)
|
||||||
LC_ALL=C && export LC_ALL && \
|
LC_ALL=C && export LC_ALL && \
|
||||||
tar $(TARFLAGS) -cf - $(DOCS) $(SOURCES) $(MISC) *.[1-8].txt | \
|
tar $(TARFLAGS) -cf - $(DOCS) $(SOURCES) $(MISC) *.[1-8].txt | \
|
||||||
gzip $(GZIPFLAGS) > $(TZCODE_VERSION).tar.gz
|
gzip $(GZIPFLAGS) > tzcode$(VERSION).tar.gz
|
||||||
LC_ALL=C && export LC_ALL && \
|
LC_ALL=C && export LC_ALL && \
|
||||||
tar $(TARFLAGS) -cf - $(DATA) | \
|
tar $(TARFLAGS) -cf - $(DATA) | \
|
||||||
gzip $(GZIPFLAGS) > $(TZDATA_VERSION).tar.gz
|
gzip $(GZIPFLAGS) > tzdata$(VERSION).tar.gz
|
||||||
|
|
||||||
typecheck:
|
typecheck:
|
||||||
make clean
|
make clean
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
#! /bin/ksh
|
#! /bin/ksh
|
||||||
|
|
||||||
TZCODE_VERSION=see_Makefile
|
TZVERSION=see_Makefile
|
||||||
|
|
||||||
# Ask the user about the time zone, and output the resulting TZ value to stdout.
|
# Ask the user about the time zone, and output the resulting TZ value to stdout.
|
||||||
# Interact with the user via stderr and stdin.
|
# Interact with the user via stderr and stdin.
|
||||||
@ -55,7 +55,7 @@ EOF
|
|||||||
exit 0
|
exit 0
|
||||||
elif [ "$1" = "--version" ]; then
|
elif [ "$1" = "--version" ]; then
|
||||||
cat <<EOF
|
cat <<EOF
|
||||||
tzselect $TZCODE_VERSION
|
tzselect $TZVERSION
|
||||||
EOF
|
EOF
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
fi
|
||||||
|
|||||||
2
zdump.c
2
zdump.c
@ -282,7 +282,7 @@ char * argv[];
|
|||||||
progname = argv[0];
|
progname = argv[0];
|
||||||
for (i = 1; i < argc; ++i)
|
for (i = 1; i < argc; ++i)
|
||||||
if (strcmp(argv[i], "--version") == 0) {
|
if (strcmp(argv[i], "--version") == 0) {
|
||||||
(void) printf("%s\n", TZCODE_VERSION);
|
(void) printf("%s\n", TZVERSION);
|
||||||
exit(EXIT_SUCCESS);
|
exit(EXIT_SUCCESS);
|
||||||
} else if (strcmp(argv[i], "--help") == 0) {
|
} else if (strcmp(argv[i], "--help") == 0) {
|
||||||
usage(stdout, EXIT_SUCCESS);
|
usage(stdout, EXIT_SUCCESS);
|
||||||
|
|||||||
2
zic.c
2
zic.c
@ -497,7 +497,7 @@ char * argv[];
|
|||||||
}
|
}
|
||||||
for (i = 1; i < argc; ++i)
|
for (i = 1; i < argc; ++i)
|
||||||
if (strcmp(argv[i], "--version") == 0) {
|
if (strcmp(argv[i], "--version") == 0) {
|
||||||
(void) printf("%s\n", TZCODE_VERSION);
|
(void) printf("%s\n", TZVERSION);
|
||||||
exit(EXIT_SUCCESS);
|
exit(EXIT_SUCCESS);
|
||||||
} else if (strcmp(argv[i], "--help") == 0) {
|
} else if (strcmp(argv[i], "--help") == 0) {
|
||||||
usage(stdout, EXIT_SUCCESS);
|
usage(stdout, EXIT_SUCCESS);
|
||||||
|
|||||||
Reference in New Issue
Block a user