diff --git a/.github/workflows/submit.yml b/.github/workflows/submit.yml index 9d19715a9862a7aed3803170feef90cd35ba527e..acf46c615ce6e9f392bc929f8a4260a3eefcee8e 100644 --- a/.github/workflows/submit.yml +++ b/.github/workflows/submit.yml @@ -341,6 +341,7 @@ jobs: run: > if ! grep --include=test-summary.txt -lqr build/*/test-results -e "TEST SUCCESS" ; then cat build/*/test-results/*/text/newfailures.txt ; + cat build/*/test-results/*/text/other_errors.txt ; exit 1 ; fi @@ -807,6 +808,7 @@ jobs: run: > if ! grep --include=test-summary.txt -lqr build/*/test-results -e "TEST SUCCESS" ; then cat build/*/test-results/*/text/newfailures.txt ; + cat build/*/test-results/*/text/other_errors.txt ; exit 1 ; fi @@ -1218,6 +1220,7 @@ jobs: run: > if ((Get-ChildItem -Path build\*\test-results\test-summary.txt -Recurse | Select-String -Pattern "TEST SUCCESS" ).Count -eq 0) { Get-Content -Path build\*\test-results\*\*\newfailures.txt ; + Get-Content -Path build\*\test-results\*\*\other_errors.txt ; exit 1 } @@ -1611,6 +1614,7 @@ jobs: run: > if ! grep --include=test-summary.txt -lqr build/*/test-results -e "TEST SUCCESS" ; then cat build/*/test-results/*/text/newfailures.txt ; + cat build/*/test-results/*/text/other_errors.txt ; exit 1 ; fi diff --git a/doc/building.html b/doc/building.html index 97c9b2a4bb693d81a2a523047d65fbca18088497..9cb1807345c905e42be6d1b7969d3b3b32e374d2 100644 --- a/doc/building.html +++ b/doc/building.html @@ -196,7 +196,7 @@
Windows XP is not a supported platform, but all newer Windows should be able to build the JDK.
On Windows, it is important that you pay attention to the instructions in the Special Considerations.
-Windows is the only non-POSIX OS supported by the JDK, and as such, requires some extra care. A POSIX support layer is required to build on Windows. Currently, the only supported such layers are Cygwin and Windows Subsystem for Linux (WSL). (Msys is no longer supported due to a too old bash; msys2 would likely be possible to support in a future version but that would require effort to implement.)
+Windows is the only non-POSIX OS supported by the JDK, and as such, requires some extra care. A POSIX support layer is required to build on Windows. Currently, the only supported such layers are Cygwin, Windows Subsystem for Linux (WSL), and MSYS2. (MSYS is no longer supported due to an outdated bash; While OpenJDK can be built with MSYS2, support for it is still experimental, so build failures and unusual errors are not uncommon.)
Internally in the build system, all paths are represented as Unix-style paths, e.g. /cygdrive/c/git/jdk/Makefile
rather than C:\git\jdk\Makefile
. This rule also applies to input to the build system, e.g. in arguments to configure
. So, use --with-msvcr-dll=/cygdrive/c/msvcr100.dll
rather than --with-msvcr-dll=c:\msvcr100.dll
. For details on this conversion, see the section on Fixpath.
A functioning Cygwin environment is required for building the JDK on Windows. If you have a 64-bit OS, we strongly recommend using the 64-bit version of Cygwin.
@@ -298,7 +298,7 @@It is advisable to keep an older version of Xcode for building the JDK when updating Xcode. This blog page has good suggestions on managing multiple Xcode versions. To use a specific version of Xcode, use xcode-select -s
before running configure
, or use --with-toolchain-path
to point to the version of Xcode to use, e.g. configure --with-toolchain-path=/Applications/Xcode8.app/Contents/Developer/usr/bin
If you have recently (inadvertently) updated your OS and/or Xcode version, and the JDK can no longer be built, please see the section on Problems with the Build Environment, and Getting Help to find out if there are any recent, non-merged patches available for this update.
The minimum accepted version of Visual Studio is 2017. Older versions will not be accepted by configure
and will not work. The maximum accepted version of Visual Studio is 2019.
For aarch64 machines running Windows the minimum accepted version is Visual Studio 2019 (16.8 or higher). For all other platforms the minimum accepted version of Visual Studio is 2017. Older versions will not be accepted by configure
and will not work. For all platforms the maximum accepted version of Visual Studio is 2022.
If you have multiple versions of Visual Studio installed, configure
will by default pick the latest. You can request a specific version to be used by setting --with-toolchain-version
, e.g. --with-toolchain-version=2017
.
If you have Visual Studio installed but configure
fails to detect it, it may be because of spaces in path.
Similar discussions for some other projects:
Google C++ Style Guide — Currently (2020) targeting C++17.
C++11 and C++14 use in Chromium — Categorizes features as allowed, banned, or to be discussed.
C++11 and C++14 use in Chromium — Categorizes features as allowed, banned, or to be discussed.
llvm Coding Standards — Currently (2020) targeting C++14.
Using C++ in Mozilla code — C++17 support is required for recent versions (2020).
make vscode-project-clangd
Additional instructions for configuring the given indexer will be displayed after the workspace has been generated.
This section is a work in progress.
-make ide-project
+The make system can generate a Visual Studio project for the Hotspot native source. After configuring, the project is generated using:
+make hotspot-ide-project
+This creates a file named jvm.vcxproj
in ide\hotspot-visualstudio
subfolder of the build output folder. The file can be opened in Visual Studio via File -> Open -> Project/Solution
.
The make system can generate generic native code indexing support in the form of a Compilation Database that can be used by many different IDEs and source code indexers.
make compile-commands
It's also possible to generate the Compilation Database for the HotSpot source code only, which is a bit faster as it includes less information.
make compile-commands-hotspot
This section is a work in progress.
+The JDK project has a script that can be used for indexing the project with IntelliJ. After configuring and building the JDK, an IntelliJ workspace can be generated by running the following command in the top-level folder of the cloned repository:
+bash bin/idea.sh
+To use it, choose File -> Open...
in IntelliJ and select the folder where you ran the above script.
Next, configure the project SDK in IntelliJ. Open File -> Project Structure -> Project
and select build/<config>/images/jdk
as the SDK to use.
In order to run the tests from the IDE, you can use the JTReg plugin. Instructions for building and using the plugin can be found here.