C++ compiler and linker warnings

C++ compiler and linker warnings

Post by Wolfgang Angenend » Thu, 29 Nov 2001 22:49:33



Hello,

I've installed an actual C++ compiler (V6.3-020) and the actual
DECwindow software (V1.2-6)
on a OpenVMS 7.2-1 system, but when I try to compile a C++ program, I
get
compiler and linker warnings.

A simple C++ example source code is:

#include <stdio.h>
#include <stdlib.h>
#include <Xm/Xm.h>

int main (unsigned int argc, char *argv[], char *envp[])
{
 exit (0);

Quote:}

$ CXX test.cxx

extern XActivateScreenSaver(
......^
%CXX-W-NOSIMPINT, omission of explicit type is nonstandard ("int"
assumed)
at line number 2000 in file SYS$COMMON:[DECW$INCLUDE]XLIB.H;1

extern XAddHost(
......^
%CXX-W-NOSIMPINT, omission of explicit type is nonstandard ("int"
assumed)
at line number 2006 in file SYS$COMMON:[DECW$INCLUDE]XLIB.H;1

extern XAddHosts(
......^
%CXX-W-NOSIMPINT, omission of explicit type is nonstandard ("int"
assumed)
at line number 2013 in file SYS$COMMON:[DECW$INCLUDE]XLIB.H;1

...

$ LINK test.obj
%LINK-W-NUDFSYMS, 1 undefined symbol:
%LINK-I-UDFSYM,         CXXL$V60_MAIN_DISPATCH

On an older OpenVMS system V6.1 the compilation is without warnings.

Can anyone help me?

Thanks
W.Angenendt

  angenendt.vcf
< 1K Download
 
 
 

C++ compiler and linker warnings

Post by Bob Koehl » Thu, 29 Nov 2001 23:40:02



Quote:> #include <stdio.h>
> #include <stdlib.h>
> #include <Xm/Xm.h>

> int main (unsigned int argc, char *argv[], char *envp[])
> {
>  exit (0);
> }

> $ CXX test.cxx

> extern XActivateScreenSaver(
> ......^
> %CXX-W-NOSIMPINT, omission of explicit type is nonstandard ("int"
> assumed)
> at line number 2000 in file SYS$COMMON:[DECW$INCLUDE]XLIB.H;1

   Looks like Xm/Xm.h eventually includes Xlib.h, and Xlib.h is out of
   date (doesn't have the C++ hooks).  For this simple example, you
   don't need stdio.h nor Xm/Xm.h.

Quote:> $ LINK test.obj
> %LINK-W-NUDFSYMS, 1 undefined symbol:
> %LINK-I-UDFSYM,         CXXL$V60_MAIN_DISPATCH

> On an older OpenVMS system V6.1 the compilation is without warnings.

   Use CXXLINK instead of LINK.

 
 
 

C++ compiler and linker warnings

Post by Martin Vorlaend » Fri, 30 Nov 2001 01:58:48



> This is a multi-part message in MIME format.

Please turn off MIME. Thanks you.

Quote:> I've installed an actual C++ compiler (V6.3-020) and the actual
> DECwindow software (V1.2-6) on a OpenVMS 7.2-1 system, but when
> I try to compile a C++ program, I get compiler and linker warnings.

> A simple C++ example source code is:

> #include <stdio.h>
> #include <stdlib.h>
> #include <Xm/Xm.h>

> int main (unsigned int argc, char *argv[], char *envp[])
> {
>  exit (0);
> }

> $ CXX test.cxx

> extern XActivateScreenSaver(
> ......^
> %CXX-W-NOSIMPINT, omission of explicit type is nonstandard ("int"
> assumed)
> at line number 2000 in file SYS$COMMON:[DECW$INCLUDE]XLIB.H;1

...

Either modify the X include files (bad idea), or use
  $ CXX /WARNINGS=(DISABLE=(NOSIMPINT)) test.cxx

cu,
  Martin
--
                       |  Martin Vorlaender  |  VMS & WNT programmer

  KNOW where you want  |     http://www.pdv-systeme.de/users/martinv/

 
 
 

1. Linker-Warnings in VMS 7.3

Hello to all OpenVMS-Friends!

After we had upgraded from OpenVMS V7.1-1H1 to V7.3 on a Test-Alphaserver we had
compiled our applications without any errors! But now (after successful
compilation) we get link-warnings with unresolved message-numbers:
%LINK-W-NOMSG, Message number 0064A120
%LINK-W-NOMSG, Message number 0064A128
%LINK-W-NOMSG, Message number 0064A130
%LINK-W-NOMSG, Message number 0064A128

Before above upgrade no link-warnings occured!

An analyze/image of link.exe shows:
        Image Identification Information

                image name: "LINK"
                image file identification: "A12-03"
                image file build identification: "X913-0060000000"
                link date/time: 22-MAR-2001 12:52:30.00
                linker identification: "A11-50"

Does anybody have an idea or a hint?

greetings
martin eismann,
cretschmar logistik gmbh
duesseldorf, germany

2. How old is the IRIS 3130?

3. checking binaries for linker warnings?

4. Can I delete selected System/Mail?

5. Linker MULDEF warning

6. Solution Architect - Pre/Post Sales - SaaS - Java/J2EE/SOA/Portals - N. 128 Area of MA - Up to $130K+

7. PNG better than gif....

8. alternate compiler/linker options in a descrip.mms

9. C++ V6.5 linker performance optimization?

10. Linker problems with C++ subroutines

11. Linker problems with C++ subroutines (correction of description)