[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: pybuild sphinxdoc and extensions



[please don't CC me on a mailing list if you don't want to end up in SPAM]

[Christoph Groth, 2015-10-22]
> With “install target”, do you mean dh_installdocs?  In our debian/rules, we

I meat override_dh_auto_install or {install,binary}-{arch,indep}

> have now
> 
> # Make documentation only if needed.
> ifneq "$(shell dh_listpackages | grep -- -doc)" ""
> override_dh_installdocs:
> 	cd doc && PYTHONPATH=$(abspath
> 	debian/python-kwant/usr/lib/python2.7/dist-packages) 	$(MAKE) html
> 	dh_installdocs
> endif

that should work too, but I'd suggest to use:

  override_dh_auto_install:
  	dh_auto_install
	PYTHONPATH=$(CURDIR)/debian/python3-kwant/usr/lib/python3/dist-packages \
	$(MAKE) -C doc html

> • How to get rid of the explicit mention of python2.7?

no need, we will not support 2.6 or 2.8 so it's OK to hardcode 2.7
and for Python 3.X use above example

> • Is the “ifneq”-clause the proper way to ensure that  documentation is only
> built for binary-indep?

I'd use:
  ifeq (,$(filter nodoc,$(DEB_BUILD_OPTIONS)))
  	...
  endif

in override_dh_auto_install-indep target, but neither nodoc or nodocs is
official (vide: #759186)

> I have one further more general question with regard to Debian packaging
> with pybuild.  Pybuild deletes the *.egg-info directory but that directory
> is included in the tarball as made by “setup.py sdist”.  (I am aware that
> some people consider that directory to be generated data, but this is
> debatable [1], and it’s standard practice to include it in the tarball

I'm lazy and now that DPMT keeps full upstream sources in git and I have
to add .gitignore to all packages I touch, I will most probably remove
the feature of deleting evil egg-info and just log an info about adding
"*.egg-info" to debian/clean or "extend-diff-ignore="^[^/]+\.egg-info/"
to debian/source/options"
-- 
Piotr Ożarowski                         Debian GNU/Linux Developer
www.ozarowski.pl          www.griffith.cc           www.debian.org
GPG Fingerprint: 1D2F A898 58DA AF62 1786 2DF7 AEF6 F1A2 A745 7645


Reply to: