27 lines
1.1 KiB
Bash
27 lines
1.1 KiB
Bash
#! /bin/bash
|
|
|
|
VERSIONEDNAME=$1
|
|
|
|
wget -N https://files.pythonhosted.org/packages/source/p/pyglet/${VERSIONEDNAME}.tar.gz
|
|
tar xzvf ${VERSIONEDNAME}.tar.gz
|
|
pushd ${VERSIONEDNAME}
|
|
rm -rvf examples # includes non-free artwork
|
|
rm -rvf tests # includes non-free font
|
|
rm -rvf tools # random developer tools (*)
|
|
rm -rvf contrib # again, questionable licensing
|
|
rm -v pyglet/image/codecs/s3tc.py # patent-encumbered algorithm (**)
|
|
rm -v pyglet/image/codecs/dds.py # image codec that uses s3tc (**)
|
|
popd
|
|
tar czvf ${VERSIONEDNAME}-repacked.tar.gz ${VERSIONEDNAME}
|
|
|
|
|
|
|
|
# (*) pyglet developers put random utilities in `tools`, without much
|
|
# regard to licenses. The development tree at 2012-10-19 included some GPL,
|
|
# for example. Given the project's culture, non-free code could be included
|
|
# in the future, so it's better to remove the directory to be on the safe side.
|
|
|
|
# (**) pyglet uses the patented S3 texture compression algorithm to
|
|
# encode/decode DirectX texture files (*.dds).
|
|
# Removing the two files disables the feature cleanly (see the guarded
|
|
# dss import in pyglet/image/codecs/__init__.py).
|