Skip to content

Commit

Permalink
samba: fix darwin
Browse files Browse the repository at this point in the history
the cups headers are part of the sdk but the library is not, which
causes configure to detect cups but the build fails with a link error.
explicitly enable / disable cups based on `enablePrinting` flag.
  • Loading branch information
paparodeo committed Oct 26, 2024
1 parent 4b8e58e commit 7014b40
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pkgs/servers/samba/4.x.nix
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ stdenv.mkDerivation (finalAttrs: {
++ optionals stdenv.hostPlatform.isDarwin [ libiconv ]
++ optionals enableLDAP [ openldap.dev python3Packages.markdown ]
++ optionals (!enableLDAP && stdenv.hostPlatform.isLinux) [ ldb talloc tevent ]
++ optional (enablePrinting && stdenv.hostPlatform.isLinux) cups
++ optional enablePrinting cups
++ optional enableMDNS avahi
++ optionals enableDomainController [ gpgme lmdb python3Packages.dnspython ]
++ optional enableRegedit ncurses
Expand Down Expand Up @@ -160,6 +160,7 @@ stdenv.mkDerivation (finalAttrs: {
"--sysconfdir=/etc"
"--localstatedir=/var"
"--disable-rpath"
(lib.enableFeature enablePrinting "cups")
] ++ optional (!enableDomainController)
"--without-ad-dc"
++ optionals (!enableLDAP) [
Expand Down

0 comments on commit 7014b40

Please sign in to comment.