Bug 77929 - Sources: kdevelop/cproject.cpp isn't ANSI compatible
Sources: kdevelop/cproject.cpp isn't ANSI compatible
Status: CLOSED CANTFIX
Product: Red Hat Linux
Classification: Retired
Component: kdevelop (Show other bugs)
7.3
i386 Linux
medium Severity low
: ---
: ---
Assigned To: Petr Rockai
Ben Levenson
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2002-11-15 10:27 EST by Sysoltsev Slawa
Modified: 2007-04-18 12:48 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2006-10-18 14:22:09 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Sysoltsev Slawa 2002-11-15 10:27:02 EST
From Bugzilla Helper:
User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)

Description of problem:
Compiling kdevelop by Intel C/C++ compiler I received such error:
c++ -DHAVE_CONFIG_H -I. -I. -I.. -I../kdevelop/widgets/qextmdi/include -
I../kdevelop/ctags -I../kdevelop/kpp -I../kdevelop/kpp -I../kdevelop/kwrite -
I/usr/include/kde -I/usr/lib/qt3-gcc2.96/include -I/usr/X11R6/include   -
DQT_THREAD_SUPPORT  -D_REENTRANT  -Wnon-virtual-dtor -Wno-long-long -Wbad-
function-cast -Wundef -Wall -pedantic -W -Wpointer-arith -Wmissing-prototypes -
Wwrite-strings -ansi -D_XOPEN_SOURCE=500 -D_BSD_SOURCE -Wcast-align -
Wconversion -fno-builtin -g -O2 -O2 -march=i386 -mcpu=i686 -DNDEBUG -DNO_DEBUG -
D_GNU_SOURCE -fno-exceptions -fno-check-new -ftemplate-depth-99  -c cproject.cpp
...
cproject.cpp(1932): error #11: unrecognized preprocessing directive
  #warning fixme: toplevel makefile detection when using VPATH RalfN
   ^

Problem here is that when "-ansi -pedantic" is specified in command line, 
compiler must perform strict ANSI check. According to ANSI standart code in 
cproject.cpp is illegal because #warning directive isn't described in ANSI C++ 
(look at section 16 - Preprocessing directives) therefore you cannot use it in 
strict ANSI dialect code.
GNU C/C++ doesn't do STRICT ANSI check so illegal code passes succesfully 
through it. But to increase Red Hat Linux portability you should synchronize 
code written and "-ansi -pedantic" cmd-line options usage. "#warning" directive 
in cproject.cpp should be changed to #error or removed or you should stop 
using "-ansi -pedantic" in command line if your code isn't ANSI compatible.

Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
1. I'm afraid you won't be able to reproduce the error because you don't have 
compiler I used.

	

Actual Results:  Compilation error.

Expected Results:  Built package.

Additional info:
Comment 1 Petr Rockai 2006-07-17 14:21:31 EDT
This bug is reported against old release of Red Hat Linux or Fedora Core 
that is no longer supported. Chances are that it has been already fixed in 
newer Fedora Core release. If you still experience the problem with 
current release of Fedora Core, please update the Version field (you may 
need to switch Product to Fedora Core first) in the bug report and put it 
back to NEW state.
Comment 2 Bill Nottingham 2006-10-18 14:22:09 EDT
Red Hat Linux is no longer supported by Red Hat, Inc. If you are still
running Red Hat Linux, you are strongly advised to upgrade to a
current Fedora Core release or Red Hat Enterprise Linux or comparable.
Some information on which option may be right for you is available at
http://www.redhat.com/rhel/migrate/redhatlinux/.

Red Hat apologizes that these issues have not been resolved yet. We do
want to make sure that no important bugs slip through the cracks.
If this issue is still present in a current Fedora Core release, please
open a new bug with the relevant information.

Closing as CANTFIX.

Note You need to log in before you can comment on or make changes to this bug.