Review your favorite Linux distribution.
Go Back > Forums > Linux Forums > Linux - Software
User Name
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.


  Search this Thread
Old 01-07-2007, 06:04 PM   #1
Registered: Aug 2006
Location: Oregon
Distribution: Ubuntu 9.04, Windows 7
Posts: 48

Rep: Reputation: 16
OpenGL program compile error with gcc 4.1.1 and Mesa 6.5.2

Hello evr1,

I have only spent probably 4 weeks in the area of C++ programming over the span of about 3 months, so bare with me here.

Recently I bought Running Linux, 5 edition and in the section on C/C++ programming, they had an OpenGL example. So I fired up Kdevelop and typed the example in line by line.

After debug silly syntax error like forgetting ';' at the end of the line (a habit of my old QBASIC 4.5 days , I came across the following errors that I am unfamiliar with:

rl.cpp:81:2: warning: no newline at end of file
rl.cpp: In function ‘int main(int, char**)’:
rl.cpp:75: error: expected primary-expression before ‘)’ token
I am running Fedora Core 6 with Mesa 6.5.2 and gcc 4.1 that I think is version 4.1.1 (it is the stock FC6 version). I've read that gcc 4.x is quite strict and that I should switch to 3.4.x or 3.5.x.

Old 01-07-2007, 06:25 PM   #2
Senior Member
Registered: Sep 2005
Location: France
Distribution: approximately NixOS (
Posts: 1,900

Rep: Reputation: 68
You have little chance to get exact answer until you post code. Probably all of it, but put an additional comment on line 75 (just /*line 75*/ will do).


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Cannot compile OpenGL program because libGL.a is missing lasindi Slackware 4 04-12-2009 05:09 PM
How to compile C program using the OSSP mm library and gcc? seleria Linux - Software 0 11-06-2006 04:08 AM
Can't compile c++ program using gcc pengu Programming 9 02-22-2006 02:59 PM
Overwrite Mesa OpenGL with ATI OpenGL Carl-Fredrik Slackware 12 10-01-2004 04:33 PM
Changing from MESA OpenGL to ATI OpenGL tillyoubreakit Linux - Hardware 19 10-07-2003 08:32 PM > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 05:32 AM.

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