fltk14: 1.4.x-2021-12-21 -> 1.4.4, refactor#401257
fltk14: 1.4.x-2021-12-21 -> 1.4.4, refactor#401257LordGrimmauld merged 2 commits intoNixOS:masterfrom
Conversation
7f90449 to
245137e
Compare
|
|
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: |
|
@jchv I stumbled upon this PR trying to update Also FLTK 1.4.4 is out already. |
|
Will try to get to this today. Sorry, it fell through the cracks it seems. |
This is branched off of common.nix as FLTK 1.4.0 makes some fairly substantial changes that are difficult to reconcile across 1.3 and 1.4.
|
|
|
@petrzjunior It's updated to FLTK 1.4.4 now. Unfortunately it doesn't really seem like there's anyone really to review these changes, so it might still be kind of hard to get it merged. Obviously, feel free to review it yourself. Hopefully it won't stall so badly this time around. |
|
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: |
eljamm
left a comment
There was a problem hiding this comment.
I believe the package in the title should be fltk14 and not fltk, since the former is the one being updated.
Other than that and a few small things, this LGTM.
| postFixup = '' | ||
| substituteInPlace $out/bin/fltk-config \ | ||
| --replace "/$out/" "/" | ||
| ''; |
There was a problem hiding this comment.
Do you know why this is necessary?
There was a problem hiding this comment.
Not exactly, but it definitely is still needed. Without it:
$ ./result/bin/fltk-config --cc --libs
/nix/store/bcw9f6r9v2fm3kv7d15fcrya0mf34xds-gcc-wrapper-14.3.0/bin/gcc
/nix/store/8spr669m2almkln8crjpiv9vc88r9g53-fltk-1.4.4//nix/store/8spr669m2almkln8crjpiv9vc88r9g53-fltk-1.4.4/lib/libfltk.a
$ ./result/bin/fltk-config --cc --libs
/nix/store/bcw9f6r9v2fm3kv7d15fcrya0mf34xds-gcc-wrapper-14.3.0/bin/gcc
/nix/store/2w74z6yw8nh66dvhn541x0278rsgyxh6-fltk-1.3.8//nix/store/2w74z6yw8nh66dvhn541x0278rsgyxh6-fltk-1.3.8/lib/libfltk.aI can't come up with a good comment explaining it because I haven't dug deep enough to truly understand what is causing that.
I'll make them both --replace-fails, at least.
bfa6d97 to
340342a
Compare
|
|
Yep, ok. The only "real" failures I'm getting on aarch64-darwin are pre-existing. |
Nice. I also ran |
|
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: |
|
Unfortunately, I don't really know what the most polite route would be to try to get this moving forward, but it sure would be nice before NixOS 25.11 branches off. FLTK has been stuck in time for quite a while, and I already tried the obvious things. Anyone on the cc list for this PR have any advice? |
|
|
|
Not aware of the CMake build issues you speak of, FLTK 1.3 and 1.4 both were building and working fine for me. This PR doesn't actually modify FLTK 1.3, it just splits the derivations out since the FLTK 1.4 configuration diverged from FLTK 1.3 enough that I felt it wasn't worth trying to maintain it in a unified way anymore (especially seeing as I'm sure eventually FLTK 1.3 will be dropped, even if not particularly soon.) (This does technically cause the FLTK 1.3 derivation to be re-evaluated, but it's because I changed a |
LordGrimmauld
left a comment
There was a problem hiding this comment.
Doesn't look too bad, but there is a couple aspects that can imo be improved while we are here.
|
|
||
| cmakeFlags = [ | ||
| # Common | ||
| "-DFLTK_BUILD_SHARED_LIBS=${onOff (!stdenv.hostPlatform.isStatic)}" |
There was a problem hiding this comment.
| "-DFLTK_BUILD_SHARED_LIBS=${onOff (!stdenv.hostPlatform.isStatic)}" | |
| (lib.cmakeBool "FLTK_BUILD_SHARED_LIBS" (!stdenv.hostPlatform.isStatic)) |
cmakeBool is preferable over some custom thing. Obviously applies to the other options too.
| libjpeg | ||
| libpng | ||
| ] | ||
| ++ lib.optionals stdenv.hostPlatform.isLinux [ |
There was a problem hiding this comment.
| ++ lib.optionals stdenv.hostPlatform.isLinux [ | |
| ++ withXorg [ |
I would like options for xorg and wayland - a linux conditional is not super readable, and i am left guessing what it does.
| ] | ||
| ++ lib.optionals withPango [ | ||
| pango | ||
| ]; |
There was a problem hiding this comment.
Maybe we could also add wayland support? Should only need wayland, wayland-protocols, and xkbcommon.
| glew | ||
| ] | ||
| ++ lib.optionals stdenv.hostPlatform.isLinux [ | ||
| fontconfig |
There was a problem hiding this comment.
Log is complaining about missing expat for fontconfig
| graphviz | ||
| ]; | ||
|
|
||
| buildInputs = |
There was a problem hiding this comment.
log is complaining about missing libsysprof-capture
| ]; | ||
|
|
||
| postPatch = '' | ||
| patchShebangs documentation/make_* |
There was a problem hiding this comment.
cmake 4 compat would be nice, e.g. by substituteInPlace if upstream doesn't maintain 1.3.x anymore
cmake 4 is currently in staging-next, failures and fixes are tracked in #445447. The hydra failure for fltk can be seen here: https://hydra.nixos.org/build/308206733/nixlog/1
Thanks for your review, @LordGrimmauld. While improvements are nice, I think we should limit the scope of this PR to splitting
If you'd like, we can undo this change so that we keep 0 rebuilds, then include it again in the followup. Perhaps this can help merge this PR faster since it's just a refactor. |
Fair enough. If i merge and open a follow-up, will you review that? |
Yup, absolutely. |
|
Sorry, I have plenty of time to work on this currently, I'm just bad at multi-tasking. @eljamm I'll go ahead and at least revert the |
|
|
Okay, i have my fltk fixes ready locally (built on top of this). Will merge and open my PR in the interest of not stalling this with bike sheds. |
|
Follow-up in #446331 |

In the distant year of 2024, I filed #357462 then proceeded to never actually do it. I think it's about time to try to take care of this, hopefully prior to NixOS 25.05 branching off.
I think FLTK 1.3 and FLTK 1.4 have diverged enough to justify forking off the 1.4 derivation and getting rid of
common.nix.(Note:
default.nixis almost entirely just whatcommon.nixused to be, just with the values inlined. Unfortunately there's no real way to make the Git diff cleaner without changing the filename, which I opted to not do.)Things done
nix.conf? (See Nix manual)sandbox = relaxedsandbox = truenix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/)Add a 👍 reaction to pull requests you find important.