mirror of
https://github.com/github/codeql.git
synced 2026-05-04 21:25:44 +02:00
Use empty toolchains.xml for java-version-too-old
This commit is contained in:
@@ -13,6 +13,12 @@ for k in ["JAVA_HOME_11_X64", "JAVA_HOME_17_X64"]:
|
||||
if k in os.environ:
|
||||
del os.environ[k]
|
||||
|
||||
run_codeql_database_create([], lang="java", runFunction = runUnsuccessfully, db = None)
|
||||
# Use a custom, empty toolchains.xml file so the autobuilder doesn't see any Java versions that may be
|
||||
# in a system-level toolchains file
|
||||
toolchains_path = os.path.join(os.getcwd(), 'toolchains.xml')
|
||||
|
||||
run_codeql_database_create([], lang="java", runFunction = runUnsuccessfully, db = None, extra_env={
|
||||
'LGTM_INDEX_MAVEN_TOOLCHAINS_FILE': toolchains_path
|
||||
})
|
||||
|
||||
check_diagnostics()
|
||||
|
||||
@@ -0,0 +1,5 @@
|
||||
<?xml version="1.0"?>
|
||||
<toolchains xmlns="https://maven.apache.org/TOOLCHAINS/1.1.0"
|
||||
xmlns:xsi="https://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="https://maven.apache.org/TOOLCHAINS/1.1.0 https://maven.apache.org/xsd/toolchains-1.1.0.xsd">
|
||||
</toolchains>
|
||||
Reference in New Issue
Block a user