| 1 |
#!/usr/bin/make -f
|
| 2 |
|
| 3 |
DEB_PYTHON_SYSTEM := pysupport
|
| 4 |
|
| 5 |
include /usr/share/cdbs/1/rules/buildcore.mk
|
| 6 |
include /usr/share/cdbs/1/rules/debhelper.mk
|
| 7 |
include /usr/share/cdbs/1/class/python-distutils.mk
|
| 8 |
include /usr/share/cdbs/1/rules/simple-patchsys.mk
|
| 9 |
|
| 10 |
DEB_PYTHON_INSTALL_ARGS_ALL += --single-version-externally-managed
|
| 11 |
|
| 12 |
binary-post-install/python-django::
|
| 13 |
# Use default python shebang
|
| 14 |
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
|
| 15 |
# Ensure executability of some scripts that are copied to projects
|
| 16 |
# (or used within projects)
|
| 17 |
chmod 755 debian/python-django/usr/share/python-support/python-django/django/conf/project_template/manage.py
|
| 18 |
chmod 755 debian/python-django/usr/share/python-support/python-django/django/bin/[^_]*.py
|
| 19 |
chmod 755 debian/python-django/usr/share/python-support/python-django/django/bin/profiling/[^_]*.py
|
| 20 |
# Create convenience symlink
|
| 21 |
mkdir -p debian/python-django/usr/lib/python-django
|
| 22 |
dh_link usr/share/python-support/python-django/django/bin usr/lib/python-django/bin
|
| 23 |
# Rename django-admin.py to django-admin
|
| 24 |
mv debian/python-django/usr/bin/django-admin.py debian/python-django/usr/bin/django-admin
|