OMNeT++/OMNEST Bug Tracker - OMNeT++
View Issue Details
0000099OMNeT++simulation kernelpublic2009-08-31 01:232010-04-01 11:38
0000099: OMNet 4.0 does not compile under Fedora 11 (GCC 4.4.1)
Just downloaded the latest OMNet 4.0 on my linux box. It's Fedora 11 which includes GCC 4.4.1. GCC has been tightening up the screws a bit on compiling code and has found a number of issues with the OMNet code. All the problems discovered pertain to including the proper header files for things like "fopen()" and many of the old-style "C" functions. Here is the fix for Fedora 11.

In the following files (all .cc), add an extra "#include <cstdio>" at the beginning of the code:

For the file "messagedependency.h" add "#include <stdio.h>". Note: this is the only header file that needs modification.

As it currently stands OMNet appears to be literated with a mixture of C and C++ code. At some point, OMNet could use a scrubbing and removal of old "C" code functions and move it to a purely C++ codebase. Maybe I can help?

Anyway, good code, looking forward to using it!

No tags attached.
Issue History
2009-08-31 01:23dhodsonNew Issue
2009-10-09 15:24rhornigNote Added: 0000180
2009-10-09 15:24rhornigStatusnew => to be tested
2009-12-04 11:03aranelNote Added: 0000195
2010-04-01 11:38rhornigNote Added: 0000226
2010-04-01 11:38rhornigStatusto be tested => resolved
2010-04-01 11:38rhornigFixed in Version => 4.1b1
2010-04-01 11:38rhornigResolutionopen => fixed
2010-04-01 11:38rhornigAssigned To => rhornig

2009-10-09 15:24   
Fixed in commit a4a15db on the master branch.
2009-12-04 11:03   
It can be easily fixed by adding #include <cstdio> to src/common/commonutils.h which is included into all related files.
2010-04-01 11:38   
Added the missing headers.