Bug#893300: cdebconf: Adding support for a pkg.cdebconf.nogtk build-profile
On Sat, Mar 17, 2018 at 09:09:11PM +0100, Karsten Merker wrote:
> I would like to add support for a "pkg.cdebconf.nogtk" build-profile
> to cdebconf. Background for that is that cdebconf (in particular
> libdebconfclient0) is needed rather early in the process of
> bootstrapping a new Debian architecture, but getting it built during
> early architecture bootstrap is difficult due to its build-dependency
> on gtk+cairo, which pulls in an enormous list of transitive
> build-dependencies that are effectively impossible to fullfill in a
> bootstrap scenario.
This approach and patch looks good to me. I'm OK with you committing
and uploading it, modulo the comments below.
> diff --git a/debian/rules b/debian/rules
> index b2b35f4d..8b85a7af 100755
> --- a/debian/rules
> +++ b/debian/rules
> @@ -21,6 +21,11 @@ LIBDEBCONF=libdebconfclient0
> DEB_FRONTENDS=passthrough text newt gtk
> UDEB_FRONTENDS=passthrough text newt gtk
>
> +ifneq ($(filter pkg.cdebconf.nogtk,$(DEB_BUILD_PROFILES)),)
> + DEB_FRONTENDS:=$(filter-out gtk,$(DEB_FRONTENDS))
> + UDEB_FRONTENDS:=$(filter-out gtk,$(UDEB_FRONTENDS))
> +endif
I think this would be clearer reversed, i.e.:
DEB_FRONTENDS=passthrough text newt
UDEB_FRONTENDS=passthrough text newt
ifeq ($(filter pkg.cdebconf.nogtk,$(DEB_BUILD_PROFILES)),)
DEB_FRONTENDS+=gtk
UDEB_FRONTENDS+=gtk
endif
> +ifneq ($(filter pkg.cdebconf.nogtk,$(DEB_BUILD_PROFILES)),)
> + dh_install -plibdebconfclient0-dev src/modules/frontend/gtk/cdebconf_gtk.h usr/include/cdebconf/
> +endif
I think I may understand what this is doing now after some confusion,
but it's pretty opaque and definitely needs at least a comment. I think
you're trying to keep the package contents identical regardless of build
profile, since the main build system won't handle it in this case due to
the change in *_FRONTENDS?
Thanks,
--
Colin Watson [cjwatson@debian.org]
Reply to: