This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

C++ & GCC / nm / symbols with trailing characters / linker errors


Hi,

I need to port a QT-application from an older development machine
to a production server.

the application consists of several C++ classes for the GUI control
and a set of interface classes that use embedded SQL-procedures,
generated by the oracle (8.1.6) C precompiler.

on the dev. machine I get _trusted_ warnings and I am able to link
an application with QT and embedded SQL.

[dev. machine] with "warning: implicit declaration":

  painter > nm up8set.o | grep OraCommit
  00008bf0 T OraCommit
  painter > nm OracleObjects.o | grep OraCommit
           U OraCommit
  painter > gcc --version
  egcs-2.91.66

on the new server, due to the higher gcc-version, I get errors, when
I wanted to leave external functions undeclared. if I declare these
functions "extern ..." the compiler runs fine, but the linker cannot
find the correct symbols, because the compiler generates postfix
characters for the requested procedures.

[prod. server] with explicit declartion "extern int procname(...);":

  painter > nm up8set.o | grep OraCommit
  000039a0 T OraCommit
  painter > nm OracleObjects.o | grep OraCommit
»          U OraCommit__Fv
»                     ^^^^
  painter > gcc --version
  2.95.2

how can I fix this? is there a known way to tell 'g++' to leave the
requested function identifiers without trailing characters? is there
a way to tell 'g++' to treat implicit declarations simply as a warning?

on the productive machine I cannot step back to an older version,
because it's simply _productive_ :/

any idea? thanks in advance.
 

-- 
mfG / best regards

     Karl Esau

LOEWE Opta GmbH  - Production Data Management
Industriestrasse 11, D-96317 Kronach, Germany
tel   : (+49) 9261 99 731
fax   : (+49) 9261 99 323
eMail : mailto:karl-heinz.esau(AT)loewe.de
visit : http://www.loewe.de


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]