From 4c7a5f76de115e1d1b4e8ddadb557e1e119b42b7 Mon Sep 17 00:00:00 2001 From: xapkohheh Date: Wed, 10 May 2023 17:26:21 +0200 Subject: [PATCH 1/6] houdini: expanded lists one entry per line for targetPkgs, executables - for simpler diffs --- pkgs/applications/misc/houdini/default.nix | 39 +++++++++++++++++++--- 1 file changed, 34 insertions(+), 5 deletions(-) diff --git a/pkgs/applications/misc/houdini/default.nix b/pkgs/applications/misc/houdini/default.nix index 9c560b7f8313..62e4630dc04f 100644 --- a/pkgs/applications/misc/houdini/default.nix +++ b/pkgs/applications/misc/houdini/default.nix @@ -4,11 +4,36 @@ buildFHSEnv rec { name = "houdini-${unwrapped.version}"; targetPkgs = pkgs: with pkgs; [ - libGLU libGL alsa-lib fontconfig zlib libpng dbus nss nspr expat pciutils - libxkbcommon libudev0-shim tbb + libGLU + libGL + alsa-lib + fontconfig + zlib + libpng + dbus + nss + nspr + expat + pciutils + libxkbcommon + libudev0-shim + tbb ] ++ (with xorg; [ - libICE libSM libXmu libXi libXext libX11 libXrender libXcursor libXfixes - libXrender libXcomposite libXdamage libXtst libxcb libXScrnSaver + libICE + libSM + libXmu + libXi + libXext + libX11 + libXrender + libXcursor + libXfixes + libXrender + libXcomposite + libXdamage + libXtst + libxcb + libXScrnSaver ]); passthru = { @@ -16,7 +41,11 @@ buildFHSEnv rec { }; extraInstallCommands = let - executables = [ "bin/houdini" "bin/hkey" "houdini/sbin/sesinetd" ]; + executables = [ + "bin/houdini" + "bin/hkey" + "houdini/sbin/sesinetd" + ]; in '' WRAPPER=$out/bin/${name} EXECUTABLES="${lib.concatStringsSep " " executables}" From 23b7205f46eb29b4e6e6e8d210dd6270e056c9d8 Mon Sep 17 00:00:00 2001 From: xapkohheh Date: Wed, 10 May 2023 20:20:44 +0200 Subject: [PATCH 2/6] houdini: added missing libs to targetPkgs --- pkgs/applications/misc/houdini/default.nix | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/pkgs/applications/misc/houdini/default.nix b/pkgs/applications/misc/houdini/default.nix index 62e4630dc04f..a1c78118e710 100644 --- a/pkgs/applications/misc/houdini/default.nix +++ b/pkgs/applications/misc/houdini/default.nix @@ -18,11 +18,19 @@ buildFHSEnv rec { libxkbcommon libudev0-shim tbb + xwayland + qt5.qtwayland + nettools # needed by licensing tools + bintools # needed for ld and other tools, so ctypes can find/load sos from python + ocl-icd # needed for opencl + numactl # needed by hfs ocl backend + ncurses5 # needed by hfs ocl backend ] ++ (with xorg; [ libICE libSM libXmu libXi + libXt libXext libX11 libXrender @@ -34,6 +42,14 @@ buildFHSEnv rec { libXtst libxcb libXScrnSaver + libXrandr + libxcb + xcbutil + xcbutilimage + xcbutilrenderutil + xcbutilcursor + xcbutilkeysyms + xcbutilwm ]); passthru = { From ca7cece9bf5b28b92f6ce5973db68d161e7ea526 Mon Sep 17 00:00:00 2001 From: xapkohheh Date: Wed, 10 May 2023 20:26:40 +0200 Subject: [PATCH 3/6] houdini: disabled dieWithParent, unsharePid Due to the nature of the software, it forks and expects children to outlive the parent, therefore dieWithParent needs to be disabled Also licensing mechanism seem to be checking processes for it's licensing helper process running. that process must be same for multiple instances of houdini itself, therefore Pid namespace has to be the same for all of them. --- pkgs/applications/misc/houdini/default.nix | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/pkgs/applications/misc/houdini/default.nix b/pkgs/applications/misc/houdini/default.nix index a1c78118e710..890a78b5d3ea 100644 --- a/pkgs/applications/misc/houdini/default.nix +++ b/pkgs/applications/misc/houdini/default.nix @@ -3,6 +3,12 @@ buildFHSEnv rec { name = "houdini-${unwrapped.version}"; + # houdini spawns hserver (and other license tools) that is supposed to live beyond the lifespan of houdini process + dieWithParent = false; + + # houdini needs to communicate with hserver process that it seem to be checking to be present in running processes + unsharePid = false; + targetPkgs = pkgs: with pkgs; [ libGLU libGL From f03311c6157211f881b5dde1650d1797ba084488 Mon Sep 17 00:00:00 2001 From: xapkohheh Date: Wed, 10 May 2023 20:31:54 +0200 Subject: [PATCH 4/6] houdini: exposed more executables houdini provides additional tools that might be useful --- pkgs/applications/misc/houdini/default.nix | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/misc/houdini/default.nix b/pkgs/applications/misc/houdini/default.nix index 890a78b5d3ea..433e90572024 100644 --- a/pkgs/applications/misc/houdini/default.nix +++ b/pkgs/applications/misc/houdini/default.nix @@ -64,8 +64,13 @@ buildFHSEnv rec { extraInstallCommands = let executables = [ - "bin/houdini" - "bin/hkey" + "bin/houdini" # houdini flavours + "bin/houdinicore" + "bin/houdinifx" + "bin/hgpuinfo" # houdini ocl config tool + "bin/hotl" # hda/otl manipulation tool + "bin/hython" # hython + "bin/hkey" # license administration "houdini/sbin/sesinetd" ]; in '' From af171a550170cca3d920b171244b91b83551a2f4 Mon Sep 17 00:00:00 2001 From: xapkohheh Date: Wed, 10 May 2023 20:34:46 +0200 Subject: [PATCH 5/6] houdini: added /etc/OpenCL/vendors binding additionally trying to bind /run/opengl-driver/etc/OpenCL/vendors -> /etc/OpenCL/vendors /etc/OpenCL/vendors -> /etc/OpenCL/vendors (for non NixOS) in wrapper to use opencl with houdini's own version of libOpenCL.so --- pkgs/applications/misc/houdini/default.nix | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/pkgs/applications/misc/houdini/default.nix b/pkgs/applications/misc/houdini/default.nix index 433e90572024..131cd28764ec 100644 --- a/pkgs/applications/misc/houdini/default.nix +++ b/pkgs/applications/misc/houdini/default.nix @@ -87,6 +87,11 @@ buildFHSEnv rec { chmod +x $EXECUTABLES ''; + extraBwrapArgs = [ + "--ro-bind-try /run/opengl-driver/etc/OpenCL/vendors /etc/OpenCL/vendors" # this is the case of NixOS + "--ro-bind-try /etc/OpenCL/vendors /etc/OpenCL/vendors" # this is the case of not NixOS + ]; + runScript = writeScript "${name}-wrapper" '' exec $@ ''; From cc63d32a0d03fe845f8f8be1bf9302f51c26afe4 Mon Sep 17 00:00:00 2001 From: xapkohheh Date: Wed, 10 May 2023 20:41:03 +0200 Subject: [PATCH 6/6] houdini: 18.5.596 -> 19.5.569 --- pkgs/applications/misc/houdini/runtime.nix | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/pkgs/applications/misc/houdini/runtime.nix b/pkgs/applications/misc/houdini/runtime.nix index 4fb2d91b99f4..2f218781abb6 100644 --- a/pkgs/applications/misc/houdini/runtime.nix +++ b/pkgs/applications/misc/houdini/runtime.nix @@ -4,11 +4,11 @@ let license_dir = "~/.config/houdini"; in stdenv.mkDerivation rec { - version = "18.5.596"; + version = "19.5.569"; pname = "houdini-runtime"; src = requireFile rec { - name = "houdini-py3-${version}-linux_x86_64_gcc6.3.tar.gz"; - sha256 = "1b1k7rkn7svmciijqdwvi9p00srsf81vkb55grjg6xa7fgyidjx1"; + name = "houdini-${version}-linux_x86_64_gcc9.3.tar.gz"; + sha256 = "0c2d6a31c24f5e7229498af6c3a7cdf81242501d7a0792e4c33b53a898d4999e"; url = meta.homepage; }; @@ -22,9 +22,9 @@ stdenv.mkDerivation rec { --no-install-bin-symlink \ --auto-install \ --no-root-check \ - --accept-EULA 2020-05-05 \ + --accept-EULA 2021-10-13 \ $out - echo "licensingMode = localValidator" >> $out/houdini/Licensing.opt + echo "licensingMode = localValidator" >> $out/houdini/Licensing.opt # does not seem to do anything any more. not sure, official docs do not say anything about it ''; dontFixup = true;