Re: Gcc on Blue Gene / Q

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Fatih Ertinaz kirjoitti 22.2.2018 klo 17:55:

I decided to try a different version; gcc-5.2.0 which seems to fail at
the exact step:
make[2]: Leaving directory
`......../gcc/gcc-5.2.0-work/powerpc64-bgq-linux/libgcc'
/bin/sh: line 3: cd: powerpc64-bgq-linux/libstdc++-v3: No such file or directory
make[1]: *** [install-target-libstdc++-v3] Error 1

Probably the build simply didn't produce 'target-libstdc++-v3' at all because there
weren't any target headers and libraries available.

One quick question:
               --target=powerpc64-bgq-linux \
               --host=powerpc64-linux-gnu \
               --build=powerpc64-linux-gnu \
Those host and build values look wrong.
Why?

If the $target value is different from the $host value, then one is trying to make a crosscompiler, not a native compiler!  A crosscompiler doesn't search the target stuff in the native places, usually '/usr/include' and '/usr/lib'. But as default searches them in the '$prefix/$target/include' and '$prefix/$target/lib' unless one has used the '--with-sysroot=$sysroot' to point where the target stuff is,
copied from the native $target system.

> checking whether the ...../gcc/gcc-5.5.0-work/./gcc/xgcc
> -B/..../gcc/gcc-5.5.0-work/./gcc/
> -B/..../gcc-5.5.0/powerpc64-bgq-linux/bin/
> -B/..../gcc-5.5.0/powerpc64-bgq-linux/lib/
> -isystem /..../gcc-5.5.0/powerpc64-bgq-linux/include
> -isystem /..../gcc-5.5.0/powerpc64-bgq-linux/sys-include

Here were the search paths but that ''/..../gcc-5.5.0/' doesn't look sane at all as the wanted $prefix. With a native GCC one usually uses '--prefix=/' or the default '--prefix=/usr/local' when leaving the '--prefix=<something>' totally away from the
GCC configure command...

I will not try more to tell why the second place for the headers, the "system headers" : '/..../gcc-5.5.0/powerpc64-bgq-linux/sys-include' is there. Only that it is a remnant from the dark past when there were systems which had new headers, "system specific", not only the "standard" posix ones. Usually they were the GUI / API headers like in Windows, X11, BeOS etc systems but when the native systems didn't have a separate place for them (like '/usr/sys-include'), neither a crosscompiler put them to the '$prefix/$target/sys-include' although it was ready for them. Instead some believed that it was the place for the standard posix headers, not the '$prefix/$target/include'. This then caused a horrible mess which the '--with-sysroot=$sysroot' solved, one just put the native headers into the $sysroot just in the same way as they were in the
native sysroot '/'....

Ok, you should use :

--build=powerpc64-bgq-linux \
--host=powerpc64-bgq-linux \
--target=powerpc64-bgq-linux \

or barely the '--host=powerpc64-bgq-linux' or leave them totally away, then
the build/host/target triplets will be 'guessed' via the 'config.guess'
script in the main GCC source directory...




[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux