Skip to content

adlplug: fix cmake 4 compatibility#450403

Merged
OPNA2608 merged 1 commit intoNixOS:masterfrom
SkohTV:cmake-fix-coladlplug
Oct 9, 2025
Merged

adlplug: fix cmake 4 compatibility#450403
OPNA2608 merged 1 commit intoNixOS:masterfrom
SkohTV:cmake-fix-coladlplug

Conversation

@SkohTV
Copy link
Member

@SkohTV SkohTV commented Oct 9, 2025

Tracking issue #445447
Github upstream hasn't had an update in 4 years, so using postPatch
There were 3 different CMakeLists.txt to patch

Things done

  • Built on platform:
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • Tested, as applicable:
  • Ran nixpkgs-review on this PR. See nixpkgs-review usage.
  • Tested basic functionality of all binary files, usually in ./result/bin/.
  • Nixpkgs Release Notes
    • Package update: when the change is major or breaking.
  • NixOS Release Notes
    • Module addition: when adding a new NixOS module.
    • Module update: when the change is significant.
  • Fits CONTRIBUTING.md, pkgs/README.md, maintainers/README.md and other READMEs.

Add a 👍 reaction to pull requests you find important.

@nixpkgs-ci nixpkgs-ci bot added 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. 10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. labels Oct 9, 2025
@nix-owners nix-owners bot requested a review from OPNA2608 October 9, 2025 19:22
@SkohTV
Copy link
Member Author

SkohTV commented Oct 9, 2025

nixpkgs-review result

Generated using nixpkgs-review.

Command: nixpkgs-review pr 450403
Commit: e7bb89e59d1ff7d83ab4852aae204c931cb72565


x86_64-linux

✅ 2 packages built:
  • adlplug
  • opnplug

@nixpkgs-ci nixpkgs-ci bot added the 9.needs: reviewer This PR currently has no reviewers requested and needs attention. label Oct 9, 2025
@OPNA2608
Copy link
Contributor

OPNA2608 commented Oct 9, 2025

Github upstream hasn't had an update in 4 years, so using postPatch

Please submit this as a PR to upstream anyway - so this issue & fix has bigger visibility for other distros and potential forks - and vendor the patch.

@nixpkgs-ci nixpkgs-ci bot removed the 9.needs: reviewer This PR currently has no reviewers requested and needs attention. label Oct 9, 2025
@SkohTV SkohTV force-pushed the cmake-fix-coladlplug branch from e7bb89e to cec9b2f Compare October 9, 2025 20:45
@SkohTV
Copy link
Member Author

SkohTV commented Oct 9, 2025

I've made a PR upstream for https://github.com/jpcima/ADLplug
However for https://github.com/Wohlstand/libOPNMIDI and https://github.com/Wohlstand/libADLMIDI the fix is already upstream, but hard to add as a patch since there's a lot of commits in the way (so would need multiple patches) and is downloaded as a submodule (not sure I can patch the repo AND multiple git submodules via github patch link)

IMO, we can either :

  • Keep substituteInPlace for submodules and fetchpatch for main repo
  • Create custom patches that we vendor for nixpkgs for the submodules

@SkohTV SkohTV force-pushed the cmake-fix-coladlplug branch from cec9b2f to 063ed4b Compare October 9, 2025 21:07
@OPNA2608
Copy link
Contributor

OPNA2608 commented Oct 9, 2025

downloaded as a submodule (not sure I can patch the repo AND multiple git submodules via github patch link)

FYI: Submodules are already resolved in the src, and fetchpatch[2,…] allow you to rewrite the paths in a patch to be applied into a different subdirectory.

Example: A patch fetched from upstream Chromium, applied to the vendored copy of Chromium inside Qt WebEngine.

(fetchpatch2 {
url = "https://github.com/chromium/chromium/commit/2f39ac8d0a414dd65c0e1d5aae38c8f97aa06ae9.patch";
hash = "sha256-3kA2os0IntxIiJwzS5nPd7QWYlOWOpoLKYsOQFYv0Sk=";
stripLen = 1;
extraPrefix = "src/3rdparty/chromium/";
})

@SkohTV SkohTV force-pushed the cmake-fix-coladlplug branch from 063ed4b to b1e28cc Compare October 9, 2025 21:16
@SkohTV
Copy link
Member Author

SkohTV commented Oct 9, 2025

downloaded as a submodule (not sure I can patch the repo AND multiple git submodules via github patch link)

FYI: Submodules are already resolved in the src, and fetchpatch[2,…] allow you to rewrite the paths in a patch to be applied into a different subdirectory.

Example: A patch fetched from upstream Chromium, applied to the vendored copy of Chromium inside Qt WebEngine.

(fetchpatch2 {
url = "https://github.com/chromium/chromium/commit/2f39ac8d0a414dd65c0e1d5aae38c8f97aa06ae9.patch";
hash = "sha256-3kA2os0IntxIiJwzS5nPd7QWYlOWOpoLKYsOQFYv0Sk=";
stripLen = 1;
extraPrefix = "src/3rdparty/chromium/";
})

extraPrefix was the missing piece, thanks !

All issues should be resolved I believe, lmk if there's anything I missed

Copy link
Contributor

@OPNA2608 OPNA2608 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nixpkgs-review result

Generated using nixpkgs-review.

Command: nixpkgs-review pr 450403
Commit: b1e28ccd61d818bfee3d52c6c9ab80caa6a17304


x86_64-linux

✅ 3 packages built:
  • adlplug
  • nixpkgs-manual
  • opnplug

LGTM, thanks!

@OPNA2608 OPNA2608 added 12.approvals: 1 This PR was reviewed and approved by one person. 12.approved-by: package-maintainer This PR was reviewed and approved by a maintainer listed in any of the changed packages. labels Oct 9, 2025
@OPNA2608 OPNA2608 added this pull request to the merge queue Oct 9, 2025
Merged via the queue into NixOS:master with commit d04b55b Oct 9, 2025
28 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. 12.approvals: 1 This PR was reviewed and approved by one person. 12.approved-by: package-maintainer This PR was reviewed and approved by a maintainer listed in any of the changed packages.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants