nixpkgs icon indicating copy to clipboard operation
nixpkgs copied to clipboard

ondsel: init at 2024.1.0

Open pinpox opened this issue 1 year ago • 4 comments

Description of changes

Alternative build for https://github.com/NixOS/nixpkgs/pull/284996 This PR builds ondsel from source instead of using the appimage.

I added the package next to freecad since it is a fork and shares most of its derivation.

Fixes: https://github.com/NixOS/nixpkgs/issues/284524

Things done

  • Built on platform(s)
    • [x] 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
  • [x] Fits CONTRIBUTING.md.

Add a :+1: reaction to pull requests you find important.

pinpox avatar Mar 03 '24 11:03 pinpox

@ofborg build ondsel

pinpox avatar Mar 03 '24 19:03 pinpox

For some reason, it seems to start freecad when running the executable inside result, even though the correct source is pulled and build. I can't really figure out why, does anyone have ideas and could help?

pinpox avatar Mar 04 '24 23:03 pinpox

how do you expect to distinguish freecad and ondsel?

viric avatar Mar 05 '24 20:03 viric

how do you expect to distinguish freecad and ondsel?

The ui looks completely different and also freecad shows a "FREECAD" as ascii art in the terminal when starting and ondsel shows ONDSEL

See here for an example of the ascii art shown: https://github.com/NixOS/nixpkgs/pull/284996#issuecomment-1962961798

pinpox avatar Mar 05 '24 21:03 pinpox

After moving it to pkgs/by-name/on/ondsel/package.nix, Ondsel builds correctly (and that's also the correct place for the package).

As for the Ondsel branding and splash screen: That one doesn't seem to be part of the Ondsel Repo, but patched in afterwards. Whenever you build their source, you get FreeCAD + patches instead. So Ondsel pretending to be Freecad 0.22 is correct. You can confirm that you're running the correct build by checking if the Assembly workbench is available.

Haven't used Ondsel yet, but it seems like some of their code isn't publicly available.

Edit: Branding stuff can be found here and needs to be applied separately: https://github.com/Ondsel-Development/freecad-feedstock

Hayajiro avatar Mar 10 '24 15:03 Hayajiro

ah nice I didn't know the by-name thing.

viric avatar Mar 10 '24 21:03 viric

Edit: Branding stuff can be found here and needs to be applied separately: https://github.com/Ondsel-Development/freecad-feedstock

I don't know enough about conda to apply those steps to the nix package build. Maybe it's easier then to continue work on the PR based on the appimage since that one has everything setup?

It might be "just" a bit of branding, but the user experience and UI is completely different and defaults setup better, which is one of the main appeals of ondsel vs. freecad.

If you have any pointers on how to apply the changes in the build of the package let me know.

I also asked @adrianinsaval over on discord, who seems to be doing the builds for the releases but haven't got any instructions on how to build ondsel from source correctly.

pinpox avatar Mar 11 '24 09:03 pinpox

The branding for Ondsel seems to be applied in the file recipe/build.sh form line 75 on. Maybe you could clone the repo (or just the branding folder)...

b-eyselein avatar Mar 11 '24 10:03 b-eyselein

https://github.com/Ondsel-Development/freecad-feedstock/blob/main/recipe%2Fbuild.sh#L75-L82

This is probably what you are missing

adrianinsaval avatar Mar 11 '24 11:03 adrianinsaval

You should also add the additional addons: https://github.com/Ondsel-Development/FreeCAD-Bundle/blob/main/conda%2Flinux%2Fcreate_bundle.sh#L33-L34 https://github.com/Ondsel-Development/FreeCAD-Bundle/blob/main/conda/scripts/install_addons.py

With the additional dependencies for Ondsel-Lens: https://github.com/Ondsel-Development/FreeCAD-Bundle/blob/458e637ab6bbceeb5fa7ab8faabb987a329ae9c4/conda/linux/create_bundle.sh#L15

adrianinsaval avatar Mar 11 '24 11:03 adrianinsaval

@b-eyselein @adrianinsaval Thansk for the pointers, that should help!

I'm also missing the Ondsel-defaults.cfg file from here

I'll try to figure out where and how I'll have to place that inside the package

pinpox avatar Mar 11 '24 13:03 pinpox

@b-eyselein @adrianinsaval I've added the branding and defaults and now the UI looks as expected :partying_face: !

Not sure how to add the additional addons though, maybe someone can help out. Is it only the first run wizard from here ?

pinpox avatar Mar 11 '24 17:03 pinpox

Do you need any help with moving this forward? I think that the only diff required is to move it to by-name

cab404 avatar May 12 '24 04:05 cab404

Do you need any help with moving this forward? I think that the only diff required is to move it to by-name

I'm not installing any additional addons yet. Could you test/verify if anything is missing? I'll move it then when it's considered ready

pinpox avatar May 13 '24 08:05 pinpox

@b-eyselein @adrianinsaval I've added the branding and defaults and now the UI looks as expected 🥳 !

Not sure how to add the additional addons though, maybe someone can help out. Is it only the first run wizard from here ?

it apparently first installs firstrun, and then installs everything under it — https://github.com/Ondsel-Development/Ondsel-FirstRun/blob/main/mods.json

cab404 avatar May 23 '24 21:05 cab404

it apparently first installs firstrun, and then installs everything under it — https://github.com/Ondsel-Development/Ondsel-FirstRun/blob/main/mods.json

Is there anything from this I have to add to the derivation?

pinpox avatar Jun 11 '24 09:06 pinpox