File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -38,12 +38,19 @@ def get_output(*args, **kwargs):
3838
3939# get the compile and link args
4040kc = "krb5-config"
41+ autodetect_kc = True
4142posix = os .name != 'nt'
4243
4344# Per https://docs.python.org/3/library/platform.html#platform.architecture
4445# this is the preferred way of determining "64-bitness".
4546is64bit = sys .maxsize > 2 ** 32
4647
48+ kc_env = 'GSSAPI_KRB5CONFIG'
49+ if kc_env in os .environ :
50+ kc = os .environ [kc_env ]
51+ autodetect_kc = False
52+ print (f"Using { kc } from env" )
53+
4754link_args , compile_args = [
4855 shlex .split (os .environ [e ], posix = posix ) if e in os .environ else None
4956 for e in ['GSSAPI_LINKER_ARGS' , 'GSSAPI_COMPILER_ARGS' ]
@@ -77,7 +84,7 @@ def get_output(*args, **kwargs):
7784 except ValueError :
7885 cygwinccompiler .get_msvcr = lambda * a , ** kw : []
7986
80- if sys .platform .startswith ("freebsd" ):
87+ if sys .platform .startswith ("freebsd" ) and autodetect_kc :
8188 # FreeBSD does $PATH backward, for our purposes. That is, the package
8289 # manager's version of the software is in /usr/local, which is in PATH
8390 # *after* the version in /usr. We prefer the package manager's version
You can’t perform that action at this time.
0 commit comments