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

pipewire: fix build for FreeBSD #387712

Merged
merged 2 commits into from
Mar 23, 2025
Merged

pipewire: fix build for FreeBSD #387712

merged 2 commits into from
Mar 23, 2025

Conversation

rhelmot
Copy link
Contributor

@rhelmot rhelmot commented Mar 6, 2025

cc #328999

Not that I haven't booted a graphical environment with this yet - this is simply a dependency for openal-soft, which is a dependency of something else I wanted.

Things done

  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
    • x86_64-freebsd (cross)
  • 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/)
  • 25.05 Release Notes (or backporting 24.11 and 25.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.

Add a 👍 reaction to pull requests you find important.

@drupol

This comment was marked as resolved.

@rhelmot
Copy link
Contributor Author

rhelmot commented Mar 6, 2025

I have great news about which branch this already targets!

@drupol
Copy link
Contributor

drupol commented Mar 6, 2025

Oh sorry. Ignore my comment.

@K900
Copy link
Contributor

K900 commented Mar 6, 2025

I merged 1.4.0 to staging-next, which adds a few dependencies. Can you rebase on that?

@rhelmot
Copy link
Contributor Author

rhelmot commented Mar 7, 2025

92c7569 is already in this branch and pipewire is already 1.4.0.

- alsa-lib being present (detected during configure) results in the
  inclusion of sources which use linux-specific errno values
- revive several isLinux configuration predicates
@rhelmot rhelmot force-pushed the freebsd-pipewire branch from 2471de9 to 1dc5948 Compare March 7, 2025 05:50
systemd,
enableSystemd ? true, # enableSystemd=false maintained by maintainers.qyliss.
enableSystemd ? stdenv.hostPlatform.isLinux, # enableSystemd=false maintained by maintainers.qyliss.
Copy link
Contributor

Choose a reason for hiding this comment

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

Nit: should this maybe check if systemd is availableOn hostSystem?

ffadoSupport ?
x11Support
&& lib.systems.equals stdenv.buildPlatform stdenv.hostPlatform
&& stdenv.hostPlatform.isLinux,
Copy link
Contributor

Choose a reason for hiding this comment

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

Same here

@@ -65,6 +71,9 @@ let
webrtc-audio-processing_1
webrtc-audio-processing
];

bluezSupport = stdenv.hostPlatform.isLinux;
Copy link
Contributor

Choose a reason for hiding this comment

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

And maybe here? Unless those are available on BSD and you don't want them for whatever reason?

(lib.mesonEnable "docs" true)
(lib.mesonOption "udevrulesdir" "lib/udev/rules.d")
(lib.mesonEnable "installed_tests" true)
(lib.mesonOption "installed_test_prefix" (placeholder "installedTests"))
(lib.mesonOption "libjack-path" "${placeholder "jack"}/lib")
(lib.mesonEnable "echo-cancel-webrtc" (webrtc-audio-processings != [ ]))
(lib.mesonEnable "libcamera" true)
(lib.mesonEnable "libcamera" (lib.meta.availableOn stdenv.hostPlatform libcamera))
Copy link
Contributor

Choose a reason for hiding this comment

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

Could hoist this maybe

@rhelmot
Copy link
Contributor Author

rhelmot commented Mar 10, 2025

The only one of these I'm dead set on actually being isLinux is alsa, since even though that one can compile on freebsd, it pulls in pipewire source code which uses linuxisms, and less so, bluez, since it is several dependencies and I don't want the giant && chain. The others I will attempt to switch to isAvailable.

@drupol
Copy link
Contributor

drupol commented Mar 23, 2025

Status of this PR?

@rhelmot
Copy link
Contributor Author

rhelmot commented Mar 23, 2025

I believe I satisfied the requested changes.

@drupol
Copy link
Contributor

drupol commented Mar 23, 2025

@K900 Good for you?

@K900
Copy link
Contributor

K900 commented Mar 23, 2025

Sorry, lost track of this one. I'll take another look in a couple of hours.

@K900 K900 merged commit 482a6cc into NixOS:staging Mar 23, 2025
27 checks passed
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.

3 participants