| 1 |
#!/usr/bin/make -f
|
| 2 |
|
| 3 |
DEB_PYTHON_SYSTEM := pysupport
|
| 4 |
DEB_PYTHON_MODULE_PACKAGE = python-django
|
| 5 |
#DEB_DH_COMPRESS_ARGS = -X.js
|
| 6 |
|
| 7 |
include /usr/share/cdbs/1/rules/buildcore.mk
|
| 8 |
include /usr/share/cdbs/1/rules/debhelper.mk
|
| 9 |
include /usr/share/cdbs/1/class/python-distutils.mk
|
| 10 |
include /usr/share/cdbs/1/rules/simple-patchsys.mk
|
| 11 |
|
| 12 |
build/python-django::
|
| 13 |
# Build HTML documentation
|
| 14 |
cd docs && make html
|
| 15 |
|
| 16 |
binary-post-install/python-django::
|
| 17 |
# Use default python shebang
|
| 18 |
perl -pi -e 's|^#!/usr/bin/env python.*$$|#!/usr/bin/python|' debian/python-django/usr/share/python-support/python-django/django/conf/project_template/manage.py
|
| 19 |
# Ensure executability of some scripts that are copied to projects
|
| 20 |
# (or used within projects)
|
| 21 |
chmod 755 debian/python-django/usr/share/python-support/python-django/django/conf/project_template/manage.py
|
| 22 |
chmod 755 debian/python-django/usr/share/python-support/python-django/django/bin/[^_]*.py
|
| 23 |
chmod 755 debian/python-django/usr/share/python-support/python-django/django/bin/profiling/[^_]*.py
|
| 24 |
# Create convenience symlink
|
| 25 |
mkdir -p debian/python-django/usr/lib/python-django
|
| 26 |
dh_link usr/share/python-support/python-django/django/bin usr/lib/python-django/bin
|
| 27 |
# Rename django-admin.py to django-admin
|
| 28 |
mv debian/python-django/usr/bin/django-admin.py debian/python-django/usr/bin/django-admin
|
| 29 |
# Remove convenience copy of libjs-jquery and replace with symlink
|
| 30 |
cd debian/python-django/usr/share/doc/python-django/html/_static\
|
| 31 |
&& rm -f jquery.js\
|
| 32 |
&& ln -s ../../../../javascript/jquery/jquery.js .
|
| 33 |
|
| 34 |
clean::
|
| 35 |
rm -rf docs/_build/*
|