[Bug 984962] Re: Uses wrong pkg-config for dbus test when cross-building [SRU]

Wookey wookey at wookware.org
Fri Apr 20 16:02:54 UTC 2012


** Description changed:

  [Problem]
- <1-2 sentence summary of the issue>
+ consolekit fails to cross-build due to trying use wrong-arch 'pkg-config' during configure.
  
  [Impact]
- <fill me in with explanation of severity and frequency of bug on users and justification for backporting the fix to the stable release>
+ The impact is only on those cross-building, but one target for the precise release was to have as much of the base system cross-buildable as possible. consolekit is a base system package so it's important to be able to cross-build it.
  
  [Development Fix]
- <fill me in with an explanation of how the bug has been addressed in the development branch, including the relevant version numbers of packages modified in order to implement the fix. >
+ Upstream git has fixed this problem by removing the check in question entirely. See http://cgit.freedesktop.org/ConsoleKit/commit/?id=f42cafcce978c402bdbc9c6e03a0c90bb0924b89
+ 
+ But that version has not yet been released. I don't know if other
+ changes are needed first before simply getting rid of it.
  
  [Stable Fix]
- <fill me in by pointing out a minimal patch applicable to the stable version of the package.>
+ The minimal fix is simply to use $PKG_CONFIG as set-up by autoconf instead of hard-coded 'pkg-config', then tha correct version is used for both native and cross builds. 
  
- [Text Case]
- <fill me in with detailed *instructions* on how to reproduce the bug.  This will be used by people later on to verify the updated package fixes the problem.>
- 1.
- 2.
- 3.
- Broken Behavior: 
- Fixed Behavior: 
+ [Test Case]
+ 1. apt-get source consolekit
+ 2. apt-get -a armel build-dep consolekit
+ 3. cd consolekit-0.4.5
+ 4. CONFIG_SITE=/etc/dpkg-cross/cross-config.armel DEB_BUILD_OPTIONS=nocheck dpkg-buildpackage -aarmel -uc -us
  
+ Broken Behavior: build will stop after a while saying: 
+   Package dbus-1 was not found in the pkg-config search path.
+ Perhaps you should add the directory containing `dbus-1.pc'
+ to the PKG_CONFIG_PATH environment variable
+ No package 'dbus-1' found
+ Error: Couldn't determine the version of your DBUS package.
+   This is probably an error in this script, please report it
+   along with the following information:
+       Base DBUS version =''
+       DBUS_VERSION_MAJOR='0'
+       DBUS_VERSION_MINOR='0'
+       DBUS_VERSION_MICRO='0'
+   (and then print out the whole of config.log)
+ 
+ Fixed Behavior: build will get past this point, saying:
+  Your dbus version is 1,4,18.
+ It will stop a bit further on with "/bin/bash: /usr/bin/dbus-binding-tool: No such file or directory", unless you have qemu installed, but that's a different bug in a different package.
+   
  [Regression Potential]
- <fill me in with a discussion of likelihood and potential severity of regressions and how users could get inadvertently affected.>
+ The only thing that could go wrong is breaking the native build. I've tested that this works fine. You can confirm it with
+ 1. apt-get build-dep consolekit
+ 2. cd consolekit-0.4.5
+ 3. dpkg-buildpackage -uc -us
+ that build should complete as normal.
  
  [Original Report]
- 
  
  consolekit can't find dbus-1 when cross-building:
  
  From the build log: http://people.linaro.org/~wookey/buildd/precise/sbuild-ma/consolekit_0.4.5-2-precise-ma-cross-armel-20120417-025041.38177.log
  Package dbus-1 was not found in the pkg-config search path.
  Perhaps you should add the directory containing `dbus-1.pc'
  to the PKG_CONFIG_PATH environment variable
  No package 'dbus-1' found
  Error: Couldn't determine the version of your DBUS package.
  
  This turns out to be because a local test in configure.ac used hard-
  coded 'pkg-config' instead of $PKG_CONFIG which autoconf has set to the
  correct path (/usr/bin/<triplet>-pkg-config)
  
  (This patch is not sufficient to cross-build this package which has
  other issues).

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to consolekit in Ubuntu.
https://bugs.launchpad.net/bugs/984962

Title:
  Uses wrong pkg-config for dbus test when cross-building [SRU]

Status in “consolekit” package in Ubuntu:
  Incomplete
Status in “consolekit” source package in Precise:
  Incomplete
Status in “consolekit” source package in q-series:
  Incomplete
Status in “consolekit” package in Debian:
  New

Bug description:
  [Problem]
  consolekit fails to cross-build due to trying use wrong-arch 'pkg-config' during configure.

  [Impact]
  The impact is only on those cross-building, but one target for the precise release was to have as much of the base system cross-buildable as possible. consolekit is a base system package so it's important to be able to cross-build it.

  [Development Fix]
  Upstream git has fixed this problem by removing the check in question entirely. See http://cgit.freedesktop.org/ConsoleKit/commit/?id=f42cafcce978c402bdbc9c6e03a0c90bb0924b89

  But that version has not yet been released. I don't know if other
  changes are needed first before simply getting rid of it.

  [Stable Fix]
  The minimal fix is simply to use $PKG_CONFIG as set-up by autoconf instead of hard-coded 'pkg-config', then tha correct version is used for both native and cross builds. 

  [Test Case]
  1. apt-get source consolekit
  2. apt-get -a armel build-dep consolekit
  3. cd consolekit-0.4.5
  4. CONFIG_SITE=/etc/dpkg-cross/cross-config.armel DEB_BUILD_OPTIONS=nocheck dpkg-buildpackage -aarmel -uc -us

  Broken Behavior: build will stop after a while saying: 
    Package dbus-1 was not found in the pkg-config search path.
  Perhaps you should add the directory containing `dbus-1.pc'
  to the PKG_CONFIG_PATH environment variable
  No package 'dbus-1' found
  Error: Couldn't determine the version of your DBUS package.
    This is probably an error in this script, please report it
    along with the following information:
        Base DBUS version =''
        DBUS_VERSION_MAJOR='0'
        DBUS_VERSION_MINOR='0'
        DBUS_VERSION_MICRO='0'
    (and then print out the whole of config.log)

  Fixed Behavior: build will get past this point, saying:
   Your dbus version is 1,4,18.
  It will stop a bit further on with "/bin/bash: /usr/bin/dbus-binding-tool: No such file or directory", unless you have qemu installed, but that's a different bug in a different package.
    
  [Regression Potential]
  The only thing that could go wrong is breaking the native build. I've tested that this works fine. You can confirm it with
  1. apt-get build-dep consolekit
  2. cd consolekit-0.4.5
  3. dpkg-buildpackage -uc -us
  that build should complete as normal.

  [Original Report]

  consolekit can't find dbus-1 when cross-building:

  From the build log: http://people.linaro.org/~wookey/buildd/precise/sbuild-ma/consolekit_0.4.5-2-precise-ma-cross-armel-20120417-025041.38177.log
  Package dbus-1 was not found in the pkg-config search path.
  Perhaps you should add the directory containing `dbus-1.pc'
  to the PKG_CONFIG_PATH environment variable
  No package 'dbus-1' found
  Error: Couldn't determine the version of your DBUS package.

  This turns out to be because a local test in configure.ac used hard-
  coded 'pkg-config' instead of $PKG_CONFIG which autoconf has set to
  the correct path (/usr/bin/<triplet>-pkg-config)

  (This patch is not sufficient to cross-build this package which has
  other issues).

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/consolekit/+bug/984962/+subscriptions




More information about the foundations-bugs mailing list