8389584: Allow a shared Gradle properties - #2240
Conversation
|
👋 Welcome back nlisker! A progress list of the required criteria for merging this PR into |
|
❗ This change is not yet ready to be integrated. |
|
@kevinrushforth Please review. Someone from Gluon might also want to take a look. A notification on the mailing list prior to integration could help give a heads-up with regards to the git conflict that may arise. |
|
The total number of required reviews for this PR has been set to 2 based on the presence of this label: |
Webrevs
|
|
I have a concern about requiring OpenJFX specific configuration in the user-level This makes OpenJFX build properties visible to every Gradle build on the machine. It also prevents developers from keeping OpenJFX only Gradle settings scoped to this repository, for example: org.gradle.java.home=C:/JDK/jdk-25.0.1
org.gradle.dependency.verification=lenient
org.gradle.daemon=falseIs there a reason we cannot continue to support a project local, gitignored |
|
I have the same concern as @AnirvanSarkar |
These are valid concerns.
As explained above, it is required for project configuration such as the toolchain and build properties, e.g.,: org.gradle.caching=true
org.gradle.parallel=true
org.gradle.configuration-cache=trueHaving this file gitignored means we can't improve the build (we're stuck with Gradle 2 or 3). It is a committed file in every project I've seen (I can make a list if it helps). Figuratively, the current setup "hijacks" the file. It boils down to what the purpose of I'd like to know which gradle settings users want to change and why. |
|
Thanks for the clarification. Using a gitignored I suggest The existing The settings I plan to override locally are: org.gradle.dependency.verification=lenient
org.gradle.daemon=falseOther developers may also want to override settings such as: org.gradle.jvmargs=-Xmx...The dependency verification override is needed in my workflow because I usually do not compile the WebKit and Media sources. Instead, I set the Because the SHA-256 hashes of these stub runtimes are not currently included in If SNAPSHOT builds of OpenJFX were available, this override would not be necessary [3]. Gradle daemon is disabled due to known issues on Windows [4][5]. Building OpenJFX wiki page [6] would also require an update if this pull request is merged. [1] - https://developer.android.com/build#properties-files |
To make sure we're on the same page, as explained above, these options can't be overridden in a local properties file that is read during the build configuration phase because they are used before the configuration phase. Those would have to be passed in as command flags (however they can be aggregated into one flag). |
|
Yes, that's my understanding as well. |
|
@AnirvanSarkar Try this branch if you're able to and see if it answers your needs. Thanks. |
|
Thanks for the changes! I noticed one behavior change around overriding OpenJFX project properties from the command line using For example, with the following in CONF = ReleaseRunning: ./gradlew -PCONF=DebugNative properties | grep CONFExpected: Current output: I believe it would be preferable for the command-line value ( One possible way to preserve this behavior could be to make |
True. It should work now. |
|
I'll want to do both a few local tests and a CI build to ensure that it doesn't cause problems. @arapte Can you also review? |
Allows using a Gradle properties file at the project level by requiring the user-specific one to be present in the user's Gradle dir. A Gradle properties file is necessary for a proper Gradle build system's configuration. The user file takes precedence over the project one.
Progress
Issue
Reviewing
Using
gitCheckout this PR locally:
$ git fetch https://git.openjdk.org/jfx.git pull/2240/head:pull/2240$ git checkout pull/2240Update a local copy of the PR:
$ git checkout pull/2240$ git pull https://git.openjdk.org/jfx.git pull/2240/headUsing Skara CLI tools
Checkout this PR locally:
$ git pr checkout 2240View PR using the GUI difftool:
$ git pr show -t 2240Using diff file
Download this PR as a diff file:
https://git.openjdk.org/jfx/pull/2240.diff
Using Webrev
Link to Webrev Comment