[R-pkg-team] Bug#901598: dh-r: xvfb-run wrapper missing
Dirk Eddelbuettel
edd at debian.org
Fri Jun 15 11:25:27 BST 2018
Package: dh-r
Version: 120180613
Severity: important
Some CRAN packages for R require x11 at build time when they load the package
towards the end of the 'R CMD build' step. r-cran.mk accomodated that via
## xvfb-run with GL extension and default resolution
xvfbSrvArgs = -screen 0 1024x768x24 -ac +extension GLX +render -noreset
[...]
## call R to install the sources we're looking at
## use this inside xvfb-run if this wrapper is installed
if test -f /usr/bin/xvfb-run; then \
$(makeFlagsCall) xvfb-run -a -n 20 \
-s "${xvfbSrvArgs}" \
R CMD INSTALL -l $(debRlib) --clean \
$(extraInstallFlags) . \
$(builttimeStamp) \
; \
else \
$(makeFlagsCall) R CMD INSTALL -l $(debRlib) \
--clean $(extraInstallFlags) . \
$(builttimeStamp) \
; \
fi
So if xvfb-run is present (in the chroot, say), it is used to wrap the call.
We used that for years.
dh-r skipped that step.
For a package like cairoDevice (aka r-cran-cairodevice), this renders dh-r
unuseable:
** testing if installed package can be loaded
Error: package or namespace load failed for 'cairoDevice':
.onLoad failed in loadNamespace() for 'cairoDevice', details:
call: fun(libname, pkgname)
error: GDK display not found - please make sure X11 is running
Error: loading failed
Execution halted
ERROR: loading failed
* removing '/build/cairodevice-2.25/debian/r-cran-cairodevice/usr/lib/R/site-library/cairoDevice'
dh_auto_install: R CMD INSTALL -l /build/cairodevice-2.25/debian/r-cran-cairodevice/usr/lib/R/site-library --clean . "--built-timestamp='Fri, 15 Jun 2018 05:15:15 -0500'" returned exit code 1
make: *** [debian/rules:7: binary] Error 25
dpkg-buildpackage: error: fakeroot debian/rules binary subprocess returned exit status 2
I: copying local configuration
E: Failed autobuilding of package
I: unmounting dev/ptmx filesystem
I: unmounting dev/pts filesystem
I: unmounting dev/shm filesystem
I: unmounting proc filesystem
I: unmounting sys filesystem
I: cleaning the build env
I: removing directory /var/cache/pbuilder/build//1441 and its subdirectories
gbp:error: 'pdebuild' failed: it exited with 1
To reproduce, clone the repo at
https://salsa.debian.org/edd/r-cran-cairodevice
and use the
bug/dh-r
branch. The master and debian branch revert back to cdbs by (yuck) including
a copy of r-cran.mk in debian/rules.
Dirk
--
http://dirk.eddelbuettel.com | @eddelbuettel | edd at debian.org
More information about the R-pkg-team
mailing list