2021-02-05 17:12:51 +00:00
|
|
|
{ lib, stdenv
|
2020-04-24 23:36:52 +00:00
|
|
|
, fetchurl
|
|
|
|
, meson
|
|
|
|
, ninja
|
2021-02-05 17:12:51 +00:00
|
|
|
, pkg-config
|
2020-04-24 23:36:52 +00:00
|
|
|
, pixman
|
2021-06-28 23:13:55 +00:00
|
|
|
, alsa-lib
|
2020-04-24 23:36:52 +00:00
|
|
|
, openssl
|
|
|
|
, libXrandr
|
|
|
|
, libXfixes
|
|
|
|
, libXext
|
|
|
|
, libXrender
|
|
|
|
, libXinerama
|
|
|
|
, libjpeg
|
|
|
|
, zlib
|
|
|
|
, spice-protocol
|
|
|
|
, python3
|
|
|
|
, glib
|
|
|
|
, cyrus_sasl
|
|
|
|
, libcacard
|
|
|
|
, lz4
|
|
|
|
, libopus
|
|
|
|
, gst_all_1
|
|
|
|
, orc
|
2022-11-04 12:27:35 +00:00
|
|
|
, gdk-pixbuf
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
2021-12-06 16:07:01 +00:00
|
|
|
let
|
|
|
|
# This file was mistakenly not included with the 0.15.0 release tarball.
|
|
|
|
# Should be fixed with the next release.
|
|
|
|
# https://gitlab.freedesktop.org/spice/spice/-/issues/56
|
|
|
|
doxygen_sh = fetchurl {
|
|
|
|
url = "https://gitlab.freedesktop.org/spice/spice/-/raw/v0.15.0/doxygen.sh";
|
|
|
|
sha256 = "0g4bx91qclihp1jfhdhyj7wp4hf4289794xxbw32kk58lnd7bzkg";
|
|
|
|
};
|
|
|
|
in
|
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "spice";
|
2021-06-28 23:13:55 +00:00
|
|
|
version = "0.15.0";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
2021-06-28 23:13:55 +00:00
|
|
|
url = "https://www.spice-space.org/download/releases/spice-server/${pname}-${version}.tar.bz2";
|
|
|
|
sha256 = "1xd0xffw0g5vvwbq4ksmm3jjfq45f9dw20xpmi82g1fj9f7wy85k";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2022-11-04 12:27:35 +00:00
|
|
|
patches = [
|
|
|
|
./remove-rt-on-darwin.patch
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
postPatch = ''
|
2021-12-06 16:07:01 +00:00
|
|
|
install ${doxygen_sh} doxygen.sh
|
2020-04-24 23:36:52 +00:00
|
|
|
patchShebangs build-aux
|
2022-02-10 20:34:41 +00:00
|
|
|
|
|
|
|
# https://gitlab.freedesktop.org/spice/spice-common/-/issues/5
|
|
|
|
substituteInPlace subprojects/spice-common/meson.build \
|
|
|
|
--replace \
|
|
|
|
"cmd = run_command(python, '-m', module)" \
|
|
|
|
"cmd = run_command(python, '-c', 'import @0@'.format(module))"
|
2020-04-24 23:36:52 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
2021-12-06 16:07:01 +00:00
|
|
|
glib
|
2020-04-24 23:36:52 +00:00
|
|
|
meson
|
|
|
|
ninja
|
2021-02-05 17:12:51 +00:00
|
|
|
pkg-config
|
2020-04-24 23:36:52 +00:00
|
|
|
python3
|
|
|
|
python3.pkgs.six
|
|
|
|
python3.pkgs.pyparsing
|
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
cyrus_sasl
|
|
|
|
glib
|
|
|
|
gst_all_1.gst-plugins-base
|
|
|
|
libXext
|
|
|
|
libXfixes
|
|
|
|
libXinerama
|
|
|
|
libXrandr
|
|
|
|
libXrender
|
|
|
|
libcacard
|
|
|
|
libjpeg
|
|
|
|
libopus
|
|
|
|
lz4
|
|
|
|
openssl
|
|
|
|
orc
|
|
|
|
pixman
|
|
|
|
python3.pkgs.pyparsing
|
2021-12-06 16:07:01 +00:00
|
|
|
spice-protocol
|
2020-04-24 23:36:52 +00:00
|
|
|
zlib
|
2022-11-04 12:27:35 +00:00
|
|
|
] ++ lib.optionals stdenv.isLinux [
|
|
|
|
alsa-lib
|
|
|
|
] ++ lib.optionals stdenv.isDarwin [
|
|
|
|
gdk-pixbuf
|
2020-04-24 23:36:52 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
NIX_CFLAGS_COMPILE = "-fno-stack-protector";
|
|
|
|
|
|
|
|
mesonFlags = [
|
|
|
|
"-Dgstreamer=1.0"
|
|
|
|
];
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
ln -s spice-server $out/include/spice
|
|
|
|
'';
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Complete open source solution for interaction with virtualized desktop devices";
|
|
|
|
longDescription = ''
|
|
|
|
The Spice project aims to provide a complete open source solution for interaction
|
|
|
|
with virtualized desktop devices.The Spice project deals with both the virtualized
|
|
|
|
devices and the front-end. Interaction between front-end and back-end is done using
|
|
|
|
VD-Interfaces. The VD-Interfaces (VDI) enable both ends of the solution to be easily
|
|
|
|
utilized by a third-party component.
|
|
|
|
'';
|
|
|
|
homepage = "https://www.spice-space.org/";
|
|
|
|
license = licenses.lgpl21;
|
|
|
|
|
2022-11-04 12:27:35 +00:00
|
|
|
maintainers = with maintainers; [ bluescreen303 atemu ];
|
|
|
|
platforms = with platforms; linux ++ darwin;
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|