LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   locating then right libarary GCC compiler (https://www.linuxquestions.org/questions/linux-software-2/locating-then-right-libarary-gcc-compiler-4175467475/)

IneptCoder 06-26-2013 10:25 AM

locating then right libarary GCC compiler
 
Hi,

There is some software that was developed on a fairly new linux (Centos 6.3) and now I am trying to compile it on a older version (Centos 5). I am getting a bunch of new warning messages on the old linux that I wasn't getting on the new one such as the following:

warning: converting from non-pointer type 'char' from NULL

warning: passing NULL to non-pointer argument 4 of...(one of the functions)

I found that the GCC compiler I am using on the older linux is version 4.1.2 while the newer linux is GCC version 4.4.6 could this be the problem for all these new messages?

Also, I am getting an error message that reads:

error: 'sched_getcpu' was not declared in this scope

Again I did not get this error on the newer linux. I think the problem might be that the older linux might not have sched.h file/library installed or maybe its not being properly linked(GCC problem again?) but I do not know how to verify this. (where would I go to see what libraries are included on the computer?)

knudfl 06-26-2013 11:45 AM

May be give it a try with gcc-4.4.x ..
The current version of "gcc-4.4 for CentOS 6.x" is 4.4.7 :

# yum install gcc44-c++

.. providing /usr/bin/ { gcc44, g++44 }

IneptCoder 06-26-2013 12:26 PM

Thanks for the response.
I do not know much about the yum command but the laptop I have to run the software (centos 5) does not have internet connections and I cannot get internet connection on it for security reasons. So I would have to download the gcc-4.4.7 onto a flash drive and then put it on the laptop. Could I install 4.4.7 on Centos 5?
I am looking at the Centos website and it looks like it is possible but I am looking for further information.

knudfl 06-26-2013 12:48 PM

Packages http://mirror.centos.org/centos/5.9/os/ >> i386 or x86_64
>> CentOS/ >>

1) gcc44-4.4.7-1.el5*
2) libstdc++44-devel-4.4.7-1.el5*
3) gcc44-c++-4.4.7-1.el5*
...... Dependencies : (gcc-4.1.2, gcc-c++-4.1.2) libstdc++-4.1.2, gmp,
but I guess you already have those installed.

-

IneptCoder 06-26-2013 01:52 PM

The problem is resolved!
thanks a million Knudfl


All times are GMT -5. The time now is 03:20 AM.