debian/rules: Allow for cross-building (Closes: #930240).
authorAaron M. Ucko <ucko@debian.org>
Mon, 30 Sep 2019 01:50:15 +0000 (21:50 -0400)
committerAaron M. Ucko <ucko@debian.org>
Mon, 30 Sep 2019 01:50:15 +0000 (21:50 -0400)
commitfdbb78f4555e144f625d76365b045f6780dfc699
treee169091b69cce435c81f35297721e3fc132d674d
parentde8ac77ef9441128d1939f29515f81ee3480c496
debian/rules: Allow for cross-building (Closes: #930240).

- Factor a DEB_CONFIGURE_COMMON_FLAGS macro out of
  DEB_CONFIGURE_EXTRA_FLAGS for flags that also make sense for native
  builds of internal helpers.
- Conditionally supply --build=... and --host= to the main
  (historically, only) configure run per Helmut Grohne's suggestion.
  (dh_auto_configure would take care of this, but insists on passing
  a --runstatedir=... flag this configure script doesn't accept.)
- Conditionally add a rule for building native datatool and
  project_tree_builder binaries (in a parallel build tree established
  via another configure invocation), make it a dependency of
  override_dh_auto_configure-arch, and arrange for everything else to
  use these binaries as needed.
- Honor DEB_BUILD_OPTIONS="... nocheck ...", also per Helmut.
- Rework logic to install (possibly indirect) local library
  dependencies to use readelf rather than ldd, making as many passes
  as necessary (four at present, but no hardcoded count).
debian/changelog
debian/rules