Unverified Commit 5bc5fcbf authored by Martin Weinelt's avatar Martin Weinelt
Browse files

python311Packages.holidays: generate l10n files

The localization files were previously missing, which led to issues
in the home-assistant workday component.
parent 4e417815
Loading
Loading
Loading
Loading
+31 −10
Original line number Diff line number Diff line
{ lib
, buildPythonPackage
, convertdate
, fetchFromGitHub
, hijri-converter
, importlib-metadata
, korean-lunar-calendar
, polib
, pytestCheckHook
, python-dateutil
, pythonOlder

# build-system
, setuptools

# l10n
, polib
, lingua
, chameleon

# dependencies
, python-dateutil

# tests
, importlib-metadata
, pytestCheckHook
}:

buildPythonPackage rec {
@@ -28,15 +35,29 @@ buildPythonPackage rec {

  nativeBuildInputs = [
    setuptools

    # l10n
    lingua
    chameleon
    polib
  ];

  postPatch = ''
    patchShebangs scripts/l10n/*.py
  '';

  preBuild = ''
    # make l10n
    ./scripts/l10n/generate_po_files.py
    ./scripts/l10n/generate_mo_files.py
  '';

  propagatedBuildInputs = [
    convertdate
    python-dateutil
    hijri-converter
    korean-lunar-calendar
  ];

  doCheck = false;

  nativeCheckInputs = [
    importlib-metadata
    polib