All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] qt5: QT5_QMAKE spec bug
@ 2016-06-28  9:16 Akihiko Odaki
  2016-07-06 23:25 ` Akihiko Odaki
  0 siblings, 1 reply; 9+ messages in thread
From: Akihiko Odaki @ 2016-06-28  9:16 UTC (permalink / raw)
  To: buildroot

Hi,

I was trying to use QT5_QMAKE variable for a new package.
http://article.gmane.org/gmane.comp.lib.uclibc.buildroot/152724

However, it failed to build. I found that it failed because -spec option 
for cross compiling was applied for host_build. It can be fixed by 
setting the value to QMAKE_XSPEC in qmake configuration instead of using 
the option.

I'm making a patch to apply the change, but I have a question. Now 
QT5_QMAKE variable has the path to qmake, but there are no variables to 
indicate the path for other commands such as python. Should I remove 
QT5_QMAKE variable or keep as it is?

Regards,
Akihiko

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Buildroot] qt5: QT5_QMAKE spec bug
  2016-06-28  9:16 [Buildroot] qt5: QT5_QMAKE spec bug Akihiko Odaki
@ 2016-07-06 23:25 ` Akihiko Odaki
  2016-07-07  7:29   ` Julien CORJON
  0 siblings, 1 reply; 9+ messages in thread
From: Akihiko Odaki @ 2016-07-06 23:25 UTC (permalink / raw)
  To: buildroot

ping

On 2016?06?28? 18:16, Akihiko Odaki wrote:
> Hi,
>
> I was trying to use QT5_QMAKE variable for a new package.
> http://article.gmane.org/gmane.comp.lib.uclibc.buildroot/152724
>
> However, it failed to build. I found that it failed because -spec option
> for cross compiling was applied for host_build. It can be fixed by
> setting the value to QMAKE_XSPEC in qmake configuration instead of using
> the option.
>
> I'm making a patch to apply the change, but I have a question. Now
> QT5_QMAKE variable has the path to qmake, but there are no variables to
> indicate the path for other commands such as python. Should I remove
> QT5_QMAKE variable or keep as it is?
>
> Regards,
> Akihiko

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Buildroot] qt5: QT5_QMAKE spec bug
  2016-07-06 23:25 ` Akihiko Odaki
@ 2016-07-07  7:29   ` Julien CORJON
  2016-07-07 13:55     ` Akihiko Odaki
  0 siblings, 1 reply; 9+ messages in thread
From: Julien CORJON @ 2016-07-07  7:29 UTC (permalink / raw)
  To: buildroot

Hi Akihiko,

-----Message d'origine-----
De?: buildroot [mailto:buildroot-bounces at busybox.net] De la part de Akihiko Odaki
Envoy??: jeudi 7 juillet 2016 01:25
??: buildroot at buildroot.org
Cc?: Thomas Petazzoni
Objet?: Re: [Buildroot] qt5: QT5_QMAKE spec bug

ping

On 2016?06?28? 18:16, Akihiko Odaki wrote:
> Hi,
>
> I was trying to use QT5_QMAKE variable for a new package.
> http://article.gmane.org/gmane.comp.lib.uclibc.buildroot/152724
>
> However, it failed to build. I found that it failed because -spec 
> option for cross compiling was applied for host_build. It can be fixed 
> by setting the value to QMAKE_XSPEC in qmake configuration instead of 
> using the option.
>

This is weird, QT5_QMAKE variable is already used in others packages (e.g. QWT, qt-webkit-kiosk).
If your fix work you could also change qt5xxx packages to use this variable instead of full path $(HOST_DIR)/usr/bin/qmake

> I'm making a patch to apply the change, but I have a question. Now 
> QT5_QMAKE variable has the path to qmake, but there are no variables 
> to indicate the path for other commands such as python. Should I 
> remove QT5_QMAKE variable or keep as it is?

Python and others already have their own infrastructures so they don't need this kind of stuff.
I suggest to keep it as is until someone implement an infrastructure for Qt ;-)

Regards,

Julien

>
> Regards,
> Akihiko
_______________________________________________
buildroot mailing list
buildroot at busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Buildroot] qt5: QT5_QMAKE spec bug
  2016-07-07  7:29   ` Julien CORJON
@ 2016-07-07 13:55     ` Akihiko Odaki
  2016-07-07 14:06       ` Thomas Petazzoni
  0 siblings, 1 reply; 9+ messages in thread
From: Akihiko Odaki @ 2016-07-07 13:55 UTC (permalink / raw)
  To: buildroot

Hi Thomas,

On 2016-07-07 16:29, Julien CORJON wrote:
 > Hi Akihiko,
 >
 > -----Message d'origine-----
 > De : buildroot [mailto:buildroot-bounces at busybox.net] De la part de 
Akihiko Odaki
 > Envoy? : jeudi 7 juillet 2016 01:25
 > ? : buildroot at buildroot.org
 > Cc : Thomas Petazzoni
 > Objet : Re: [Buildroot] qt5: QT5_QMAKE spec bug
 >
 > ping
 >
 > On 2016?06?28? 18:16, Akihiko Odaki wrote:
 >> Hi,
 >>
 >> I was trying to use QT5_QMAKE variable for a new package.
 >> http://article.gmane.org/gmane.comp.lib.uclibc.buildroot/152724
 >>
 >> However, it failed to build. I found that it failed because -spec
 >> option for cross compiling was applied for host_build. It can be fixed
 >> by setting the value to QMAKE_XSPEC in qmake configuration instead of
 >> using the option.
 >>
 >
 > This is weird, QT5_QMAKE variable is already used in others packages 
(e.g. QWT, qt-webkit-kiosk).
 > If your fix work you could also change qt5xxx packages to use this 
variable instead of full path $(HOST_DIR)/usr/bin/qmake

I think those packages are not meant to be built for the host.

 >> I'm making a patch to apply the change, but I have a question. Now
 >> QT5_QMAKE variable has the path to qmake, but there are no variables
 >> to indicate the path for other commands such as python. Should I
 >> remove QT5_QMAKE variable or keep as it is?
 >
 > Python and others already have their own infrastructures so they 
don't need this kind of stuff.

You mean package/pkg-*.mk by the infrastructures? Many packages 
depending on Python don't use package/pkg-python.mk and specify the path 
in their -.mk.

$ git grep bin/python | wc -l
93

I have not checked other commands, but I guess there are similar codes 
for other commands. That's the reason I wonder if I should use the 
variable or not.

 > I suggest to keep it as is until someone implement an infrastructure 
for Qt ;-)

The variable is not used in Qt packages and they will need to be 
modified to use the variable if it is kept. My patches to add a few Qt 
packages are also pending. There is no option to keep as they are.

Regards,
Akihiko Odaki

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Buildroot] qt5: QT5_QMAKE spec bug
  2016-07-07 13:55     ` Akihiko Odaki
@ 2016-07-07 14:06       ` Thomas Petazzoni
  2016-07-07 14:31         ` Akihiko Odaki
  0 siblings, 1 reply; 9+ messages in thread
From: Thomas Petazzoni @ 2016-07-07 14:06 UTC (permalink / raw)
  To: buildroot

Hello,

On Thu, 7 Jul 2016 22:55:36 +0900, Akihiko Odaki wrote:

> I think those packages are not meant to be built for the host.

QT5_QMAKE is a variable meant to built qmake-based packages for the
target. It has never been intended to build qmake-based packages for
the host.

Which qmake-based package do you need to build for host? Notice that we
do not build qt5 for the host, so in order to build qmake-based
packages for the host, you would first have to create a host-qt5base
package, which is going to cause a lot of problems down the road.

>  > Python and others already have their own infrastructures so they   
> don't need this kind of stuff.
> 
> You mean package/pkg-*.mk by the infrastructures? Many packages 
> depending on Python don't use package/pkg-python.mk and specify the path 
> in their -.mk.
> 
> $ git grep bin/python | wc -l
> 93

Using Python and being a Python package are completely different things.

The Python package infrastructure is used by Python modules that use
distutils or setuptools.

But besides that, lots of packages use Python in their build process,
even if they are not at all Python modules.

> The variable is not used in Qt packages and they will need to be 
> modified to use the variable if it is kept. My patches to add a few Qt 
> packages are also pending. There is no option to keep as they are.

Not sure I understood this part.

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Buildroot] qt5: QT5_QMAKE spec bug
  2016-07-07 14:06       ` Thomas Petazzoni
@ 2016-07-07 14:31         ` Akihiko Odaki
  2016-07-07 14:53           ` Thomas Petazzoni
  2016-07-17  2:06           ` Akihiko Odaki
  0 siblings, 2 replies; 9+ messages in thread
From: Akihiko Odaki @ 2016-07-07 14:31 UTC (permalink / raw)
  To: buildroot

Hi,

On 2016-07-07 23:06, Thomas Petazzoni wrote:
> Hello,
>
> On Thu, 7 Jul 2016 22:55:36 +0900, Akihiko Odaki wrote:
>
>> I think those packages are not meant to be built for the host.
>
> QT5_QMAKE is a variable meant to built qmake-based packages for the
> target. It has never been intended to build qmake-based packages for
> the host.
>
> Which qmake-based package do you need to build for host? Notice that we
> do not build qt5 for the host, so in order to build qmake-based
> packages for the host, you would first have to create a host-qt5base
> package, which is going to cause a lot of problems down the road.

qtwaylandscanner in qt5wayland, a package I made. Actually it can be 
built without host-qt5base.

http://code.qt.io/cgit/qt/qtwayland.git/tree/src/qtwaylandscanner

>>  > Python and others already have their own infrastructures so they
>> don't need this kind of stuff.
>>
>> You mean package/pkg-*.mk by the infrastructures? Many packages
>> depending on Python don't use package/pkg-python.mk and specify the path
>> in their -.mk.
>>
>> $ git grep bin/python | wc -l
>> 93
>
> Using Python and being a Python package are completely different things.
>
> The Python package infrastructure is used by Python modules that use
> distutils or setuptools.
>
> But besides that, lots of packages use Python in their build process,
> even if they are not at all Python modules.

Anyway, such building tools have no variables for their pathes?

>> The variable is not used in Qt packages and they will need to be
>> modified to use the variable if it is kept. My patches to add a few Qt
>> packages are also pending. There is no option to keep as they are.
>
> Not sure I understood this part.

So actually packages in package/qt5 doesn't use QT5_QMAKE variable.

$ git grep bin/qmake package/qt5 | wc -l
23

Shouldn't they refer to QT5_QMAKE if it is kept?

In contrast, QT5_QMAKE is referred in 4 packages.

$ git grep QT5_QMAKE package | wc -l
5

Regards,
Akihiko Odaki

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Buildroot] qt5: QT5_QMAKE spec bug
  2016-07-07 14:31         ` Akihiko Odaki
@ 2016-07-07 14:53           ` Thomas Petazzoni
  2016-07-17  2:06           ` Akihiko Odaki
  1 sibling, 0 replies; 9+ messages in thread
From: Thomas Petazzoni @ 2016-07-07 14:53 UTC (permalink / raw)
  To: buildroot

Hello,

On Thu, 7 Jul 2016 23:31:14 +0900, Akihiko Odaki wrote:

> qtwaylandscanner in qt5wayland, a package I made. Actually it can be 
> built without host-qt5base.

No, it cannot (from the link you pointed) :

#include <QCoreApplication>
#include <QFile>
#include <QXmlStreamReader>

If it builds on your build machine, it's because you have the Qt5
development files installed. But you cannot rely on them being
available on the build machine of every Buildroot user.

> > Using Python and being a Python package are completely different things.
> >
> > The Python package infrastructure is used by Python modules that use
> > distutils or setuptools.
> >
> > But besides that, lots of packages use Python in their build process,
> > even if they are not at all Python modules.  
> 
> Anyway, such building tools have no variables for their pathes?

Not necessarily. The QT5_QMAKE variable exists precisely because some
arguments must be passed to qmake to make it build code for the target.

> >> The variable is not used in Qt packages and they will need to be
> >> modified to use the variable if it is kept. My patches to add a few Qt
> >> packages are also pending. There is no option to keep as they are.  
> >
> > Not sure I understood this part.  
> 
> So actually packages in package/qt5 doesn't use QT5_QMAKE variable.
> 
> $ git grep bin/qmake package/qt5 | wc -l
> 23
> 
> Shouldn't they refer to QT5_QMAKE if it is kept?

Yes, they probably should, indeed.

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Buildroot] qt5: QT5_QMAKE spec bug
  2016-07-07 14:31         ` Akihiko Odaki
  2016-07-07 14:53           ` Thomas Petazzoni
@ 2016-07-17  2:06           ` Akihiko Odaki
  2016-07-24 22:43             ` Akihiko Odaki
  1 sibling, 1 reply; 9+ messages in thread
From: Akihiko Odaki @ 2016-07-17  2:06 UTC (permalink / raw)
  To: buildroot

Hi,

On 2016-07-07 23:53, Thomas Petazzoni wrote:
 > Hello,
 >
 > On Thu, 7 Jul 2016 23:31:14 +0900, Akihiko Odaki wrote:
 >
 >> qtwaylandscanner in qt5wayland, a package I made. Actually it can be
 >> built without host-qt5base.
 >
 > No, it cannot (from the link you pointed) :
 >
 > #include <QCoreApplication>
 > #include <QFile>
 > #include <QXmlStreamReader>
 >
 > If it builds on your build machine, it's because you have the Qt5
 > development files installed. But you cannot rely on them being
 > available on the build machine of every Buildroot user.

They seems to be provided by libQt5Bootstrap.

$ grep LIBS output/build/qt5wayland-5.6.1-1/src/qtwaylandscanner/Makefile
LIBS          = $(SUBLIBS) -L/home/root3/buildroot/output/host/usr/lib 
-lQt5Bootstrap -lpthread
	$(LINK) $(LFLAGS) -o $(TARGET) $(OBJECTS) $(OBJCOMP) $(LIBS)

Qt provides the option of host_build and the patch is to utilize it. I 
guess it is limited for use of compiling tools necessary for target build.

See qmake documentation for host_build option.
http://doc.qt.io/qt-5/qmake-environment-reference.html

 >>> Using Python and being a Python package are completely different 
things.
 >>>
 >>> The Python package infrastructure is used by Python modules that use
 >>> distutils or setuptools.
 >>>
 >>> But besides that, lots of packages use Python in their build process,
 >>> even if they are not at all Python modules.
 >>
 >> Anyway, such building tools have no variables for their pathes?
 >
 > Not necessarily. The QT5_QMAKE variable exists precisely because some
 > arguments must be passed to qmake to make it build code for the target.

qmake can have a system for persistent configuration and it is intended 
for such uses, and also allows to distinguish the target build and the 
host build. Shouldn't QT5_QMAKE be removed and use the system?

By the way, the system is already used for some configurations. See 
commit 86db2a76e2f07d003464d5e0383d3ea437dc47d9.

Regards,
Akihiko Odaki

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Buildroot] qt5: QT5_QMAKE spec bug
  2016-07-17  2:06           ` Akihiko Odaki
@ 2016-07-24 22:43             ` Akihiko Odaki
  0 siblings, 0 replies; 9+ messages in thread
From: Akihiko Odaki @ 2016-07-24 22:43 UTC (permalink / raw)
  To: buildroot

ping

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2016-07-24 22:43 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-06-28  9:16 [Buildroot] qt5: QT5_QMAKE spec bug Akihiko Odaki
2016-07-06 23:25 ` Akihiko Odaki
2016-07-07  7:29   ` Julien CORJON
2016-07-07 13:55     ` Akihiko Odaki
2016-07-07 14:06       ` Thomas Petazzoni
2016-07-07 14:31         ` Akihiko Odaki
2016-07-07 14:53           ` Thomas Petazzoni
2016-07-17  2:06           ` Akihiko Odaki
2016-07-24 22:43             ` Akihiko Odaki

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.