with import {}; let fhs = pkgs.buildFHSUserEnv { name = "myenv"; targetPkgs = pkgs: with pkgs; [ zlib SDL2 SDL2.dev SDL2_image SDL2_mixer libtool binutils cmake ]; runScript = "bash"; profile = " export LD_LIBRARY_PATH=/usr/lib:/usr/lib32 "; }; in pkgs.stdenv.mkDerivation { name = "myenv-shell"; nativeBuildInputs = [ fhs ]; shellHook = "exec myenv"; }