python3Packages.antlr4-python3-runtime: fix build

This commit is contained in:
Nick Cao 2023-06-19 17:25:01 +08:00
parent 5ca54e9579
commit 061398e505
No known key found for this signature in database

View file

@ -1,17 +1,27 @@
{ lib
, buildPythonPackage
, isPy3k
, setuptools
, python
, antlr4 }:
, antlr4
}:
buildPythonPackage rec {
pname = "antlr4-python3-runtime";
inherit (antlr4.runtime.cpp) version src;
format = "pyproject";
disabled = python.pythonOlder "3.6";
sourceRoot = "${src.name}/runtime/Python3";
# in 4.9, test was renamed to tests
nativeBuildInputs = [
setuptools
];
# We use an asterisk because this expression is used also for old antlr
# versions, where there the tests directory is `test` and not `tests`.
# See e.g in package `baserow`.
checkPhase = ''
cd test*
${python.interpreter} run.py