[PATCH v2] sb: Add support to search for a suitable version of python.

Chris Johns chrisj at rtems.org
Wed Oct 24 10:13:56 UTC 2018


On 24/10/18 9:03 pm, Malte Münch wrote:
> This is the output:

Thanks.

> [mamu at verstappen rtems]$   echo “” | gcc -xc -E -v -
> Es werden eingebaute Spezifikationen verwendet.
> COLLECT_GCC=gcc
> Ziel: x86_64-pc-linux-gnu
> Konfiguriert mit: /build/gcc/src/gcc/configure --prefix=/usr
> --libdir=/usr/lib --libexecdir=/usr/lib --mandir=/usr/share/man
> --infodir=/usr/share/info --with-bugurl=https://bugs.archlinux.org/
> --enable-languages=c,c++,ada,fortran,go,lto,objc,obj-c++ --enable-shared
> --enable-threads=posix --enable-libmpx --with-system-zlib --with-isl
> --enable-__cxa_atexit --disable-libunwind-exceptions
> --enable-clocale=gnu --disable-libstdcxx-pch --disable-libssp
> --enable-gnu-unique-object --enable-linker-build-id --enable-lto
> --enable-plugin --enable-install-libiberty --with-linker-hash-style=gnu
> --enable-gnu-indirect-function --enable-multilib --disable-werror
> --enable-checking=release --enable-default-pie --enable-default-ssp
> --enable-cet=auto
> Thread-Modell: posix
> gcc-Version 8.2.1 20180831 (GCC)
> COLLECT_GCC_OPTIONS='-E' '-v' '-mtune=generic' '-march=x86-64'
>  /usr/lib/gcc/x86_64-pc-linux-gnu/8.2.1/cc1 -E -quiet -v -
> -mtune=generic -march=x86-64
> nicht vorhandenes Verzeichnis
> »/usr/lib/gcc/x86_64-pc-linux-gnu/8.2.1/../../../../x86_64-pc-linux-gnu/include«
> wird ignoriert
> doppeltes Verzeichnis »/usr/include« wird ignoriert
> Suche für »#include "..."« beginnt hier:
> Suche für »#include <...>« beginnt hier:

Oh of course this makes sense.

>  /usr/include/
>  /usr/lib/gcc/x86_64-pc-linux-gnu/8.2.1/include
>  /usr/local/include
>  /usr/lib/gcc/x86_64-pc-linux-gnu/8.2.1/include-fixed
> Ende der Suchliste.
> # 1 "<stdin>"
> # 1 "<eingebaut>"
> # 1 "<Kommandozeile>"
> # 31 "<Kommandozeile>"
> # 1 "/usr/include/stdc-predef.h" 1 3
> # 32 "<Kommandozeile>" 2
> # 1 "<stdin>"
> “”
> COMPILER_PATH=/usr/lib/gcc/x86_64-pc-linux-gnu/8.2.1/:/usr/lib/gcc/x86_64-pc-linux-gnu/8.2.1/:/usr/lib/gcc/x86_64-pc-linux-gnu/:/usr/lib/gcc/x86_64-pc-linux-gnu/8.2.1/:/usr/lib/gcc/x86_64-pc-linux-gnu/
> LIBRARY_PATH=/usr/lib/gcc/x86_64-pc-linux-gnu/8.2.1/:/usr/lib/gcc/x86_64-pc-linux-gnu/8.2.1/../../../../lib/:/lib/../lib/:/usr/lib/../lib/:/usr/lib/gcc/x86_64-pc-linux-gnu/8.2.1/../../../:/lib/:/usr/lib/
> COLLECT_GCC_OPTIONS='-E' '-v' '-mtune=generic' '-march=x86-64'
> [mamu at verstappen rtems]$ which gcc
> /usr/bin/gcc
>  unfortunately part of the output is in german.

Nothing unfortunate just something I did not consider. What happens with:

echo “” | LC_ALL= gcc -xc -E -v -

?

It is matter of forcing gcc in the script into English so markers in the script
can be searched for.

> It looks like
> /usr/include is included but /usr/include/python2.7 isn't

That is expected. The gdb config script in the RSB knows how to find the python
major and minor version numbers and then to inspect this directory.

Chris



More information about the devel mailing list