Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

freeplane: minor refactor, 1.11.8 -> 1.11.14 #312940

Merged
merged 7 commits into from
May 19, 2024
Merged

Conversation

drupol
Copy link
Contributor

@drupol drupol commented May 19, 2024

Description of changes

Things done

  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)
    • sandbox = relaxed
    • sandbox = true
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • 24.05 Release Notes (or backporting 23.05 and 23.11 Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
  • Fits CONTRIBUTING.md.

Add a 👍 reaction to pull requests you find important.

@drupol drupol changed the title Freeplane/bump freeplane: 0.11.8 -> 0.11.14, minor refactor May 19, 2024
@drupol drupol marked this pull request as ready for review May 19, 2024 17:16
@drupol drupol changed the title freeplane: 0.11.8 -> 0.11.14, minor refactor freeplane: minor refactor May 19, 2024
@drupol
Copy link
Contributor Author

drupol commented May 19, 2024

I tried to update to 1.11.14, but I was blocked with:

❯ nix build .#freeplane -L
freeplane> Running phase: unpackPhase
freeplane> unpacking source archive /nix/store/p2i15dr6mhl383x2flnak56m3lmrcd71-source
freeplane> source root is source
freeplane> Running phase: patchPhase
freeplane> Running phase: updateAutotoolsGnuConfigScriptsPhase
freeplane> Running phase: configurePhase
freeplane> no configure script, doing nothing
freeplane> Running phase: buildPhase
freeplane> Welcome to Gradle 7.6.4!
freeplane> Here are the highlights of this release:
freeplane>  - Added support for Java 19.
freeplane>  - Introduced `--rerun` flag for individual task rerun.
freeplane>  - Improved dependency block for test suites to be strongly typed.
freeplane>  - Added a pluggable system for Java toolchains provisioning.
freeplane> For more details see https://docs.gradle.org/7.6.4/release-notes.html
freeplane> To honour the JVM settings for this build a single-use Daemon process will be forked. See https://docs.gradle.org/7.6.4/userguide/gradle_daemon.html#sec:disabling_the_daemon.
freeplane> > Starting Daemon> IDLEDaemon will be stopped at the end of the build
freeplane> 
freeplane> > IDLE<-------------> 0% INITIALIZING [18ms]<-------------> 0% INITIALIZING [118ms]<-------------> 0% INITIALIZING [218ms]<-------------> 0% INITIALIZING [318ms]<-------------> 0% INITIALIZING [418ms]> Running init scripts<-------------> 0% INITIALIZING [518ms]<-------------> 0% INITIALIZING [618ms]<-------------> 0% INITIALIZING [718ms]> Running init scripts > Compiling initialization script '/nix/store/8b0c777h7z<-------------> 0% INITIALIZING [818ms]<-------------> 0% INITIALIZING [918ms]<-------------> 0% INITIALIZING [1s]> Running init scripts> Evaluating settings > Compiling settings file 'settings.gradle'> Evaluating settings<-------------> 0% CONFIGURING [1s]> Loading projects<-------------> 0% CONFIGURING [2s]> root project> root project > Compiling build file 'build.gradle'> root project> root project > Resolve dependencies of detachedConfiguration1<-------------> 0% CONFIGURING [3s]> root project > Resolve dependencies of detachedConfiguration4> root project > Resolve dependencies of :classpath<-------------> 0% CONFIGURING [4s]
freeplane> FAILURE: Build failed with an exception.
freeplane> * What went wrong:
freeplane> A problem occurred configuring root project 'freeplane_root'.
freeplane> > Could not resolve all files for configuration ':classpath'.
freeplane>    > Could not find okio-3.2.0.jar (com.squareup.okio:okio:3.2.0).
freeplane>      Searched in the following locations:
freeplane>          file:/nix/store/p807lyf0harakc2m8hpgxcvr03ahb1yr-freeplane-deps-1.11.13/com/squareup/okio/okio/3.2.0/okio-3.2.0.jar
freeplane> * Try:
freeplane> > Run with --stacktrace option to get the stack trace.
freeplane> > Run with --info or --debug option to get more log output.
freeplane> > Run with --scan to get full insights.
freeplane> * Get more help at https://help.gradle.org
freeplane> BUILD FAILED in 5s
freeplane> 
freeplane> 
freeplane> <-------------> 0% WAITING> Deleting unused version-specific caches in /build/source/.gradle
error: builder for '/nix/store/jfm493iwf8vldag8yaih2lxjw3p7i6m5-freeplane-1.11.13.drv' failed with exit code 1;
       last 25 log lines:
       > Daemon will be stopped at the end of the build
       > 
       > FAILURE: Build failed with an exception.
       > 
       > * What went wrong:
       > A problem occurred configuring root project 'freeplane_root'.
       > > Could not resolve all files for configuration ':classpath'.
       >    > Could not find okio-3.2.0.jar (com.squareup.okio:okio:3.2.0).
       >      Searched in the following locations:
       >          file:/nix/store/p807lyf0harakc2m8hpgxcvr03ahb1yr-freeplane-deps-1.11.13/com/squareup/okio/okio/3.2.0/okio-3.2.0.jar
       >
       > * Try:
       > > Run with --stacktrace option to get the stack trace.
       > > Run with --info or --debug option to get more log output.
       > > Run with --scan to get full insights.
       >
       > * Get more help at https://help.gradle.org
       >
       > BUILD FAILED in 5s

       For full logs, run 'nix log /nix/store/jfm493iwf8vldag8yaih2lxjw3p7i6m5-freeplane-1.11.13.drv'.

@drupol
Copy link
Contributor Author

drupol commented May 19, 2024

@TomaSajt Hope you don't mind me pinging you here, but since you're the only one I know doing some java. I tried to upgrade to 1.11.14, but got an issue with a dependency. If you could have a look, I'll be very grateful.

@TomaSajt
Copy link
Contributor

@TomaSajt Hope you don't mind me pinging you here, but since you're the only one I know doing some java. I tried to upgrade to 1.11.14, but got an issue with a dependency. If you could have a look, I'll be very grateful.

okio's naming has always been pretty weird in gradle, so we usually have some workarounds for it in packages that use it.

In this case, the original author of the okio patch was really thorough, making sure that they don't hard-code any version numbers. However it looks like okio has changed its naming system for later versions and the patch no longer works as expected.

Previously, we had to make a symlink for
com/squareup/okio/okio/x.y.z/okio-jvm-x.y.z.jar at com/squareup/okio/okio/x.y.z/okio-x.y.z.jar

however, now the original file that needs to be symlinked is in the okio-jvm directory, so we need to make a symlink for
com/squareup/okio/okio-jvm/x.y.z/okio-jvm-x.y.z.jar at com/squareup/okio/okio/x.y.z/okio-x.y.z.jar

So I rewrote the logic for the symlinking, and it's pretty short (I also changed the comment)

# com/squareup/okio/okio-jvm/x.y.z/okio-jvm-x.y.z.jar is expected to exist under com/squareup/okio/okio/x.y.z/okio-x.y.z.jar
while IFS="" read -r -d "" path; do
  ln -s "$path" ''${path//okio-jvm/okio}
done < <(find "$out" -type f -name 'okio-jvm-*.jar' -print0)

Co-authored-by: TomaSajt <62384384+TomaSajt@users.noreply.github.com>
@drupol
Copy link
Contributor Author

drupol commented May 19, 2024

Thank you !!!!

@drupol drupol merged commit 2c08690 into NixOS:master May 19, 2024
22 of 24 checks passed
@drupol drupol deleted the freeplane/bump branch May 19, 2024 21:38
@emilylange emilylange changed the title freeplane: minor refactor freeplane: minor refactor, 1.11.8 -> 1.11.14 May 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants