Source: theano Version: 1.0.5+dfsg-1 Tags: patch User: [email protected] Usertags: cross-satisfiability
theano cannot be cross built from source, because its Build-Depends are not satisfiable. While looking into it, I observed that d/control kindly documents the purpose of dependencies and that theano-doc is an Arch:all package, which is irrelevant to cross building. A small modification to debian/rules can remove the documentation from the arch-only build, which allows demoting a big chunk of dependencies to Build-Depend-Indep. Please consider applying the attached patch. Helmut
diff --minimal -Nru theano-1.0.5+dfsg/debian/changelog theano-1.0.5+dfsg/debian/changelog --- theano-1.0.5+dfsg/debian/changelog 2020-08-16 14:33:47.000000000 +0200 +++ theano-1.0.5+dfsg/debian/changelog 2021-01-18 20:48:12.000000000 +0100 @@ -1,3 +1,10 @@ +theano (1.0.5+dfsg-1.1) UNRELEASED; urgency=medium + + * Non-maintainer upload. + * Demote documentation dependencies to Build-Depends-Inep. (Closes: #-1) + + -- Helmut Grohne <[email protected]> Mon, 18 Jan 2021 20:48:12 +0100 + theano (1.0.5+dfsg-1) unstable; urgency=medium * New upstream release (by a new maintainer). Drop/refresh patches. diff --minimal -Nru theano-1.0.5+dfsg/debian/control theano-1.0.5+dfsg/debian/control --- theano-1.0.5+dfsg/debian/control 2020-08-16 13:26:22.000000000 +0200 +++ theano-1.0.5+dfsg/debian/control 2021-01-18 20:48:12.000000000 +0100 @@ -21,18 +21,8 @@ python3-pydot, python3-sympy <!nocheck>, graphviz, -#for the documentation build +#for README.html build python3-docutils, - python3-sphinx, - python3-sphinx-rtd-theme, - python3-pygments, - dvipng, - texlive-latex-extra, - texlive-fonts-recommended, - latexmk, - rdfind, - symlinks, - jupyter-nbconvert, python3-ipykernel, #for building Javascript dependencies (of d3viz) node-browserify-lite, uglifyjs.terser, @@ -44,6 +34,19 @@ mocha, chai, libjs-d3 +Build-Depends-Indep: +#for the documentation build + dh-sequence-sphinxdoc, + python3-sphinx, + python3-sphinx-rtd-theme, + python3-pygments, + dvipng, + texlive-latex-extra, + texlive-fonts-recommended, + latexmk, + rdfind, + symlinks, + jupyter-nbconvert, python3-ipykernel, Rules-Requires-Root: no Standards-Version: 4.5.0 Homepage: http://www.deeplearning.net/software/theano/ diff --minimal -Nru theano-1.0.5+dfsg/debian/rules theano-1.0.5+dfsg/debian/rules --- theano-1.0.5+dfsg/debian/rules 2020-08-16 13:26:22.000000000 +0200 +++ theano-1.0.5+dfsg/debian/rules 2021-01-18 20:48:10.000000000 +0100 @@ -6,9 +6,10 @@ export THEANO_FLAGS=base_compiledir='.pybuild',device=cpu export PYTHONPATH=$(CURDIR) export HOME=$(CURDIR)/jupyter_tmp +DO_PACKAGES=$(shell dh_listpackages) %: - dh $@ --with python3,sphinxdoc --buildsystem=pybuild + dh $@ --with python3 --buildsystem=pybuild override_dh_auto_clean: mv theano/bin -T bin || true @@ -40,6 +41,7 @@ cd $(CURDIR)/theano/scan_module && mv scan_perform.c -t c_code #documentation ifeq (,$(filter nodoc,$(DEB_BUILD_OPTIONS))) +ifneq (,$(filter theano-doc,$(DO_PACKAGES))) sed -i -e "s/!pip/#!pip/g" doc/library/d3viz/index.ipynb mkdir jupyter_tmp #check that we can run this, but throw away the result because it's unreproducible (profiling output) @@ -48,6 +50,7 @@ jupyter-nbconvert --to html doc/library/d3viz/index.ipynb sed -i -e "s/#!pip/!pip/g" doc/library/d3viz/index.ipynb python3 doc/scripts/docgen.py +endif rst2html README.rst README.html cat NEWS.txt HISTORY.txt | gzip -n -9 > NEWS.gz endif @@ -63,9 +66,11 @@ override_dh_installdocs: dh_installdocs -A README.html NEWS.gz ifeq (,$(filter nodoc,$(DEB_BUILD_OPTIONS))) +ifneq (,$(filter theano-doc,$(DO_PACKAGES))) rdfind -outputname /dev/null -makesymlinks true debian/theano-doc symlinks -r -s -c debian/theano-doc endif +endif override_dh_installchangelogs: #the -X is meant as "don't try to install upstream changelog, only Debian's" - #906827

