Skip to content

craftos-pc: support for darwin#240092

Merged
siraben merged 1 commit intoNixOS:masterfrom
siraben:craftos-pc-darwin
Nov 12, 2025
Merged

craftos-pc: support for darwin#240092
siraben merged 1 commit intoNixOS:masterfrom
siraben:craftos-pc-darwin

Conversation

@siraben
Copy link
Member

@siraben siraben commented Jun 27, 2023

Description of changes

craftos-pc supports darwin as well as indicated in their project, however it requires a few adaptions.

Things done
  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
  • 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/)
  • 23.11 Release Notes (or backporting 23.05 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.

@siraben siraben marked this pull request as draft June 27, 2023 10:10
@ofborg ofborg bot added the 6.topic: darwin Running or building packages on Darwin label Jun 27, 2023
@siraben siraben force-pushed the craftos-pc-darwin branch 3 times, most recently from eec3010 to 9bc0c89 Compare June 27, 2023 10:42
@siraben
Copy link
Member Author

siraben commented Jun 27, 2023

@tomodachi94 would you be able to help look into this? I'm not sure why craftos needs to build its own lua, could it not use Nixpkgs' lua?

@siraben siraben force-pushed the craftos-pc-darwin branch from 9bc0c89 to fea8eb4 Compare June 27, 2023 10:43
@ofborg ofborg bot added the 8.has: package (new) This PR adds a new package label Jun 27, 2023
@ofborg ofborg bot requested a review from tomodachi94 June 27, 2023 11:18
@ofborg ofborg bot added 11.by: package-maintainer This PR was created by a maintainer of all the package it changes. 10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 10.rebuild-darwin: 1 This PR causes 1 package to rebuild on Darwin. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. 10.rebuild-linux: 1 This PR causes 1 package to rebuild on Linux. labels Jun 27, 2023
@tomodachi94
Copy link
Member

I'm not sure why craftos needs to build its own lua, could it not use Nixpkgs' lua?

It could, but iirc ComputerCraft's Lua has some quirks that are not compatible with standard Lua. I'll take a closer look at this when I have more time, probably later tonight or tomorrow :)

(Thanks for making this PR!)

@tomodachi94
Copy link
Member

@siraben upon further inspection, CPC has a custom fork of liblua specifically for improved compatibility with the game itself. I don't think that replacing the custom patched Lua for a prebuilt one would work very well with the emulator.

(Maybe the custom Lua should get split out into its own package, liblua-craftos or similar?)

Also, if you rebase onto master, there should be some working tests that ensure this PR's changes work properly on all platforms.

@tomodachi94
Copy link
Member

@siraben: the author of CraftOS-PC has some release resources that includes a MacOS icon here; it might be worth taking a look.

@tomodachi94 tomodachi94 mentioned this pull request Jul 23, 2023
12 tasks
@tomodachi94 tomodachi94 added 2.status: work-in-progress 2.status: blocked by pr/issue Another PR or issue is preventing this from being completed and removed 2.status: blocked by pr/issue Another PR or issue is preventing this from being completed labels Jul 23, 2023
@tomodachi94
Copy link
Member

@siraben try rebasing your changes on top of master, the tests were broken but they have been fixed.

@siraben siraben force-pushed the craftos-pc-darwin branch from fea8eb4 to fac6260 Compare July 24, 2023 05:26
@ofborg ofborg bot requested a review from tomodachi94 July 24, 2023 05:46
Copy link
Member

@tomodachi94 tomodachi94 left a comment

Choose a reason for hiding this comment

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

Lgtm, sorry for taking so long.

@tomodachi94 tomodachi94 added the 12.approvals: 1 This PR was reviewed and approved by one person. label Aug 3, 2023
@siraben
Copy link
Member Author

siraben commented Oct 13, 2023

Can't merge ATM since it doesn't actually build on macOS yet.

@wegank wegank added the 2.status: stale https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md label Mar 19, 2024
@tomodachi94
Copy link
Member

Hopefully this is easier once MCJack123/craftos2#373 is merged.

@stale stale bot removed the 2.status: stale https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md label Sep 3, 2024
@wegank wegank added the 2.status: merge conflict This PR has merge conflicts with the target branch label Nov 9, 2024
@wegank wegank added the 2.status: stale https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md label Jan 2, 2025
@stale stale bot removed the 2.status: stale https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md label Jun 26, 2025
@nixpkgs-ci nixpkgs-ci bot added the 2.status: stale https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md label Jun 26, 2025
@siraben siraben marked this pull request as ready for review November 3, 2025 05:52
@siraben siraben requested a review from tomodachi94 November 3, 2025 05:55
@siraben siraben changed the title craftos-pc: support for darwin (WIP) craftos-pc: support for darwin Nov 3, 2025
@nixpkgs-ci nixpkgs-ci bot added 12.approved-by: package-maintainer This PR was reviewed and approved by a maintainer listed in any of the changed packages. 2.status: merge-bot eligible This PR can be merged by commenting "@NixOS/nixpkgs-merge-bot merge". and removed 2.status: merge conflict This PR has merge conflicts with the target branch 2.status: stale https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md 10.rebuild-darwin: 1 This PR causes 1 package to rebuild on Darwin. 10.rebuild-linux: 1 This PR causes 1 package to rebuild on Linux. labels Nov 3, 2025
Copy link
Member

@tomodachi94 tomodachi94 left a comment

Choose a reason for hiding this comment

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

Diff mostly lgtm, just one smaller thing to avoid unnecessary repetition.

@siraben
Copy link
Member Author

siraben commented Nov 11, 2025

@tomodachi94 let me know what you think

Copy link
Member

@tomodachi94 tomodachi94 left a comment

Choose a reason for hiding this comment

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

Diff lgtm. Thank you for putting in the effort to make this happen 💖

@siraben siraben added this pull request to the merge queue Nov 12, 2025
Merged via the queue into NixOS:master with commit a22570f Nov 12, 2025
30 of 32 checks passed
@siraben siraben deleted the craftos-pc-darwin branch November 12, 2025 07:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

2.status: merge-bot eligible This PR can be merged by commenting "@NixOS/nixpkgs-merge-bot merge". 6.topic: darwin Running or building packages on Darwin 8.has: package (new) This PR adds a new package 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. 11.by: package-maintainer This PR was created by a maintainer of all the package it changes. 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.

4 participants