@@ -658,6 +658,7 @@ LIBFFI_INCLUDEDIR
658
658
PKG_CONFIG_LIBDIR
659
659
PKG_CONFIG_PATH
660
660
PKG_CONFIG
661
+ TZPATH
661
662
SHLIBS
662
663
CFLAGSFORSHARED
663
664
LINKFORSHARED
@@ -819,6 +820,7 @@ with_assertions
819
820
enable_optimizations
820
821
with_lto
821
822
with_hash_algorithm
823
+ with_tzpath
822
824
with_address_sanitizer
823
825
with_memory_sanitizer
824
826
with_undefined_behavior_sanitizer
@@ -1524,6 +1526,9 @@ Optional Packages:
1524
1526
--with-hash-algorithm=[fnv|siphash24]
1525
1527
select hash algorithm for use in Python/pyhash.c
1526
1528
(default is SipHash24)
1529
+ --with-tzpath=<list of absolute paths separated by pathsep>
1530
+ Select the default time zone search path for zoneinfo.TZPATH
1531
+
1527
1532
--with-address-sanitizer
1528
1533
enable AddressSanitizer memory error detector,
1529
1534
'asan' (default is no)
@@ -10150,6 +10155,47 @@ $as_echo "default" >&6; }
10150
10155
fi
10151
10156
10152
10157
10158
+ validate_tzpath () {
10159
+ # Checks that each element of hte path is an absolute path
10160
+ if test -z " $1 " ; then
10161
+ # Empty string is allowed: it indicates no system TZPATH
10162
+ return 0
10163
+ fi
10164
+
10165
+ # Bad paths are those that don't start with /
10166
+ if ( echo $1 | grep -qE ' (^|:)([^/]|$)' ); then
10167
+ as_fn_error $? " --with-tzpath must contain only absolute paths, not $1 " " $LINENO " 5
10168
+ return 1;
10169
+ fi
10170
+ }
10171
+
10172
+ TZPATH=" /usr/share/zoneinfo:/usr/lib/zoneinfo:/usr/share/lib/zoneinfo:/etc/zoneinfo"
10173
+ { $as_echo " $as_me :${as_lineno-$LINENO } : checking for --with-tzpath" >&5
10174
+ $as_echo_n " checking for --with-tzpath... " >&6 ; }
10175
+
10176
+ # Check whether --with-tzpath was given.
10177
+ if test " ${with_tzpath+set} " = set ; then :
10178
+ withval=$with_tzpath ;
10179
+ case " $withval " in
10180
+ yes)
10181
+ as_fn_error $? " --with-tzpath requires a value" " $LINENO " 5
10182
+ ;;
10183
+ * )
10184
+ validate_tzpath " $withval "
10185
+ TZPATH=" $withval "
10186
+ { $as_echo " $as_me :${as_lineno-$LINENO } : result: \" $withval \" " >&5
10187
+ $as_echo " \" $withval \" " >&6 ; }
10188
+ ;;
10189
+ esac
10190
+
10191
+ else
10192
+ validate_tzpath " $TZPATH "
10193
+ { $as_echo " $as_me :${as_lineno-$LINENO } : result: \" $TZPATH \" " >&5
10194
+ $as_echo " \" $TZPATH \" " >&6 ; }
10195
+ fi
10196
+
10197
+
10198
+
10153
10199
{ $as_echo " $as_me :${as_lineno-$LINENO } : checking for --with-address-sanitizer" >&5
10154
10200
$as_echo_n " checking for --with-address-sanitizer... " >&6 ; }
10155
10201
0 commit comments