diff --git a/pkgs/by-name/li/libvncserver/package.nix b/pkgs/by-name/li/libvncserver/package.nix index 510717cfcc4d..0d6b14a8fcf1 100644 --- a/pkgs/by-name/li/libvncserver/package.nix +++ b/pkgs/by-name/li/libvncserver/package.nix @@ -10,6 +10,8 @@ libpng, withSystemd ? lib.meta.availableOn stdenv.hostPlatform systemd, systemd, + + enableShared ? !stdenv.hostPlatform.isStatic, }: stdenv.mkDerivation (finalAttrs: { @@ -37,7 +39,10 @@ stdenv.mkDerivation (finalAttrs: { cmake ]; - cmakeFlags = [ (lib.cmakeBool "WITH_SYSTEMD" withSystemd) ]; + cmakeFlags = [ + (lib.cmakeBool "WITH_SYSTEMD" withSystemd) + (lib.cmakeBool "BUILD_SHARED_LIBS" enableShared) + ]; buildInputs = [