gmb problem on rhel6
Hi all,
I am trying to build arm tool chain on my rhel6 machine.
I have the same problem like in https:/
I have downloaded latest version of arm gcc.
The native gcc is installed like it was described in step 4, but I don't know how to use it.
The suggested solution with updating ppl to version 12 something is not possible since I can install only version 10 something.
Thanks
Question information
- Language:
- English Edit question
- Status:
- Solved
- Assignee:
- No assignee Edit question
- Solved by:
- Nemanja Savic
- Solved:
- Last query:
- Last reply:
Revision history for this message
![]() |
#1 |
Today I've found another solution - replace "--with-
I've compiled the toolchain several times, solving dozens of problems, so feel free to ask (;
BTW - I'm compiling using my "normal" gcc (most recent), without installing specific version like in the description. If you do the same, make sure to update variables in build-common.sh. I have them like that:
BUILD=x86_
HOST_LINUX=
HOST_MINGW=
HOST_MINGW_
Revision history for this message
![]() |
#2 |
Unfortunately, this suggestions didn't solve my problem.
I changed --with-
checking how to link with libgmp... -lgmp
checking how to link with libgmpxx... -lgmpxx -lgmp
checking for the GMP library version 4.1.3 or above... no
configure: error: Cannot find GMP version 4.1.3 or higher.
GMP is the GNU Multi-Precision library:
see http://
When compiling the GMP library, do not forget to enable the C++ interface:
add --enable-cxx to the configuration options.
[savi_ne@
[1] 11945
[savi_ne@
DLR passwd:
Loaded plugins: refresh-packagekit, rhnplugin
Setting up Install Process
Package gmp-4.3.
Nothing to do
Revision history for this message
![]() |
#3 |
I have just found that I make a mistake and put on one plate --with-gmp-prefix. When I changed that, I got similar proble, slightly different:
checking for shared library run path origin... done
checking how to link with libgmp... /home/savi_
checking how to link with libgmpxx... /home/savi_
checking for the GMP library version 4.1.3 or above... no
configure: error: Cannot find GMP version 4.1.3 or higher.
GMP is the GNU Multi-Precision library:
see http://
When compiling the GMP library, do not forget to enable the C++ interface:
add --enable-cxx to the configuration options.
[1]- Done gedit build-prerequis
[2]+ Done gedit build-prerequis
I hope somebody will have any suggestion what to do next.
P.S. I am using RHEL6
Regards
Nemanja
Revision history for this message
![]() |
#4 |
But the scripts search for GMP in toolchain build directory - something like build_linux/
Why can't you try to replace PPL with 0.12.1 in toolchain src dir and updating version number in build-common.sh? That's all it takes to use newer PPL.
4\/3!!
Revision history for this message
![]() |
#5 |
I suppose because of this:
[savi_ne@ts gcc-arm-
Loaded plugins: refresh-packagekit, rhnplugin
Setting up Install Process
Package ppl-0.10.
Nothing to do
I think the main problem is that I am not so involved in using linux.
Revision history for this message
![]() |
#6 |
If you only use the toolchain on the build system, you can use the gmp from your system, i.e. remove the build for gmp.
Revision history for this message
![]() |
#7 |
Does this mean that I should comment his in build-prerequis
echo Task [1-1] /$HOST_LINUX/gmp/
rm -rf $BUILDDIR_LINUX/gmp && mkdir -p $BUILDDIR_LINUX/gmp
pushd $BUILDDIR_LINUX/gmp
CPPFLAGS=
--host=
--prefix=
--enable-cxx \
--disable-
--disable-nls
make -j$JOBS
make install
#make check
popd
?
Revision history for this message
![]() |
#8 |
Yes, but you'll need to supply proper paths to GMP to other components that need it. Actually you probably don't need most of the libraries from the prerequisites if you have them on your system.
4\/3!!
Revision history for this message
![]() |
#9 |
OK, can you suggest me how to install proper version of ppl or how to supply proper paths to GMP?
I commented mentioned part and nothing happened again.
Revision history for this message
![]() |
#10 |
Hi Nemanja Savic,
Can you help me confirm whether the problem can be fixed by using the newly built gcc as in step 4?
You can just modify the environment files to add the path, for example on Ubuntu:
edit "~/.bashrc" by adding following code at the end of file:
export PATH=XXX:$PATH
in which XXX is the path where you installed the newly built GCC.
I think it's something similar for rhel6 system.
After that, please use following command to verify the newlib built GCC is in PATH:
$ which gcc
Hoping this help.
Revision history for this message
![]() |
#11 |
I built new gcc like few days ago, or I hope that it was successful build, cause it lasted for one hour or so.
I added new path as it was suggested.
[savi_ne@
bash: export: `/home/
[savi_ne@
/usr/bin/gcc
Obviousely, something is wrong.
Revision history for this message
![]() |
#12 |
Ok, I managed to install properly native gcc:
[savi_ne@
~/tools/
Does this mean that my default gcc is nativ-gcc or not?
Is there any specific action for compiling arn tool chain using native-gcc or I should act as usual?
Regards
Revision history for this message
![]() |
#13 |
@chengbin
the problem vannot be solved using native-gcc. I still have the same problem.
checking how to link with libgmp... -lgmp
checking how to link with libgmpxx... -lgmpxx -lgmp
checking for the GMP library version 4.1.3 or above... no
configure: error: Cannot find GMP version 4.1.3 or higher.
GMP is the GNU Multi-Precision library:
see http://
When compiling the GMP library, do not forget to enable the C++ interface:
add --enable-cxx to the configuration options.
Revision history for this message
![]() |
#14 |
Sorry I haven't tried the build process on rhel6, now I am not sure what the problem is.
Basically, in our release, GCC(version 4.6) requires GMP/MPFR/
You can refer to GCC document at http://
After understanding the relations between these prerequisites and GCC, you can open config.log and check why it cannot find the correct version GMP.
NOTE, the GCC document is for GCC trunk, it requires ISL, rather than ppl as our release.
Hoping this can help.
Revision history for this message
![]() |
#15 |
But it's PPL that doesn't find GMP, not GCC... It's in the "build-
Revision history for this message
![]() |
#16 |
Yes, that is the problem. So, any new suggestions?
Revision history for this message
![]() |
#17 |
Somewhere is stated about installing first gmp, mpfr, mps and ppl with some proper configuration, and then installing GCC using previously installed tools.
Do you think that this is proper way?
Revision history for this message
![]() |
#18 |
You always do it this way, but that's not the problem anyway [; Try PPL 0.12.1 - when I tried some time ago it solved the problem you have. Now - when I build "natively" (so my PC is x86_64-... and I set BUILD and HOST variables in build-common.sh to this type) - it works with PPL 0.11, but when I try to do it non-natively (like specifying that HOST would be i686) it still fails. Fortunately I don't need 32-bit binary anyway (; Maybe you could try that too? If your PC and your OS is 64-bits you should specify these variables to be the same as your system, so x86_64-linux-gnu it I remember correctly.
4\/3!!
Revision history for this message
![]() |
#19 |
There is also another question (sorry for a lot of them):
In native gcc as you can see this path
~/tools/
There is no i686, can this be becuse of bad native-gcc installation?
Revision history for this message
![]() |
#20 |
Actually I was talking about compiling the toolchain with the "native compiler" of your system (the one from RHEL6), not compiling your own compiler. Try looking for that compiler in /usr, /bin or sth like that (sorry, don't know much about linux), and use it. It will probably be x86_64-
Revision history for this message
![]() |
#21 |
I still haven't installed this tool under RHEL6. Any new suggestions?
Revision history for this message
![]() |
#22 |
Very sorry that we have no RHEL6 system, so no progress on this issue yet.
Is it possible for you to re-build the toolchain on other validated platforms?
Revision history for this message
![]() |
#23 |
Hi Nemanja,
I managed to set up a 64bit RHEL 6.2 system and can reproduce this issue. During the PPL configuration, a file named conftest.c will be generated and built to verify whether there are GMP head files and library files in current environment. So to successfully build this file, the PPL configuration process needs to know where to find those head files and library files. With option "--with-
If use options like "--with-gmp=DIR" or "--with-
To quick fix this issue, just specify the correct path to .h files in CXXFLAGS and CFLAGS, the path to .a files in LDFLAGS when configure PPL. In my system, I configure PPL with:
#######
echo Task [I-4] /$HOST_LINUX/ppl/
rm -rf $BUILDDIR_LINUX/ppl && mkdir -p $BUILDDIR_LINUX/ppl
pushd $BUILDDIR_LINUX/ppl
CFLAGS=
CXXFLAGS=
LDFLAGS=
$SRCDIR/
--host=
--target=
--prefix=
--disable-
--disable-nls \
--enable-
--with-
make
make install
popd
#######
The new option "--enable-
Also please remember to update the --host and --build to something like:
BUILD=x86_
HOST_LINUX=
With above changes, I can build the prerequisite libraries and toolchain on my 64bit RHEL 6.2 machine.
Hope those are helpful.
Revision history for this message
![]() |
#24 |
Hi all,
hm, I haven't been trying to install this for a two months or so now, so I have forgot about the things I was doing before. But this looks very promissing. Here I can only use RHEL and nothing else, that's the biggest problem, because otherwise I would install ubuntu and be in peace.
Since I have deleted everything I have to start again from scratch.
I have changed variables BUILD and HOST_LINUX.
In build-prerequis
Best regards and thank you
Nemanja
Revision history for this message
![]() |
#25 |
And also maybe this can be usefull for u to tell me what's wrong. i mean obviousely gmp libraries again, but maybe something else
/home/savi_
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking how to create a ustar tar archive... gnutar
checking for x86_64-
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking whether we are actually using the Intel C compiler... no
checking for x86_64-
checking for x86_64-
checking for x86_64-
checking for x86_64-
checking for x86_64-
checking for x86_64-
checking for x86_64-
checking for x86_64-
checking for x86_64-
checking for x86_64-
checking for x86_64-
checking for x86_64-
checking for x86_64-
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking dependency style of g++... gcc3
checking whether we are actually using the Intel C++ compiler... no
checking for grep that handles long lines and -e... /bin/grep
checking for fgrep... /bin/grep -F
checking for egrep... /bin/grep -E
checking for a sed that does not truncate output... /bin/sed
checking how to run the C++ preprocessor... g++ -E
checking whether make sets $(MAKE)... (cached) yes
checking whether to compile with debug info... yes
checking whether to compile for profiling... no
checking whether to compile for test coverage... no
checking whether to enable checking of run-time assertions... no
checking whether to enable even more run-time assertions... no
checking whether to enable optimizations... standard
checking for which architecture to optimize... default
checking whether to select specific floating point arithmetics... default
checking whether to use precompiled headers... no
checking the type of integral values to use as coefficients... GMP mpz
checking for an ANSI C-conforming const... yes
checking for inline... inline
checking how to run the C preprocessor... gcc -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking whether byte ordering is bigendian... no
checking for typeof syntax and keyword spelling... typeof
checking size of char... 1
checking size of short... 2
checking size of int... 4
checking size of long... 8
checking size of long long... 8
checking size of size_t... 8
checking size of float... 4
checking size of double... 8
checking size of long double... 16
checking size of int*... 8
checking size of fp... 8
checking for perl... /usr/bin/perl
checking for library containing sqrt... none required
checking fenv.h usability... yes
checking fenv.h presence... yes
checking for fenv.h... yes
checking ieeefp.h usability... no
checking ieeefp.h presence... no
checking for ieeefp.h... no
checking if it is possible to control the FPU... yes
checking whether the C++ compiler provides proper long doubles... yes
checking the binary format of C++ floats... IEEE754 Single Precision
checking whether C++ provides exact output for floats... yes
checking the binary format of C++ doubles... IEEE754 Double Precision
checking whether C++ provides exact output for doubles... yes
checking the binary format of C++ long doubles... Intel Double-Extended
checking whether C++ provides exact output for long doubles... yes
checking whether the C++ compiler supports flexible arrays... yes
checking whether the IEEE inexact flag is supported in C++... yes
checking if the compiler has the remainder bug... yes
checking whether the C++ compiler supports __attribute__ ((weak))... yes
checking for fenv.h... (cached) yes
checking for ieeefp.h... (cached) no
checking getopt.h usability... yes
checking getopt.h presence... yes
checking for getopt.h... yes
checking signal.h usability... yes
checking signal.h presence... yes
checking for signal.h... yes
checking for string.h... (cached) yes
checking for strings.h... (cached) yes
checking sys/resource.h usability... yes
checking sys/resource.h presence... yes
checking for sys/resource.h... yes
checking sys/time.h usability... yes
checking sys/time.h presence... yes
checking for sys/time.h... yes
checking for sys/types.h... (cached) yes
checking for unistd.h... (cached) yes
checking whether ffs is declared... yes
checking whether getenv is declared... yes
checking whether strtof is declared... yes
checking whether strtod is declared... yes
checking whether strtold is declared... yes
checking whether strtoll is declared... yes
checking whether strtoull is declared... yes
checking whether fma is declared... yes
checking whether fmaf is declared... yes
checking whether fmal is declared... yes
checking whether rintf is declared... yes
checking whether rintl is declared... yes
checking for int_fast16_t... yes
checking for int_fast32_t... yes
checking for int_fast64_t... yes
checking for uint_fast16_t... yes
checking for uint_fast32_t... yes
checking for uint_fast64_t... yes
checking for uintptr_t... yes
checking for ld used by GCC... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for shared library run path origin... done
checking how to link with libgmp... -lgmp
checking how to link with libgmpxx... -lgmpxx -lgmp
checking for the GMP library version 4.1.3 or above... no
configure: error: Cannot find GMP version 4.1.3 or higher.
GMP is the GNU Multi-Precision library:
see http://
When compiling the GMP library, do not forget to enable the C++ interface:
add --enable-cxx to the configuration options.
Revision history for this message
![]() |
#26 |
Fortunatelly guys, it finally works thanks to Terry Guo. I read few times his post and realized the problem abput the folder, so I have just added following line before confiiguring ppl (except changing host and build variables as was stated above):
#######
cp -R $BUILDDIR_
#######
and it made my life easier.
Many thanks, and I hope that this will be helpful to the other people.
Nemanja