13 pythonPackages ? null,
17 stdenv.mkDerivation (finalAttrs: {
22 url = "https://www.efficios.com/files/babeltrace/babeltrace-${finalAttrs.version}.tar.bz2";
23 hash = "sha256-Z7Q6qu9clR+nrxpVfPcgGhH+iYdrfCK6CgPLwxbbWpw=";
28 # The pre-generated ./configure script uses an old autoconf version which
29 # breaks cross-compilation (replaces references to malloc with rpl_malloc).
30 # Re-generate with nixpkgs's autoconf. This requires glib to be present in
31 # nativeBuildInputs for its m4 macros to be present.
36 ++ lib.optionals enablePython [
38 pythonPackages.setuptools
49 # --enable-debug-info (default) requires the configure script to run host
50 # executables to determine the elfutils library version, which cannot be done
51 # while cross compiling.
52 (lib.enableFeature (stdenv.hostPlatform == stdenv.buildPlatform) "debug-info")
54 ++ lib.optionals enablePython [
55 # Using (lib.enableFeature enablePython "python-bindings") makes the
56 # configure script look for python dependencies even when
57 # enablePython==false. Adding the configure flag conditionally seems to
59 "--enable-python-bindings"
63 passthru.updateScript = gitUpdater {
64 url = "https://git.efficios.com/babeltrace.git";
66 # Versions 2.x are packaged independently as babeltrace2
67 allowedVersions = "^1\\.";
71 description = "Command-line tool and library to read and convert LTTng tracefiles";
72 homepage = "https://www.efficios.com/babeltrace";
73 license = lib.licenses.mit;
74 platforms = lib.platforms.linux;
75 maintainers = with lib.maintainers; [