# Description: A collection of tools for internationalizing Python applications # URL: http://babel.pocoo.org/ # Maintainer: Tim Biermann, tbier at posteo dot de # Depends on: python3-pytz python3-setuptools babel name=python3-babel version=2.7.0 release=1 source=(https://github.com/python-babel/babel/archive/v$version/$name-$version.tar.gz https://unicode.org/Public/cldr/35.1/cldr-common-35.1.zip) unpack_source() { for file in ${source[@]}; do case ${file##*/} in $name-$version.tar.gz) bsdtar -p -o -C $SRC -xf $(get_filename $file) ;; cldr-common-35.1.zip) mkdir $SRC/babel-$version/cldr || true cp $(get_filename $file) $SRC/babel-$version/cldr/cldr-core-35.1.zip bsdtar -p -o -C $SRC/babel-$version/cldr -xf $(get_filename $file);; *) cp $(get_filename $file) $SRC ;; esac done } build() { cd babel-$version python3 setup.py import_cldr python3 setup.py build python3 setup.py install --root=$PKG \ --optimize=1 \ --skip-build mv $PKG/usr/bin/pybabel $PKG/usr/bin/py3babel }