So I’ve been banging my head on this for a while now and I’m not even sure how to ask the question, but anyway:
Let’s say I have a derivation for a python package looking like so:
{
python,
buildPythonPackage,
fetchFromGitHub,
setuptools,
}:
buildPythonPackage {
pname = “xrt”;
version = “1.6.1”;
src = fetchFromGitHub {
owner = “kklmn”;
repo = “xrt”;
rev = “43a229b98c49669378e2e2127ba00ac9217de451”;
sha256 = “sha256-BfMfAx/sN3Uf/JxY41DzDce0yAotFeI9o//wINeOVEM=”;
};
pyproject = true;
build-system = [ setuptools ];
postInstall = ‘’
makeWrapper $out/bin/xrtQookStart.py $out/bin/xrtQook --run “chmod -R 777 $HOME/.xrt”
makeWrapper ${python.interpreter} $out/bin/xrtBentXtal
–add-flags “$out/lib/python3.12/site-packages/xrt/gui/xrtBentXtal.py”
–run “chmod -R 777 $HOME/.xrt”
‘’;
}
This derivation is the first in my future collection of packages that should have the same interface as nixpkgs. I’ve called it glebpkgs and the repo is here: GitHub - glebdovzhenko/glebpkgs · GitHub
But! The only way I figured out how to add this derivation to a dev env flake is so:
let
pkgs = import nixpkgs { inherit overlays system; };
gpkgs = import glebpkgs { };
in
{
devShells.default = pkgs.mkShell {
name = “skif-xrt”;
venvDir = “./.venv”;
nativeBuildInputs = with pkgs; [
qt5.qttools.dev
cmake
blas
];
buildInputs =
with pkgs.python312Packages;
[
python
venvShellHook
] ++ [ (callPackage gpkgs.xrt_1 { }) ];
};
What i want is this:
buildInputs =
with pkgs.python312Packages;
[
python
venvShellHook
]
++ [ gpkgs.xrt_1 ];
What am I missing? I feel like there’s just one step left to make, but I don’t have enough experience to even google it. So any help wuld be appreciated and thanks in advance!