I try to start sclang of supercollider from a flake it seems it need qt to run.
How do I pass those information into a flake?
When sclang started from a flake it fails with the following output:
warning: creating lock file '/home/olaf/github/qtflake/flake.lock'
compiling class library...
qt.qpa.plugin: Could not find the Qt platform plugin "wayland" in ""
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.
Available platform plugins are: eglfs, linuxfb, minimal, minimalegl, offscreen, vnc, xcb.
/nix/store/ariv3k47kf8k782bjkfaziiy49p1k36r-test/bin/test: line 8: 406414 Aborted (core dumped) sclang
so it seems i need to pass some information regarding qt and wayland from my system to the shell that runs sclang.
here is the flake:
{
description = "test";
inputs = {
nixpkgs.url = "github:nixOS/nixpkgs";
flake-utils.url = "github:numtide/flake-utils";
};
outputs = { self, nixpkgs, flake-utils }:
flake-utils.lib.eachDefaultSystem (system:
let
pkgs = import nixpkgs { inherit system; };
in
{
packages.test = pkgs.writeShellApplication {
name = "test";
runtimeInputs = with pkgs; [ supercollider ];
text = ''
sclang
'';
};
apps.default = {
type = "app";
program = "${self.packages.${system}.test}/bin/test";
};
});
}