Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.debian.maint.python > #8918
| Path | csiph.com!news.redatomik.org!aioe.org!bofh.it!news.nic.it!robomod |
|---|---|
| From | Dmitry Shachnev <mitya57@debian.org> |
| Newsgroups | linux.debian.maint.python |
| Subject | Re: Upstream build system, Sphinx autodoc, Python import path |
| Date | Fri, 30 Sep 2016 08:50:02 +0200 |
| Message-ID | <smZNU-6HU-11@gated-at.bofh.it> (permalink) |
| References | <slWfn-7h7-15@gated-at.bofh.it> <smR3X-12A-9@gated-at.bofh.it> |
| X-Mailbox-Line | From debian-python-request@lists.debian.org Fri Sep 30 06:41:17 2016 |
| Old-Return-Path | <mitya57@gmail.com> |
| X-Amavis-Spam-Status | No, score=-9.501 tagged_above=-10000 required=5.3 tests=[BAYES_00=-2, FOURLA=0.1, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FORGED_FROMDOMAIN=0.001, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.001, LDO_WHITELIST=-5, PGPSIGNATURE=-5, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, RCVD_IN_SORBS_SPAM=0.5, SARE_BOUNDARY_LC=1.666] autolearn=ham autolearn_force=no |
| X-Policyd-Weight | NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_BL_NJABL=-1.5 CL_IP_EQ_HELO_IP=-2 (check from: .gmail. - helo: .mail-lf0-f43.google. - helo-domain: .google.) FROM/MX_MATCHES_HELO(DOMAIN)=-2; rate: -7 |
| X-Google-Dkim-Signature | v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:date:from:to:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=gCNB/soIYtlSkKo1eEgpawqJDgZiji623pMnmdx/MWM=; b=fASD8VB+XWllt9s6mEFfnnZvw3px5OTobGHWLfi3XCMwj6I55Q0pPomRx3xmF1qaTF N3wJIt5imfoEtY7f2qzsWNNgOoP9yqcEu0Vhnq8RH5zO0bVEdjyXQfZF5hZa/02FamwN mLryyttTza7shWMXxZDrhqdqgBCJcnFoAoSPHoujFULxyiUfXSwnLHKhOX1Mh2JKh4OI SBuVMl+gwVuA+yi7UyYFs2kcOyxhUACGUsSal99vstQC1bQRmybbuVT9ff+Nvt0O34u0 hZ1RORAqHlwWeE6BYq3rhh0u/Yf8KkvWNtTBwbYC6DbKaBLPTVk63jwBnRKiqhtxe/96 Dd/Q== |
| X-Gm-Message-State | AA6/9RkZbRwirTknFfkLyf0wcEYSAhRoYsdlMI0qwZ/GBmOkA0X82rzzCjmzE65zwMORgw== |
| X-Received | by 10.25.41.141 with SMTP id p135mr2453501lfp.183.1475217661266; Thu, 29 Sep 2016 23:41:01 -0700 (PDT) |
| MIME-Version | 1.0 |
| Content-Type | multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="zsmtcoehnxgcsxmi" |
| Content-Disposition | inline |
| User-Agent | NeoMutt/20160916 (1.7.0) |
| X-Mailing-List | <debian-python@lists.debian.org> archive/latest/14260 |
| List-ID | <debian-python.lists.debian.org> |
| List-URL | <https://lists.debian.org/debian-python/> |
| List-Archive | https://lists.debian.org/msgid-search/20160930064057.ipdnuy5k4yqy7c6s@mitya57.me |
| Approved | robomod@news.nic.it |
| Lines | 75 |
| Organization | linux.* mail to news gateway |
| Sender | robomod@news.nic.it |
| X-Original-Date | Fri, 30 Sep 2016 09:40:57 +0300 |
| X-Original-Message-ID | <20160930064057.ipdnuy5k4yqy7c6s@mitya57.me> |
| X-Original-References | <85h991lodg.fsf@benfinney.id.au> <479e273e-ccf6-17c0-d8cb-a926daa3fb4a@debian.org> |
| Xref | csiph.com linux.debian.maint.python:8918 |
Show key headers only | View raw
[Multipart message — attachments visible in raw view] - view raw
Hi Thomas, On Thu, Sep 29, 2016 at 11:22:08PM +0200, Thomas Goirand wrote: > On 09/27/2016 10:48 AM, Ben Finney wrote: > > Our wiki page on Library Style Guide advises the Debian packaging > > override the Python import path: > > > > If you need to build the Sphinx documentation (usually from .rst or > > .md files), add: > > > > override_dh_auto_build: > > dh_auto_build > > PYTHONPATH=. sphinx-build -N -bhtml docs/ build/html # HTML generator > > PYTHONPATH=. sphinx-build -N -bman docs/ build/man # Manpage generator > > If that's what the wiki advise, then it's quite wrong. The target which > should be "overrides" is dh_sphinxdoc. I usually do this: > > override_dh_sphinxdoc: > ifeq (,$(findstring nodocs, $(DEB_BUILD_OPTIONS))) > sphinx-build -b html doc/source \ > $(CURDIR)/debian/foo-doc/usr/share/doc/foo-doc/html > dh_sphinxdoc > endif > > And the same kind of thing for man page. It's IMO nice to have the > nodocs thing if it takes too long to build (probably useless if it's > quick). In such case, overriding the correct debian/rules target is key. I think the modern way to disable docs is using DEB_BUILD_PROFILES=nodoc rather than DEB_BUILD_OPTIONS (because that allows you to actually disable building the foo-doc package, and also allows dropping sphinx build-dep). See [1], [2] for details. Anyway, for non-core Python packages there is usually no reason to care about this, and in that case building the docs in override_dh_auto_build is perfectly fine. And IMO it is semantically more correct to build stuff in build target, rather than install target. [1]: https://wiki.debian.org/BuildProfileSpec#Registered_profile_names [2]: https://wiki.debian.org/DebianBootstrap#Documentation_loops > I don't see why upstream requiring PYTHONPATH=. would be bad... Agreed. -- Dmitry Shachnev
Back to linux.debian.maint.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Upstream build system, Sphinx autodoc, Python import path Ben Finney <ben+debian@benfinney.id.au> - 2016-09-27 10:50 +0200
Re: Upstream build system, Sphinx autodoc, Python import path Thomas Goirand <zigo@debian.org> - 2016-09-29 23:30 +0200
Re: Upstream build system, Sphinx autodoc, Python import path Dmitry Shachnev <mitya57@debian.org> - 2016-09-30 08:50 +0200
Re: Upstream build system, Sphinx autodoc, Python import path Thomas Goirand <zigo@debian.org> - 2016-09-29 23:40 +0200
Re: Upstream build system, Sphinx autodoc, Python import path Barry Warsaw <barry@debian.org> - 2016-09-30 00:00 +0200
Re: Upstream build system, Sphinx autodoc, Python import path Nikolaus Rath <Nikolaus@rath.org> - 2016-09-30 05:00 +0200
Re: Upstream build system, Sphinx autodoc, Python import path Florent Rougon <f.rougon@free.fr> - 2016-09-30 08:20 +0200
Re: Upstream build system, Sphinx autodoc, Python import path Thomas Goirand <zigo@debian.org> - 2016-09-30 12:20 +0200
Re: Upstream build system, Sphinx autodoc, Python import path Nikolaus Rath <Nikolaus@rath.org> - 2016-09-30 23:20 +0200
csiph-web