push sheeet
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s

This commit is contained in:
Dark Steveneq
2025-10-09 14:15:47 +02:00
commit 646b892680
49168 changed files with 5897842 additions and 0 deletions

View File

@@ -0,0 +1,88 @@
{
lib,
stdenv,
fetchFromGitHub,
fetchpatch,
cmake,
libjpeg,
openssl,
zlib,
libgcrypt,
libpng,
withSystemd ? lib.meta.availableOn stdenv.hostPlatform systemd,
systemd,
enableShared ? !stdenv.hostPlatform.isStatic,
buildExamples ? false,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "libvncserver";
version = "0.9.15";
outputs = [
"out"
"dev"
];
src = fetchFromGitHub {
owner = "LibVNC";
repo = "libvncserver";
tag = "LibVNCServer-${finalAttrs.version}";
hash = "sha256-a3acEjJM+ZA9jaB6qZ/czjIfx/L3j71VjJ6mtlqYcSw=";
};
patches = [
# fix generated pkg-config files
./pkgconfig.patch
(fetchpatch {
name = "libvncserver-fix-cmake-4.patch";
url = "https://github.com/LibVNC/libvncserver/commit/e64fa928170f22a2e21b5bbd6d46c8f8e7dd7a96.patch";
hash = "sha256-AAZ3H34+nLqQggb/sNSx2gIGK96m4zatHX3wpyjNLOA=";
})
];
nativeBuildInputs = [
cmake
];
cmakeFlags = [
(lib.cmakeBool "WITH_SYSTEMD" withSystemd)
(lib.cmakeBool "BUILD_SHARED_LIBS" enableShared)
(lib.cmakeBool "WITH_EXAMPLES" buildExamples)
(lib.cmakeBool "WITH_TESTS" finalAttrs.doCheck)
];
# This test checks if using the **installed** headers works.
# As it doesn't set the include paths correctly, and we have nixpkgs-review to check if
# packages continue to build, patching it would serve no purpose, so we can just remove the test entirely.
postPatch = ''
substituteInPlace CMakeLists.txt \
--replace-fail 'add_test(NAME includetest COMMAND' '# add_test(NAME includetest COMMAND'
'';
buildInputs = [
libjpeg
openssl
libgcrypt
libpng
]
++ lib.optionals withSystemd [
systemd
];
propagatedBuildInputs = [
zlib
];
doCheck = enableShared;
meta = with lib; {
description = "VNC server library";
homepage = "https://libvnc.github.io/";
license = licenses.gpl2Plus;
maintainers = with maintainers; [ raskin ];
platforms = platforms.unix;
};
})

View File

@@ -0,0 +1,28 @@
diff --git a/src/libvncclient/libvncclient.pc.cmakein b/src/libvncclient/libvncclient.pc.cmakein
index ceeda39d..2516e643 100644
--- a/src/libvncclient/libvncclient.pc.cmakein
+++ b/src/libvncclient/libvncclient.pc.cmakein
@@ -1,7 +1,7 @@
prefix=@CMAKE_INSTALL_PREFIX@
exec_prefix=@CMAKE_INSTALL_PREFIX@
-libdir=@CMAKE_INSTALL_PREFIX@/@CMAKE_INSTALL_LIBDIR@
-includedir=@CMAKE_INSTALL_PREFIX@/include
+libdir=@CMAKE_INSTALL_FULL_LIBDIR@
+includedir=@CMAKE_INSTALL_FULL_INCLUDEDIR@
Name: LibVNCClient
Description: A library for easy implementation of a VNC client.
diff --git a/src/libvncserver/libvncserver.pc.cmakein b/src/libvncserver/libvncserver.pc.cmakein
index 33ec6685..57244742 100644
--- a/src/libvncserver/libvncserver.pc.cmakein
+++ b/src/libvncserver/libvncserver.pc.cmakein
@@ -1,7 +1,7 @@
prefix=@CMAKE_INSTALL_PREFIX@
exec_prefix=@CMAKE_INSTALL_PREFIX@
-libdir=@CMAKE_INSTALL_PREFIX@/@CMAKE_INSTALL_LIBDIR@
-includedir=@CMAKE_INSTALL_PREFIX@/include
+libdir=@CMAKE_INSTALL_FULL_LIBDIR@
+includedir=@CMAKE_INSTALL_FULL_INCLUDEDIR@
Name: LibVNCServer
Description: A library for easy implementation of a VNC server.