Hello,
I’m trying to make the Tiled map editor export a map file in a nix script. I get a segmentation fault when trying in a script, while in my shell this works flawlessly. Here’s a minimal example:
with import <nixpkgs> {};
stdenv.mkDerivation rec {
name = "test";
buildInputs = with pkgs; [ tiled xvfb_run ];
src = ./.;
QT_PLUGIN_PATH = pkgs.qt5.qtbase.bin + "/" + pkgs.qt5.qtbase.qtPluginPrefix;
buildPhase = ''
xvfb-run tiled --export-map $src/map.tmx map.lua
'';
}
I’m using some QT_PLUGIN_PATH magic because otherwise xcb is not found. Running that example produces /nix/store/qcm3sk20a0wnnf0y1vnz1c4rsj40wb7r-xvfb-run/bin/.xvfb-run-wrapped: line 170: 552 Segmentation fault DISPLAY=:$SERVERNUM XAUTHORITY=$AUTHFILE "$@" 2>&1
. I’m not sure if this is a bug in xvfb, tiled, or my own configuration.
Cheers