Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Calling IMSL libraries in Intel Visual Fortran ( Visual Studio 2010)

Status
Not open for further replies.

Nitha1978

Programmer
Feb 13, 2013
2
US
Hi,

I am writing a program using Intel Visual Fortran 2011 for MS Project.
I have dll (with source code) which were compiled as 16-bit dll using MS Fortran Power station 4.0.
Now i want re-compile the dll files as 32 & 64 bit dll. I use Intel Visual Fortran 2011 with IMSL libraries 7.0.

When i compile and build the project it says that?

" error LNK2019: unresolved external symbol "

It is because of calling the FFT2D.
Could you Please tell me the way to solution for this problem.


Thanks

Nitha
 
That is probably an external library that was bundled with the package.

Easy way around this, just to see if the routine is needed at all. Someone may have one reference to it but the code might never get executed. Look for where it is getting called and find the parameters. Then add a dummy with those parameters and a print statement indicating that the routine has been called.

Do a run. If you see the print statement, then convert the body of FFT2D
 
Thanks for your reply.

Since i am new to fortran, I am thinking to run samples program to learn intel fortran.
First i started with simple problem. Here is the sample code.

program hello_image

write(*,*) "Hello from image ", this_image(), &
"out of ", num_images()," total images"

end program hello_image

But when i compile and run the code, it gave following errors.

Build Log

Build started: Project: coarray_samples, Configuration: Debug|Win32

Output

Compiling with Intel(R) Visual Fortran Compiler XE 12.0.5.221 [IA-32]...
ifort /nologo /debug:full /debug:parallel /Od /Qcoarray:shared /Qcoarray-num-images:4 /warn:interfaces /module:"Debug\\" /object:"Debug\\" /Fd"Debug\vc100.pdb" /traceback /check:bounds /libs:static /threads /dbglibs /winapp /4Yportlib /Qmkl:parallel /c /Qvc10 /Qlocation,link,"C:\Program Files\Microsoft Visual Studio 10.0\VC\\bin" "D:\Program Files\Intel\ComposerXE-2011\Samples\en_US\Fortran\coarray_samples\coarray_samples\hello_image.f90"
Linking...
Link /OUT:"Debug\coarray_samples.exe" /INCREMENTAL:NO /NOLOGO /MANIFEST /MANIFESTFILE:"D:\Program Files\Intel\ComposerXE-2011\Samples\en_US\Fortran\coarray_samples\coarray_samples\Debug\coarray_samples.exe.intermediate.manifest" /MANIFESTUAC:"level='asInvoker' uiAccess='false'" /DEBUG /PDB:"D:\Program Files\Intel\ComposerXE-2011\Samples\en_US\Fortran\coarray_samples\coarray_samples\Debug\coarray_samples.pdb" /SUBSYSTEM:CONSOLE /IMPLIB:"D:\Program Files\Intel\ComposerXE-2011\Samples\en_US\Fortran\coarray_samples\coarray_samples\Debug\coarray_samples.lib" "Debug\hello_image.obj"
Link: executing 'link'
LIBCMTD.lib(woutputs.obj) : error LNK2019: unresolved external symbol __imp__DecodePointer@4 referenced in function __woutput_s_l
LIBCMTD.lib(woutputp.obj) : error LNK2001: unresolved external symbol __imp__DecodePointer@4
LIBCMTD.lib(purevirt.obj) : error LNK2001: unresolved external symbol __imp__DecodePointer@4
LIBCMTD.lib(crtmboxw.obj) : error LNK2001: unresolved external symbol __imp__DecodePointer@4
LIBCMTD.lib(crtmbox.obj) : error LNK2001: unresolved external symbol __imp__DecodePointer@4
LIBCMTD.lib(outputs.obj) : error LNK2001: unresolved external symbol __imp__DecodePointer@4
LIBCMTD.lib(woutput.obj) : error LNK2001: unresolved external symbol __imp__DecodePointer@4
LIBCMTD.lib(output.obj) : error LNK2001: unresolved external symbol __imp__DecodePointer@4
LIBCMTD.lib(outputp.obj) : error LNK2001: unresolved external symbol __imp__DecodePointer@4
LIBCMTD.lib(input.obj) : error LNK2001: unresolved external symbol __imp__DecodePointer@4
LIBCMTD.lib(inputs.obj) : error LNK2001: unresolved external symbol __imp__DecodePointer@4
LIBCMTD.lib(hooks.obj) : error LNK2001: unresolved external symbol __imp__DecodePointer@4
LIBCMTD.lib(rand_s.obj) : error LNK2001: unresolved external symbol __imp__DecodePointer@4
LIBCMTD.lib(invarg.obj) : error LNK2001: unresolved external symbol __imp__DecodePointer@4
LIBCMTD.lib(handler.obj) : error LNK2001: unresolved external symbol __imp__DecodePointer@4
LIBCMTD.lib(crt0dat.obj) : error LNK2001: unresolved external symbol __imp__DecodePointer@4
LIBCMTD.lib(winsig.obj) : error LNK2001: unresolved external symbol __imp__DecodePointer@4
LIBCMTD.lib(onexit.obj) : error LNK2001: unresolved external symbol __imp__DecodePointer@4
LIBCMTD.lib(tidtable.obj) : error LNK2001: unresolved external symbol __imp__DecodePointer@4
LIBCMTD.lib(crt0.obj) : error LNK2019: unresolved external symbol __imp__HeapSetInformation@16 referenced in function ___tmainCRTStartup
LIBCMTD.lib(crtmboxw.obj) : error LNK2001: unresolved external symbol __imp__EncodePointer@4
LIBCMTD.lib(crtmbox.obj) : error LNK2001: unresolved external symbol __imp__EncodePointer@4
LIBCMTD.lib(purevirt.obj) : error LNK2001: unresolved external symbol __imp__EncodePointer@4
LIBCMTD.lib(hooks.obj) : error LNK2001: unresolved external symbol __imp__EncodePointer@4
LIBCMTD.lib(rand_s.obj) : error LNK2001: unresolved external symbol __imp__EncodePointer@4
LIBCMTD.lib(invarg.obj) : error LNK2001: unresolved external symbol __imp__EncodePointer@4
LIBCMTD.lib(handler.obj) : error LNK2001: unresolved external symbol __imp__EncodePointer@4
LIBCMTD.lib(winsig.obj) : error LNK2019: unresolved external symbol __imp__EncodePointer@4 referenced in function _signal
LIBCMTD.lib(onexit.obj) : error LNK2001: unresolved external symbol __imp__EncodePointer@4
LIBCMTD.lib(cmiscdat.obj) : error LNK2001: unresolved external symbol __imp__EncodePointer@4
LIBCMTD.lib(tidtable.obj) : error LNK2001: unresolved external symbol __imp__EncodePointer@4
LIBCMTD.lib(osfinfo.obj) : error LNK2019: unresolved external symbol __imp__InitializeCriticalSectionAndSpinCount@8 referenced in function __alloc_osfhnd
LIBCMTD.lib(mlock.obj) : error LNK2001: unresolved external symbol __imp__InitializeCriticalSectionAndSpinCount@8
LIBCMTD.lib(ioinit.obj) : error LNK2001: unresolved external symbol __imp__InitializeCriticalSectionAndSpinCount@8
LIBCMTD.lib(stream.obj) : error LNK2001: unresolved external symbol __imp__InitializeCriticalSectionAndSpinCount@8
LIBCMTD.lib(expand.obj) : error LNK2019: unresolved external symbol __imp__HeapQueryInformation@20 referenced in function __is_LFH_enabled
LIBCMTD.lib(cpu_disp.obj) : error LNK2019: unresolved external symbol __imp__IsProcessorFeaturePresent@4 referenced in function ___sse2_available_init
Debug\coarray_samples.exe : fatal error LNK1120: 6 unresolved externals


coarray_samples - 38 error(s), 0 warning(s)


Please anyone give me the solution.

Thanks
 
I don't really know what this_image() and num_images() do. If you want to try something simple, create a new Fortran project. Add a program, something like
Code:
program main
print *, 'It works'
end program
Build and run using visual studio. Now if that works, then do the same with your test program. There is no need to run ifort from the command line unless you really wish to. You can run it from the visual studio ide.
 
@xwb this_image() and num_images() are F2008 instructions for // processing (co-arrays)

François Jacq
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top