public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Heiko Schocher <hs@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [BUG] powerpc: tqm5200: does not compile with current HEAD
Date: Mon, 23 Jan 2017 10:08:26 +0100	[thread overview]
Message-ID: <5885C80A.3060403@denx.de> (raw)

Hello,

building powerpc based tqm5200 board fails with current HEAD
(at least on fedora host):

pollux:u-boot-tqm5200 hs [master] $ ./tools/buildman/buildman TQM5200S
boards.cfg is up to date. Nothing to do.
Building current source for 2 boards (2 threads, 4 jobs per thread)
    powerpc:  +   TQM5200S
+In file included from /usr/include/python2.7/pyconfig.h:6:0,
+                 from /usr/include/python2.7/Python.h:8,
+                 from tools/libfdt_wrap.c:147:
+/usr/include/python2.7/pyconfig-64.h:1202:0: Warnung: ?_POSIX_C_SOURCE? redefiniert
+ #define _POSIX_C_SOURCE 200112L
+
+In file included from /usr/include/stdint.h:25:0,
+                 from /usr/lib/gcc/x86_64-redhat-linux/6.3.1/include/stdint.h:9,
+                 from include/compiler.h:19,
+                 from include/libfdt_env.h:12,
+                 from <Kommandozeile>:0:
+/usr/include/features.h:225:0: Anmerkung: dies ist die Stelle der vorherigen Definition
+ # define _POSIX_C_SOURCE 200809L
+/usr/include/python2.7/pyconfig-64.h:1224:0: Warnung: ?_XOPEN_SOURCE? redefiniert
+ #define _XOPEN_SOURCE 600
+/usr/include/features.h:166:0: Anmerkung: dies ist die Stelle der vorherigen Definition
+ # define _XOPEN_SOURCE 700
+gcc: Fehler: nicht erkannte Kommandozeilenoption ?-melf32ppclinux?
+error: command 'gcc' failed with exit status 1
+make[2]: *** [tools/_libfdt.so] Fehler 1
+make[1]: *** [tools] Fehler 2
+make: *** [sub-make] Fehler 2
[...]

Also no chance using ELDK ...

reverting patch:
1905c8fc711a: build: Always build the libfdt python module

and I can again build the TQM5200 board...

Hmm.. first I wonder, why do we need at all such things like SWIG
for a U-Boot build... ? Is this really needed?

Here the Code in tools/Makefile:
# Build a libfdt Python module if swig is available
# Use 'sudo apt-get install swig libpython-dev' to enable this
hostprogs-$(CONFIG_SPL_OF_PLATDATA) += \
         $(if $(shell which swig 2> /dev/null),_libfdt.so)
_libfdt.so-sharedobjs += $(LIBFDT_OBJS)
libfdt:
[...]

Comment says we need swig *and* libpython-dev ... but the check is only
for "swig" ... What is when there is no "libpython-dev" ?

Like on fedora:
# dnf install libpython-dev Last metadata expiration check: 1:50:58 ago on Mon Jan 23 07:49:26 2017.
No package libpython-dev available.
Error: Unable to find a match.

Ok, the following patch applied to mainline, and current HEAD of U-Boot
builds again for the tqm5200 board on my fedora host:

diff --git a/tools/Makefile b/tools/Makefile
index a609d05..a8a5599 100644
--- a/tools/Makefile
+++ b/tools/Makefile
@@ -112,7 +112,7 @@ fit_check_sign-objs   := $(dumpimage-mkimage-objs) fit_check_sign.o
  # Build a libfdt Python module if swig is available
  # Use 'sudo apt-get install swig libpython-dev' to enable this
  hostprogs-y += \
-       $(if $(shell which swig 2> /dev/null),_libfdt.so)
+       $(if $(shell which swig libpython-dev 2> /dev/null),_libfdt.so)
  _libfdt.so-sharedobjs += $(LIBFDT_OBJS)
  libfdt:

Any comments? Ideas?

bye,
Heiko
-- 
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany

             reply	other threads:[~2017-01-23  9:08 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-23  9:08 Heiko Schocher [this message]
2017-01-23 12:56 ` [U-Boot] [BUG] powerpc: tqm5200: does not compile with current HEAD Simon Glass
2017-01-23 13:17   ` Tom Rini
2017-01-23 13:25     ` Simon Glass

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=5885C80A.3060403@denx.de \
    --to=hs@denx.de \
    --cc=u-boot@lists.denx.de \
    /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