Untitled

mail@pastecode.io avatar
unknown
nix
7 months ago
2.3 kB
2
Indexable
Never
# error:
# error: builder for '/nix/store/xfsgn494zn2a96gy04s6pfnj7sz2hlic-python3.10-lws-1.2.8.drv' failed with exit code 1;
#        last 10 log lines:
#        > running build_ext
#        > building 'lws' extension
#        > creating build
#        > creating build/temp.linux-x86_64-cpython-310
#        > creating build/temp.linux-x86_64-cpython-310/lwslib
#        > g++ -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -I/nix/store/jh2dj172jmmlw74kw4bsqa5ycf1blv4v-libxcrypt-4.4.36/include -fPIC -Ilwslib/ -I/nix/store/1ir112jvygv9gg2x2cq451cr9l5ydhf1-python3.10-numpy-1.26.1/lib/python3.10/site-packages/numpy/core/include -I/nix/store/l8d6q4y9cvp2d5qf2sxxj072668bfcjr-python3-3.10.13/include/python3.10 -c lws.bycython.cpp -o build/temp.linux-x86_64-cpython-310/lws.bycython.o -O3
#        > cc1plus: fatal error: lws.bycython.cpp: No such file or directory
#        > compilation terminated.
#        > error: command '/nix/store/sfgnb6rr428bssyrs54d6d0vv2avi95c-gcc-wrapper-12.3.0/bin/g++' failed with exit code 1
#        > /nix/store/d4jf1cbbk494zwgbqz31pxgigpsbh6w2-stdenv-linux/setup: line 1553: pop_var_context: head of shell_variables not a function context
#        For full logs, run 'nix log /nix/store/xfsgn494zn2a96gy04s6pfnj7sz2hlic-python3.10-lws-1.2.8.drv'.

{ pkgs ? import (fetchTarball "https://github.com/NixOS/nixpkgs/archive/55520e0602239cf57799cc5eebcac2712b5728eb.tar.gz") {overlays = [(final: prev: { cudaPackages = prev.cudaPackages_12; })];} }:

with pkgs;

python310Packages.buildPythonPackage rec {
  pname = "lws";
  version = "1.2.8"; # replace with the actual version
  format = "setuptools";

  src = fetchFromGitHub {
    owner = "Jonathan-LeRoux";
    repo = pname;
    rev = "v${version}";
    sha256 = "sha256-vOJY1qd+7KuYKo1KaqqDD0B7BEST4tHNba0RaqRnYgM=";
  };
  nativeBuildInputs = with pkgs; [
    automake
    python310Packages.cython_3
    python310Packages.setuptools
  ];

  buildInputs = [
    python310Packages.numpy
  ];

  postPatch = ''
    cd python
  '';
  
  meta = with lib; {
    description = "Short description of the package"; # replace with actual description
    homepage = "https://github.com/Jonathan-LeRoux/lws";
    license = licenses.mit; # replace with the actual license
  };
}
Leave a Comment