author | Denis Laxalde <denis.laxalde@logilab.fr> |
Wed, 28 Sep 2016 11:06:28 +0200 | |
changeset 11740 | dabbb2a4a493 |
parent 11631 | faf279e33298 |
child 11832 | e8be49ecb522 |
permissions | -rwxr-xr-x |
11515
b3267ba817b4
Initial debian packaging
Julien Cristau <julien.cristau@logilab.fr>
parents:
diff
changeset
|
1 |
#!/usr/bin/make -f |
0 | 2 |
# Sample debian/rules that uses debhelper. |
3 |
# GNU copyright 1997 to 1999 by Joey Hess. |
|
4 |
||
5 |
# Uncomment this to turn on verbose mode. |
|
6 |
#export DH_VERBOSE=1 |
|
858
e6ae125d5903
reorganize debian packages (Closes: #1168)
Julien Jehannet <julien.jehannet@logilab.fr>
parents:
275
diff
changeset
|
7 |
|
0 | 8 |
build: build-stamp |
3936
0fc300eb4746
prepare 3.5.7
Nicolas Chauvat <nicolas.chauvat@logilab.fr>
parents:
2413
diff
changeset
|
9 |
build-stamp: |
0 | 10 |
dh_testdir |
11424
1451f040555f
[pkg] Drop NO_SETUPTOOLS option
Denis Laxalde <denis.laxalde@logilab.fr>
parents:
11394
diff
changeset
|
11 |
python setup.py build |
8476
864a92b10cb8
[book] Some tweaks to fix cubicweb-documentation package generation
Julien Cristau <julien.cristau@logilab.fr>
parents:
7767
diff
changeset
|
12 |
# cubicweb.foo needs to be importable by sphinx, so create a cubicweb symlink to the source dir |
864a92b10cb8
[book] Some tweaks to fix cubicweb-documentation package generation
Julien Cristau <julien.cristau@logilab.fr>
parents:
7767
diff
changeset
|
13 |
mkdir -p debian/pythonpath |
11394
f0188639e544
[debian] Adjust symlink to cubicweb package so that documention builds fine
Denis Laxalde <denis.laxalde@logilab.fr>
parents:
10992
diff
changeset
|
14 |
ln -sf $(CURDIR)/cubicweb debian/pythonpath |
7767
07c74f5585d1
[debian] build the book with no auto-compression of book files (closes: #1906581)
Julien Jehannet <julien.jehannet@logilab.fr>
parents:
7512
diff
changeset
|
15 |
# documentation build is now made optional since it can break for old |
07c74f5585d1
[debian] build the book with no auto-compression of book files (closes: #1906581)
Julien Jehannet <julien.jehannet@logilab.fr>
parents:
7512
diff
changeset
|
16 |
# distributions and we don't want to block a new release of Cubicweb |
07c74f5585d1
[debian] build the book with no auto-compression of book files (closes: #1906581)
Julien Jehannet <julien.jehannet@logilab.fr>
parents:
7512
diff
changeset
|
17 |
# because of documentation issues. |
10536
887c6eef8077
[pkg] various fixes
Julien Cristau <julien.cristau@logilab.fr>
parents:
9237
diff
changeset
|
18 |
-PYTHONPATH=$${PYTHONPATH:+$${PYTHONPATH}:}$(CURDIR)/debian/pythonpath $(MAKE) -C doc all |
8476
864a92b10cb8
[book] Some tweaks to fix cubicweb-documentation package generation
Julien Cristau <julien.cristau@logilab.fr>
parents:
7767
diff
changeset
|
19 |
rm -rf debian/pythonpath |
0 | 20 |
touch build-stamp |
21 |
||
3936
0fc300eb4746
prepare 3.5.7
Nicolas Chauvat <nicolas.chauvat@logilab.fr>
parents:
2413
diff
changeset
|
22 |
clean: |
0 | 23 |
dh_testdir |
24 |
rm -f build-stamp configure-stamp |
|
25 |
rm -rf build |
|
858
e6ae125d5903
reorganize debian packages (Closes: #1168)
Julien Jehannet <julien.jehannet@logilab.fr>
parents:
275
diff
changeset
|
26 |
#rm -rf debian/cubicweb-*/ |
e6ae125d5903
reorganize debian packages (Closes: #1168)
Julien Jehannet <julien.jehannet@logilab.fr>
parents:
275
diff
changeset
|
27 |
find . -name "*.pyc" -delete |
10536
887c6eef8077
[pkg] various fixes
Julien Cristau <julien.cristau@logilab.fr>
parents:
9237
diff
changeset
|
28 |
-$(MAKE) -C doc clean |
0 | 29 |
dh_clean |
30 |
||
10559
5821ae654dfd
[pkg] various debian packaging fixes
Julien Cristau <julien.cristau@logilab.fr>
parents:
10536
diff
changeset
|
31 |
install: build |
0 | 32 |
dh_testdir |
33 |
dh_testroot |
|
858
e6ae125d5903
reorganize debian packages (Closes: #1168)
Julien Jehannet <julien.jehannet@logilab.fr>
parents:
275
diff
changeset
|
34 |
dh_clean |
0 | 35 |
dh_installdirs |
858
e6ae125d5903
reorganize debian packages (Closes: #1168)
Julien Jehannet <julien.jehannet@logilab.fr>
parents:
275
diff
changeset
|
36 |
|
11424
1451f040555f
[pkg] Drop NO_SETUPTOOLS option
Denis Laxalde <denis.laxalde@logilab.fr>
parents:
11394
diff
changeset
|
37 |
python setup.py -q install --no-compile --prefix=debian/tmp/usr |
11515
b3267ba817b4
Initial debian packaging
Julien Cristau <julien.cristau@logilab.fr>
parents:
diff
changeset
|
38 |
|
858
e6ae125d5903
reorganize debian packages (Closes: #1168)
Julien Jehannet <julien.jehannet@logilab.fr>
parents:
275
diff
changeset
|
39 |
# Put all the python library and data in cubicweb-common |
e6ae125d5903
reorganize debian packages (Closes: #1168)
Julien Jehannet <julien.jehannet@logilab.fr>
parents:
275
diff
changeset
|
40 |
# and scripts in cubicweb-server |
9208
7ae95f48e2f0
[pkg] fix debian packaging (closes #3058542)
David Douard <david.douard@logilab.fr>
parents:
9193
diff
changeset
|
41 |
dh_install -vi --sourcedir=debian/tmp |
1821 | 42 |
# cwctl in the cubicweb-ctl package |
9208
7ae95f48e2f0
[pkg] fix debian packaging (closes #3058542)
David Douard <david.douard@logilab.fr>
parents:
9193
diff
changeset
|
43 |
rm -f debian/cubicweb-common/usr/lib/python*/*/cubicweb/cwctl.py |
6532
6096018ac6b7
[debian] cleanup -common package
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
6520
diff
changeset
|
44 |
# wdoc in the cubicweb-web package |
6096018ac6b7
[debian] cleanup -common package
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
6520
diff
changeset
|
45 |
rm -rf debian/cubicweb-common/usr/share/cubicweb/cubes/shared/wdoc |
6096018ac6b7
[debian] cleanup -common package
Sylvain Thénault <sylvain.thenault@logilab.fr>
parents:
6520
diff
changeset
|
46 |
rm -rf debian/cubicweb-common/usr/share/cubicweb/cubes/shared/data |
858
e6ae125d5903
reorganize debian packages (Closes: #1168)
Julien Jehannet <julien.jehannet@logilab.fr>
parents:
275
diff
changeset
|
47 |
dh_lintian |
e6ae125d5903
reorganize debian packages (Closes: #1168)
Julien Jehannet <julien.jehannet@logilab.fr>
parents:
275
diff
changeset
|
48 |
|
e6ae125d5903
reorganize debian packages (Closes: #1168)
Julien Jehannet <julien.jehannet@logilab.fr>
parents:
275
diff
changeset
|
49 |
# Remove unittests directory (should be available in cubicweb-dev only) |
10992
228b6d2777e4
[pkg] don't install dataimport/test in both cubicweb-server and cubicweb-dev
Julien Cristau <julien.cristau@logilab.fr>
parents:
10559
diff
changeset
|
50 |
rm -rf debian/cubicweb-server/usr/lib/python2*/*-packages/cubicweb/dataimport/test |
10559
5821ae654dfd
[pkg] various debian packaging fixes
Julien Cristau <julien.cristau@logilab.fr>
parents:
10536
diff
changeset
|
51 |
rm -rf debian/cubicweb-server/usr/lib/python2*/*-packages/cubicweb/server/test |
5821ae654dfd
[pkg] various debian packaging fixes
Julien Cristau <julien.cristau@logilab.fr>
parents:
10536
diff
changeset
|
52 |
rm -rf debian/cubicweb-server/usr/lib/python2*/*-packages/cubicweb/hooks/test |
5821ae654dfd
[pkg] various debian packaging fixes
Julien Cristau <julien.cristau@logilab.fr>
parents:
10536
diff
changeset
|
53 |
rm -rf debian/cubicweb-server/usr/lib/python2*/*-packages/cubicweb/sobjects/test |
5821ae654dfd
[pkg] various debian packaging fixes
Julien Cristau <julien.cristau@logilab.fr>
parents:
10536
diff
changeset
|
54 |
rm -rf debian/cubicweb-web/usr/lib/python2*/*-packages/cubicweb/web/test |
5821ae654dfd
[pkg] various debian packaging fixes
Julien Cristau <julien.cristau@logilab.fr>
parents:
10536
diff
changeset
|
55 |
rm -rf debian/cubicweb-twisted/usr/lib/python2*/*-packages/cubicweb/etwist/test |
5821ae654dfd
[pkg] various debian packaging fixes
Julien Cristau <julien.cristau@logilab.fr>
parents:
10536
diff
changeset
|
56 |
rm -rf debian/cubicweb-common/usr/lib/python2*/*-packages/cubicweb/ext/test |
5821ae654dfd
[pkg] various debian packaging fixes
Julien Cristau <julien.cristau@logilab.fr>
parents:
10536
diff
changeset
|
57 |
rm -rf debian/cubicweb-common/usr/lib/python2*/*-packages/cubicweb/entities/test |
11631 | 58 |
rm -rf debian/cubicweb-pyramid/usr/lib/python2*/*-packages/cubicweb/pyramid/tests |
858
e6ae125d5903
reorganize debian packages (Closes: #1168)
Julien Jehannet <julien.jehannet@logilab.fr>
parents:
275
diff
changeset
|
59 |
|
11515
b3267ba817b4
Initial debian packaging
Julien Cristau <julien.cristau@logilab.fr>
parents:
diff
changeset
|
60 |
|
0 | 61 |
# Build architecture-independent files here. |
62 |
binary-indep: build install |
|
63 |
dh_testdir |
|
64 |
dh_testroot -i |
|
9193
eaa58d1c7d5f
[pkg] python-central has been removed from Debian
David Douard <david.douard@logilab.fr>
parents:
9174
diff
changeset
|
65 |
dh_python2 -i |
10559
5821ae654dfd
[pkg] various debian packaging fixes
Julien Cristau <julien.cristau@logilab.fr>
parents:
10536
diff
changeset
|
66 |
dh_python2 -i /usr/share/cubicweb |
0 | 67 |
dh_installinit -i -n --name cubicweb -u"defaults 99" |
68 |
dh_installlogrotate -i |
|
69 |
dh_installdocs -i -A README |
|
70 |
dh_installman -i |
|
10536
887c6eef8077
[pkg] various fixes
Julien Cristau <julien.cristau@logilab.fr>
parents:
9237
diff
changeset
|
71 |
dh_installchangelogs -i -Xdoc/changes |
0 | 72 |
dh_link -i |
10559
5821ae654dfd
[pkg] various debian packaging fixes
Julien Cristau <julien.cristau@logilab.fr>
parents:
10536
diff
changeset
|
73 |
dh_compress -i -X.py -X.ini -X.xml -X.js -X.rst -X.txt -Xchangelog.html |
0 | 74 |
dh_fixperms -i |
75 |
dh_installdeb -i |
|
76 |
dh_gencontrol -i |
|
77 |
dh_md5sums -i |
|
78 |
dh_builddeb -i |
|
79 |
||
80 |
binary-arch: |
|
81 |
||
3936
0fc300eb4746
prepare 3.5.7
Nicolas Chauvat <nicolas.chauvat@logilab.fr>
parents:
2413
diff
changeset
|
82 |
binary: binary-indep |
0 | 83 |
.PHONY: build clean binary binary-indep binary-arch |
84 |