* [Buildroot] [PATCH] qtopia4: fix use of pkg-config
@ 2008-10-28 1:51 Markus Heidelberg
2008-10-28 7:14 ` Thomas Petazzoni
2008-10-28 9:38 ` Peter Korsgaard
0 siblings, 2 replies; 5+ messages in thread
From: Markus Heidelberg @ 2008-10-28 1:51 UTC (permalink / raw)
To: buildroot
When cross compiling, Qt sets PKG_CONFIG in its own configure script to
an empty string. That leads to not using pkg-config. To avoid that, use
the configure option -force-pkg-config. Also set environment variables
for pkg-config defined in TARGET_CONFIGURE_OPTS.
---
package/qtopia4/qtopia4.mk | 7 ++++++-
1 files changed, 6 insertions(+), 1 deletions(-)
diff --git a/package/qtopia4/qtopia4.mk b/package/qtopia4/qtopia4.mk
index c959d40..360b949 100644
--- a/package/qtopia4/qtopia4.mk
+++ b/package/qtopia4/qtopia4.mk
@@ -253,10 +253,15 @@ endif
-[ -f $(QTOPIA4_QCONFIG_FILE) ] && cp $(QTOPIA4_QCONFIG_FILE) \
$(QTOPIA4_TARGET_DIR)/$(QTOPIA4_QCONFIG_FILE_LOCATION)
+# Qt doesn't use PKG_CONFIG, it searches for pkg-config with 'which'.
+# PKG_CONFIG_SYSROOT is only used to avoid a warning from Qt's configure system
+# when cross compiling, Qt 4.4.3 is wrong here.
(cd $(QTOPIA4_TARGET_DIR); rm -rf config.cache; \
- PATH=$(TARGET_PATH) \
+ $(TARGET_CONFIGURE_OPTS) \
+ PKG_CONFIG_SYSROOT="$(STAGING_DIR)" \
./configure \
-verbose \
+ -force-pkg-config \
-embedded $(BR2_PACKAGE_QTOPIA4_EMB_PLATFORM) \
$(QTOPIA4_QCONFIG_COMMAND) \
$(QTOPIA4_CONFIGURE) \
--
1.5.6.4
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [Buildroot] [PATCH] qtopia4: fix use of pkg-config
2008-10-28 1:51 [Buildroot] [PATCH] qtopia4: fix use of pkg-config Markus Heidelberg
@ 2008-10-28 7:14 ` Thomas Petazzoni
2008-10-28 8:22 ` Markus Heidelberg
2008-10-28 9:38 ` Peter Korsgaard
1 sibling, 1 reply; 5+ messages in thread
From: Thomas Petazzoni @ 2008-10-28 7:14 UTC (permalink / raw)
To: buildroot
Le Tue, 28 Oct 2008 02:51:36 +0100,
Markus Heidelberg <markus.heidelberg@web.de> a ?crit :
> + $(TARGET_CONFIGURE_OPTS) \
> + PKG_CONFIG_SYSROOT="$(STAGING_DIR)" \
I don't get why PKG_CONFIG_SYSROOT should be set here. The correct
variable is PKG_CONFIG_SYSROOT_DIR and it is already set in
TARGET_CONFIGURE_OPTS. I probably missed something specific to Qt, but
I didn't understand the sentence: ?PKG_CONFIG_SYSROOT is only used to
avoid a warning from Qt's configure system?.
Thanks,
Thomas
--
Thomas Petazzoni, Free Electrons
Kernel, drivers and embedded Linux development,
consulting, training and support.
http://free-electrons.com
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Buildroot] [PATCH] qtopia4: fix use of pkg-config
2008-10-28 7:14 ` Thomas Petazzoni
@ 2008-10-28 8:22 ` Markus Heidelberg
2008-10-28 8:50 ` Thomas Petazzoni
0 siblings, 1 reply; 5+ messages in thread
From: Markus Heidelberg @ 2008-10-28 8:22 UTC (permalink / raw)
To: buildroot
Thomas Petazzoni, 28.10.2008:
> Le Tue, 28 Oct 2008 02:51:36 +0100,
> Markus Heidelberg <markus.heidelberg@web.de> a ?crit :
>
> > + $(TARGET_CONFIGURE_OPTS) \
> > + PKG_CONFIG_SYSROOT="$(STAGING_DIR)" \
>
> I don't get why PKG_CONFIG_SYSROOT should be set here. The correct
> variable is PKG_CONFIG_SYSROOT_DIR and it is already set in
> TARGET_CONFIGURE_OPTS. I probably missed something specific to Qt, but
> I didn't understand the sentence: ?PKG_CONFIG_SYSROOT is only used to
> avoid a warning from Qt's configure system?.
Damn, I wanted to keep the comment short without being unclear, which
apparently failed. This extract from the file Qt/configure should make the use
of -force-pkg-config and PKG_CONFIG_SYSROOT clear. Qt should query
PKG_CONFIG_SYSROOT_DIR instead of PKG_CONFIG_SYSROOT. I've already sent a bug
report.
if [ "$QT_CROSS_COMPILE" = "yes" ]; then
if [ -n "$QT_FORCE_PKGCONFIG" ]; then
echo >&2 ""
echo >&2 "You have asked to use pkg-config and are cross-compiling."
echo >&2 "Please make sure you have a correctly set-up pkg-config"
echo >&2 "environment!"
echo >&2 ""
if [ -z "$PKG_CONFIG_PATH" ]; then
echo >&2 ""
echo >&2 "Warning: PKG_CONFIG_PATH has not been set. This could mean"
echo >&2 "the host compiler's .pc files will be used. This is probably"
echo >&2 "not what you want."
echo >&2 ""
elif [ -z "$PKG_CONFIG_SYSROOT" ]; then
echo >&2 ""
echo >&2 "Warning: PKG_CONFIG_SYSROOT has not been set. This means"
echo >&2 "your toolchain's .pc files must contain the paths to the"
echo >&2 "toolchain's libraries & headers. If configure tests are"
echo >&2 "failing, please check these files."
echo >&2 ""
fi
else
PKG_CONFIG=""
fi
fi
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Buildroot] [PATCH] qtopia4: fix use of pkg-config
2008-10-28 8:22 ` Markus Heidelberg
@ 2008-10-28 8:50 ` Thomas Petazzoni
0 siblings, 0 replies; 5+ messages in thread
From: Thomas Petazzoni @ 2008-10-28 8:50 UTC (permalink / raw)
To: buildroot
Le Tue, 28 Oct 2008 09:22:53 +0100,
Markus Heidelberg <markus.heidelberg@web.de> a ?crit :
> Damn, I wanted to keep the comment short without being unclear, which
> apparently failed. This extract from the file Qt/configure should
> make the use of -force-pkg-config and PKG_CONFIG_SYSROOT clear. Qt
> should query PKG_CONFIG_SYSROOT_DIR instead of PKG_CONFIG_SYSROOT.
> I've already sent a bug report.
Ok, now perfectly clear with the code :-) Maybe you can add the
reference of your e-mail in the archives in the comment ? It would keep
the comment short, but still allow one to understand what's going on
exactly.
Thanks a lot for the clarification !
Thomas
--
Thomas Petazzoni, Free Electrons
Kernel, drivers and embedded Linux development,
consulting, training and support.
http://free-electrons.com
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Buildroot] [PATCH] qtopia4: fix use of pkg-config
2008-10-28 1:51 [Buildroot] [PATCH] qtopia4: fix use of pkg-config Markus Heidelberg
2008-10-28 7:14 ` Thomas Petazzoni
@ 2008-10-28 9:38 ` Peter Korsgaard
1 sibling, 0 replies; 5+ messages in thread
From: Peter Korsgaard @ 2008-10-28 9:38 UTC (permalink / raw)
To: buildroot
>>>>> "Markus" == Markus Heidelberg <markus.heidelberg@web.de> writes:
Markus> When cross compiling, Qt sets PKG_CONFIG in its own configure script to
Markus> an empty string. That leads to not using pkg-config. To avoid that, use
Markus> the configure option -force-pkg-config. Also set environment variables
Markus> for pkg-config defined in TARGET_CONFIGURE_OPTS.
Thanks, committed.
--
Bye, Peter Korsgaard
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2008-10-28 9:38 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-10-28 1:51 [Buildroot] [PATCH] qtopia4: fix use of pkg-config Markus Heidelberg
2008-10-28 7:14 ` Thomas Petazzoni
2008-10-28 8:22 ` Markus Heidelberg
2008-10-28 8:50 ` Thomas Petazzoni
2008-10-28 9:38 ` Peter Korsgaard
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox