You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Fix conflict
* Use native tools on machine
* Fix SignalR Java POM to include description
* Try stream8
* New pool
* No git
* Maybe change the order
* Add newline at end of global.json file
---------
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Brennan <[email protected]>
Co-authored-by: Matt Thalman <[email protected]>
Write-Host-f Magenta "Detected JDK in $localJdkPath (via local repo convention)"
313
-
$env:JAVA_HOME=$localJdkPath
314
-
}
315
-
elseif ($env:JAVA_HOME) {
316
-
if (-not (Test-Path"${env:JAVA_HOME}\bin\javac.exe")) {
317
-
Write-Error"The environment variable JAVA_HOME was set, but ${env:JAVA_HOME}\bin\javac.exe does not exist. Remove JAVA_HOME or update it to the correct location for the JDK. See https://www.bing.com/search?q=java_home for details."
318
-
}
319
-
else {
320
-
Write-Host-f Magenta "Detected JDK in ${env:JAVA_HOME} (via JAVA_HOME)"
if (-not$foundJdk-and$RunBuild-and ($All-or$BuildJava) -and-not$NoBuildJava) {
357
-
Write-Error"Could not find the JDK. Either run $PSScriptRoot\scripts\InstallJdk.ps1 to install for this repo, or install the JDK globally on your machine (see $PSScriptRoot\..\docs\BuildFromSource.md for details)."
358
-
}
359
311
360
312
# Initialize global variables need to be set before the import of Arcade is imported
Write-Host-f Magenta "Detected JDK in $localJdkPath (via local repo convention)"
346
+
$env:JAVA_HOME=$localJdkPath
347
+
}
348
+
elseif ($env:JAVA_HOME) {
349
+
if (-not (Test-Path"${env:JAVA_HOME}\bin\javac.exe")) {
350
+
Write-Error"The environment variable JAVA_HOME was set, but ${env:JAVA_HOME}\bin\javac.exe does not exist. Remove JAVA_HOME or update it to the correct location for the JDK. See https://www.bing.com/search?q=java_home for details."
351
+
}
352
+
else {
353
+
Write-Host-f Magenta "Detected JDK in ${env:JAVA_HOME} (via JAVA_HOME)"
if (-not$foundJdk-and$RunBuild-and ($All-or$BuildJava) -and-not$NoBuildJava) {
390
+
Write-Error"Could not find the JDK. Either run $PSScriptRoot\scripts\InstallJdk.ps1 to install for this repo, or install the JDK globally on your machine (see $PSScriptRoot\..\docs\BuildFromSource.md for details)."
391
+
}
392
+
}
393
+
387
394
# Add default .binlog location if not already on the command line. tools.ps1 does not handle this; it just checks
388
395
# $BinaryLog, $CI and $ExcludeCIBinarylog values for an error case. But tools.ps1 provides a nice function to help.
389
396
if ($BinaryLog) {
@@ -416,6 +423,17 @@ try {
416
423
$tmpRestore=$restore
417
424
$restore=$true
418
425
426
+
# Initialize the native tools before locating java.
427
+
if ($NativeToolsOnMachine) {
428
+
$env:NativeToolsOnMachine=$true
429
+
# Do not promote native tools except in cases where -NativeToolsOnMachine is passed.
430
+
# Currently the JDK is laid out in an incorrect pattern: https://github.com/dotnet/dnceng/issues/2185
431
+
InitializeNativeTools
432
+
}
433
+
434
+
# Locate java, now that we may have java available after initializing native tools.
0 commit comments