2021-01-21 17:00:13 +00:00
|
|
|
{lib, stdenv, fetchurl, gettext, python3}:
|
2009-04-17 16:08:14 +01:00
|
|
|
|
2010-12-14 10:21:38 +00:00
|
|
|
stdenv.mkDerivation rec {
|
2019-08-15 13:41:18 +01:00
|
|
|
pname = "iso-codes";
|
2021-03-11 17:02:06 +00:00
|
|
|
version = "4.6.0";
|
2017-03-14 01:29:03 +00:00
|
|
|
|
2009-04-17 16:08:14 +01:00
|
|
|
src = fetchurl {
|
2019-08-31 00:57:29 +01:00
|
|
|
url = "https://salsa.debian.org/iso-codes-team/iso-codes/-/archive/${pname}-${version}/${pname}-${pname}-${version}.tar.bz2";
|
2021-03-11 17:02:06 +00:00
|
|
|
sha256 = "sha256-Ivd5538QpTFXP2r6ca/g12IZ0ZW1nduu0z4kiSb9Mxs=";
|
2009-04-17 16:08:14 +01:00
|
|
|
};
|
2019-05-07 01:58:25 +01:00
|
|
|
|
2009-04-17 16:08:14 +01:00
|
|
|
patchPhase = ''
|
|
|
|
for i in `find . -name \*.py`
|
|
|
|
do
|
2017-03-14 01:29:03 +00:00
|
|
|
sed -i -e "s|#!/usr/bin/env python|#!${python3}/bin/python|" $i
|
2009-04-17 16:08:14 +01:00
|
|
|
done
|
|
|
|
'';
|
2019-05-07 01:58:25 +01:00
|
|
|
|
|
|
|
nativeBuildInputs = [ gettext python3 ];
|
2010-12-14 10:21:38 +00:00
|
|
|
|
2021-01-21 17:00:13 +00:00
|
|
|
meta = with lib; {
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://salsa.debian.org/iso-codes-team/iso-codes";
|
2010-12-14 10:21:38 +00:00
|
|
|
description = "Various ISO codes packaged as XML files";
|
2018-09-02 19:13:36 +01:00
|
|
|
license = licenses.lgpl21;
|
2017-03-14 01:29:03 +00:00
|
|
|
platforms = platforms.all;
|
2010-12-14 10:21:38 +00:00
|
|
|
};
|
2009-04-17 16:08:14 +01:00
|
|
|
}
|