PGI User Forum
 SearchSearch   MemberlistMemberlist     RegisterRegister   ProfileProfile    Log inLog in 

CUDA-x86.

incompatible impicit declararion

 
Post new topic   Reply to topic    PGI User Forum Forum Index -> Programming and Compiling
View previous topic :: View next topic  
Author Message
happyez



Joined: 09 Apr 2010
Posts: 13

PostPosted: Wed Feb 23, 2011 2:32 am    Post subject: incompatible impicit declararion Reply with quote

Hello,

I get the warning message below when compling the WRF/CHEM.
But executable files were maded in the directories.

sym.c:77: incompatible implicit declaration of built-in function 'exit'

what is meaning of the warning messages and how to solved..

Second,

I get the error message when compling the WRF/CHEM.

./compile emi_conv

pgf90 -o convert_emiss.exe -fastsse -Mvect=noaltcode -Msmartalloc
-Mprefetch=distance:8 -Mfprelaxed -w -Mfree -byteswapio

convert_emiss.o ../main/libwrflib.a /home/lim/WRFCHEM/WRFV3/external/fftpack/fftpack5/libfftpack.a
/home/lim/WRFCHEM/WRFV3/external/io_grib1/libio_grib1.a
/home/lim/WRFCHEM/WRFV3/external/io_grib_share/libio_grib_share.a
/home/lim/WRFCHEM/WRFV3/external/io_int/libwrfio_int.a
/home/lim/WRFCHEM/WRFV3/external/esmf_time_f90/libesmf_time.a
/home/lim/WRFCHEM/WRFV3/external/RSL_LITE/librsl_lite.a
/home/lim/WRFCHEM/WRFV3/frame/module_internal_header_util.o
/home/lim/WRFCHEM/WRFV3/frame/pack_utils.o
/home/lim/WRFCHEM/WRFV3/WRFV3/external/io_netcdf/libwrfio_nf.a
-L/opt/lib.pgi/NETCDF4/lib -lnetcdff -lnetcdf


convert_emiss.o: In function `.STATICS1':
convert_emiss.f90:(.data+0x1384): undefined reference to `module_initialize_real_'
make[1]: [convert_emiss] Error 2 (ignored)

Can anyone help me?
Any comment will greatly appreciate.
Thanks..
Back to top
View user's profile
mkcolg



Joined: 30 Jun 2004
Posts: 6146
Location: The Portland Group Inc.

PostPosted: Wed Feb 23, 2011 11:05 am    Post subject: Reply with quote

Hi Happyez,

Quote:
sym.c:77: incompatible implicit declaration of built-in function 'exit'
This warning is coming from GCC. The code needs to include the header file 'stdlib.h' in order to get the definition for the system call to exit. Otherwise GCC thinks you want to use it's builtin (meaning defined internally by the compiler) exit. It probably safe to ignore, but you can add "#include <stdlib.h>" to fix it.

Quote:
convert_emiss.o: In function `.STATICS1':
convert_emiss.f90:(.data+0x1384): undefined reference to `module_initialize_real_'

This means that the linker can't find a symbol that's being used in your program. In this case it's the Initialize Real Module found in "WRFV3/dyn_em/module_initialize_real.F".

When you built WRF, did you build the 'real' case, or one of the idealized cases?

- Mat
Back to top
View user's profile
rf1



Joined: 29 Nov 2010
Posts: 1

PostPosted: Tue Mar 22, 2011 1:54 am    Post subject: Reply with quote

convert_emiss.o: In function `.STATICS1':
convert_emiss.f90:(.data+0x1384): undefined reference to `module_initialize_real_'
make[1]: [convert_emiss] Error 2 (ignored)

I have the same problem when using pgi Version 10.9 (module_initialize_real does definitely exist). But convert_emiss compiles properly when I use version 9.0-1. However, I did not find the reason for this yet.
Back to top
View user's profile
Display posts from previous:   
Post new topic   Reply to topic    PGI User Forum Forum Index -> Programming and Compiling All times are GMT - 7 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © phpBB Group