Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH] glmark2: depend on host-python
Date: Sun, 27 Sep 2015 21:21:27 +0200	[thread overview]
Message-ID: <20150927212127.2e70faeb@free-electrons.com> (raw)
In-Reply-To: <1443194731-52284-1-git-send-email-Vincent.Riera@imgtec.com>

Vicente,

On Fri, 25 Sep 2015 16:25:31 +0100, Vicente Olivert Riera wrote:
> The waf build system of glmark2 needs Python 2 as stated on its README
> file:
> 
> python 2.x (>= 2.4) for the build system (waf)
> 
> Building it with a system with Python 3 as the default Python version
> will result on a failure like this one:
> 
> File "waflib/Utils.py", line 199
>     except OSError ,e:
>                    ^
> SyntaxError: invalid syntax
> 
> So, in order to fix this, make this package depending on host-python and
> also run the waf script using $(HOST_DIR)/usr/bin/python2.

This part is fine.

> At the same time fix a typo in the .mk file. The python-config script is
> localed at $(HOST_DIR)/usr/bin/ instead of $(STAGING_DIR)/usr/bin/.

But I'm not sure at all about this part.
$(HOST_DIR)/usr/bin/python-config will give results that are valid to
build things against the *host* Python, while
$(STAGING_DIR)/usr/bin/python-config will give results that are valid
to build things against the *target* Python.

Therefore, it is necessary to look into the Waf logic to understand how
PYTHON_CONFIG is used. Is it used to build just things that used
during the build process and therefore probably built against the host
Python, or is it about building things against the target Python?

From a quick look, I don't see anything in the glmark2 source code that
would need Python. It's really only waf itself that uses Python. So I
don't quite see where PYTHON_CONFIG can actually be useful...

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

  parent reply	other threads:[~2015-09-27 19:21 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-09-25 15:25 [Buildroot] [PATCH] glmark2: depend on host-python Vicente Olivert Riera
2015-09-25 15:27 ` Vicente Olivert Riera
2015-09-27 11:21 ` Bernd Kuhls
2015-09-27 19:21 ` Thomas Petazzoni [this message]
2015-09-28  8:33   ` Vicente Olivert Riera
2015-09-28 20:52     ` Thomas Petazzoni
2015-09-29 18:13       ` Vicente Olivert Riera

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20150927212127.2e70faeb@free-electrons.com \
    --to=thomas.petazzoni@free-electrons.com \
    --cc=buildroot@busybox.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox