LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 10-11-2010, 06:19 AM   #1
padadhic
LQ Newbie
 
Registered: Oct 2010
Posts: 1

Rep: Reputation: 0
GCC 4.1.2 Issues


Hi

I am very much new to this posts.If this post is not releven here, please let me know what could be relevent thread.

We have a big proprietary project. Our code was compiling very properly with gcc 3.3.4 but not with 4.1.2.

The errors what we get is "ISO forbids declaration" / undefined symbols kind of.

my question is that is there any gcc/g++ compiler switch which can disable checking extra ISO confirmations and stick to our older ISO standards.

in addition to this how we can figure out what ISO standards are supported by which gcc/g++ versions
 
Old 10-11-2010, 08:14 AM   #2
neonsignal
Senior Member
 
Registered: Jan 2005
Location: Melbourne, Australia
Distribution: Debian Bookworm (Fluxbox WM)
Posts: 1,391
Blog Entries: 54

Rep: Reputation: 360Reputation: 360Reputation: 360Reputation: 360
Quote:
Originally Posted by padadhic View Post
We have a big proprietary project. Our code was compiling very properly with gcc 3.3.4 but not with 4.1.2.
The simplest approach (if you don't intend to fix the non-conformant code) is to stick with the older version 3.3 gcc. Many distros still have it in their repositories. Once you install it, you may be able to just set it before building your project (assuming a typical makefile):
Code:
export CC=/usr/bin/gcc-3.3
Quote:
is there any gcc/g++ compiler switch which can disable checking extra ISO confirmations and stick to our older ISO standards.
There are several switches, depending on which ISO standard your code complies to, and depending on whether this is C or C++.

Quote:
how we can figure out what ISO standards are supported by which gcc/g++ versions
This has no simple answer, since standard support in compilers is something that improves over a number of versions. Both of the major standards (ANSI C99 and the ISO C++98 standard) predated version 3.3 of gcc. However, version 3.4 of gcc did significantly improve support for the ISO C++98 standard, and 4.3 onwards is preparing for the upcoming ISO C++0x standard. You would need to refer to the release notes for more detail.

It is likely that some of your errors are not caused because of a newer ISO standard, but because the compiler is better at checking for conformance.

Last edited by neonsignal; 10-11-2010 at 08:17 AM.
 
Old 10-11-2010, 08:44 AM   #3
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
Welcome to LQ.

.... To continue, what's already said by @ neonsignal :

Looks like RH EL5 / CentOS 5.5. Is that, what you are using ?
http://www.catb.org/~esr/faqs/smart-questions.html

If yes, then try # yum install compat-gcc-34-c++
.. to have gcc / g++ version 3.4.6 installed.

Please try with :
export CC=gcc34 CXX=g++34

If it isn't working, please ask for a solution to install
gcc-3.3.6 or gcc-3.3.3.
( Version 3.3.6 are PCLinuxOS packages.
3.3.3 : Can be uploaded to Rapidshare on your request.)
..
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Just stating out, gcc issues kc3 Linux From Scratch 7 02-28-2015 04:06 AM
gcc issues Britten Ubuntu 4 11-27-2005 01:04 PM
GCC/G++ Issues chalewa4bambu Linux - Software 1 11-25-2004 05:07 PM
Are there any issues on updating gcc (-> 3.3.3) hp_tux Slackware 16 03-25-2004 10:36 PM
gcc compatibilty issues h/w Programming 5 11-02-2003 06:22 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 04:21 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration