diff mbox

Error building Qt5Multimedia

Message ID CAAXf6LWEAPs-EpsHzgqJ1eiiRL+u2rssa_SM0EE5=6yQxrtbZQ@mail.gmail.com
State Not Applicable
Headers show

Commit Message

Thomas De Schampheleire March 18, 2014, 3:53 p.m. UTC
Hi Marco,

On Tue, Mar 18, 2014 at 3:45 PM, Marco Trapanese
<marcotrapanese@gmail.com> wrote:
>
> Thomas,
>
>> You can go to output/build/qt5multimedia and try to re-execute the
>> command mentioned in config.log related to the gstreamer test. Maybe
>> you can debug based on that, maybe using 'strace -fo /tmp/out
>> <command>' to check what kind of files it is looking for.
>
>
>
> I issued:
>
> cd
> /home/marco/dev/buildroot/output/build/qt5multimedia-5.2.1/config.tests/gstreamer
>
> strace -fo /tmp/out /home/marco/dev/buildroot/output/host/usr/bin/qmake
> "CONFIG -= qt debug_and_release app_bundle lib_bundle"
> /home/marco/dev/buildroot/output/build/qt5multimedia-5.2.1/config.tests/gstreamer
>
> Project ERROR: gstreamer-0.10 development package not found
>
> Here the strace output:
>
> http://code.bulix.org/7oi5mj-85862
>
> I'm not so expert to understand what's happening.
>
> Unfortunately this feature is mandatory for my project.

The problem is this:

3752  stat64("/usr/local/bin/pkg-config", 0xbf8c2860) = -1 ENOENT (No
such file or directory)
3752  stat64("/usr/bin/pkg-config", 0xbf8c2860) = -1 ENOENT (No such
file or directory)
3752  stat64("/bin/pkg-config", 0xbf8c2860) = -1 ENOENT (No such file
or directory)
3752  stat64("/usr/local/games/pkg-config", 0xbf8c2860) = -1 ENOENT
(No such file or directory)
3752  stat64("/usr/games/pkg-config", 0xbf8c2860) = -1 ENOENT (No such
file or directory)
3752  write(2, "sh: 1: ", 7)            = 7
3752  write(2, "pkg-config: not found", 21) = 21
3752  write(2, "\n", 1)                 = 1
3752  dup2(10, 2)                       = 2
3752  close(10)                         = 0
3752  exit_group(127)                   = ?
3751  <... waitpid resumed> [{WIFEXITED(s) && WEXITSTATUS(s) == 127}], 0) = 3752
3751  rt_sigaction(SIGINT, {SIG_DFL, [], 0}, NULL, 8) = 0
3751  rt_sigaction(SIGQUIT, {SIG_DFL, [], 0}, NULL, 8) = 0
3751  rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0
3751  --- SIGCHLD (Child exited) @ 0 (0) ---
3751  write(2, "Project ERROR: gstreamer-0.10 de"..., 60) = 60
3751  exit_group(3)

It tries to find pkg-config, but fails to do so. pkg-config is used in
the test to try and find gstreamer.
Normally, pkg-config should come from buildroot itself
(output/host/usr/bin/pkg-config) but it seems this is not happening
here.

I did the same on my machine, and it seems /usr/bin/pkg-config is
used. This is not supposed to happen.
It explains why building the same configuration on different machines
gives different results.

This is actually a bug.
Could you try following patch:

$ hg diff

and after applying this patch run:
make qt5multimedia-dirclean qt5multimedia

I believe this should fix the problem. The same solution should be
applied to the other qt5 packages.
Or maybe someone else thinks the problem should be fixed in a different way.
I'm adding some people to this thread so they can shed their light on it...

Best regards,
Thomas

Comments

Thomas Petazzoni March 18, 2014, 6:27 p.m. UTC | #1
Dear Thomas De Schampheleire,

On Tue, 18 Mar 2014 16:53:17 +0100, Thomas De Schampheleire wrote:

>  define QT5MULTIMEDIA_CONFIGURE_CMDS
> -       (cd $(@D); $(HOST_DIR)/usr/bin/qmake)
> +       (cd $(@D); $(TARGET_MAKE_ENV) $(HOST_DIR)/usr/bin/qmake)
>  endef
> 
>  define QT5MULTIMEDIA_BUILD_CMDS
> 
> and after applying this patch run:
> make qt5multimedia-dirclean qt5multimedia
> 
> I believe this should fix the problem. The same solution should be
> applied to the other qt5 packages.
> Or maybe someone else thinks the problem should be fixed in a different way.
> I'm adding some people to this thread so they can shed their light on it...

Your change indeed looks good.

Thomas
Marco Trapanese March 19, 2014, 5:31 a.m. UTC | #2
Hi Thomas,

Il 18/03/2014 16:53, Thomas De Schampheleire ha scritto:

>
> This is actually a bug.
> Could you try following patch:
>
> $ hg diff
> diff --git a/package/qt5/qt5multimedia/qt5multimedia.mk
> b/package/qt5/qt5multimedia/qt5multimedia.mk
> --- a/package/qt5/qt5multimedia/qt5multimedia.mk
> +++ b/package/qt5/qt5multimedia/qt5multimedia.mk
> @@ -25,7 +25,7 @@ QT5MULTIMEDIA_DEPENDENCIES += gst-plugin
>   endif
>
>   define QT5MULTIMEDIA_CONFIGURE_CMDS
> -       (cd $(@D); $(HOST_DIR)/usr/bin/qmake)
> +       (cd $(@D); $(TARGET_MAKE_ENV) $(HOST_DIR)/usr/bin/qmake)
>   endef
>
>   define QT5MULTIMEDIA_BUILD_CMDS
>
> and after applying this patch run:
> make qt5multimedia-dirclean qt5multimedia
>
> I believe this should fix the problem. The same solution should be
> applied to the other qt5 packages.
> Or maybe someone else thinks the problem should be fixed in a different way.
> I'm adding some people to this thread so they can shed their light on it...


I confirm it compiled successfully after applying your patch. I haven't 
tried yet QtMultimedia on the target, but at least there were no errors 
at compile-time :-)

Thank you for your support!
Marco
Marco Trapanese March 20, 2014, 7:25 p.m. UTC | #3
Il 19/03/2014 06:31, Marco Trapanese ha scritto:
> I confirm it compiled successfully after applying your patch. I 
> haven't tried yet QtMultimedia on the target, but at least there were 
> no errors at compile-time :-)


I'm glad to say it works!

Thank you
Marco
Thomas De Schampheleire March 20, 2014, 8:16 p.m. UTC | #4
Hi Marco,

On Thu, Mar 20, 2014 at 8:25 PM, Marco Trapanese
<marcotrapanese@gmail.com> wrote:
> Il 19/03/2014 06:31, Marco Trapanese ha scritto:
>
>> I confirm it compiled successfully after applying your patch. I haven't
>> tried yet QtMultimedia on the target, but at least there were no errors at
>> compile-time :-)
>
>
>
> I'm glad to say it works!
>

That's great, thanks for your feedback!
In the mean time I sent patches to the list to fix this issue for all
qt packages.

Best regards,
Thomas
diff mbox

Patch

diff --git a/package/qt5/qt5multimedia/qt5multimedia.mk
b/package/qt5/qt5multimedia/qt5multimedia.mk
--- a/package/qt5/qt5multimedia/qt5multimedia.mk
+++ b/package/qt5/qt5multimedia/qt5multimedia.mk
@@ -25,7 +25,7 @@  QT5MULTIMEDIA_DEPENDENCIES += gst-plugin
 endif

 define QT5MULTIMEDIA_CONFIGURE_CMDS
-       (cd $(@D); $(HOST_DIR)/usr/bin/qmake)
+       (cd $(@D); $(TARGET_MAKE_ENV) $(HOST_DIR)/usr/bin/qmake)
 endef

 define QT5MULTIMEDIA_BUILD_CMDS