NOTE: The netcdf-porting
mailing list is no longer active. The list archives are made available for historical reasons.
"a.rost@xxxxxxxxxxx" <a.rost@xxxxxxxxxxx> writes:
Hi Ed, thanks for replying so fast! The solution you proposed works fine as long as you just need the C-Interface. But I'm looking for a way to build both - the C and the Fortran77 interface in one DLL which didn't work inside the Visual Studio.
It will work from visual studio if you find the correct pre-processor setting for your fortran. The way netCDF supports fortran is by building a bunch of C functions with mangled names, such that when you call the thing from fortran, the name gets mangled in the same way and you get the C function in the DLL. But since every fortran compiler can mangle things in different ways, the netCDF build has to know what fortran compiler you intend to use. You set this as a preprocessor flag in visual studio before building the C library. I forget which pre-processor symbol is currently being used in the visual studio solution file, but if it doesn't work for your fortran compiler, you can try to see flags pgiFortran or f2cFortran and try again. Good luck... Ed -- Ed Hartnett -- ed@xxxxxxxxxxxxxxxx
netcdf-porting
archives: