- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Dear All,
i don't understand nothing about computers,I need help step by step.I have Windows7 64bit on my pc and I
want to arrive to use a Fortran Project (I have Microsoft Visual studio 2008 and Intel Fortran compiler 11.0-061) with FFTW.
What I did is:
1)download fftw-3.2.2-dll64.zip from the web www.fftw.org and extract the files
2)into Visual Studio 2008 x64 Win64 Command Prompt I typed the command :lib /def:libfftw3-3.def and created
libfftw3-3.lib (by default the machine is x64)
3)I put it in the directory Resource Files of my Project Solution Explorer
4)In the Project Properties I put:
the path of my lib in Additional Include Directories under Fortran General
the path of my lib in AdditionalLibrary DirectoriesunderLinker General
the name libfftw3-3.lib in Additional Dependencies in Linker Input
The Debug is under x64 platform.
I didn't added any particular include command at the beginning of my file .for thatI want to build .Inside I use commands like
call dfftw_execute (plan_forward).
If I build,it gives me the error:
error LNK2019:unresolved external symbol DFFTW_EXECUTE
This for all the fftw callings I have in my file .
Is it wrong what I did with the library or the problem is in the commands I used?
What I must do ?
Thanks a lot
i
i don't understand nothing about computers,I need help step by step.I have Windows7 64bit on my pc and I
want to arrive to use a Fortran Project (I have Microsoft Visual studio 2008 and Intel Fortran compiler 11.0-061) with FFTW.
What I did is:
1)download fftw-3.2.2-dll64.zip from the web www.fftw.org and extract the files
2)into Visual Studio 2008 x64 Win64 Command Prompt I typed the command :lib /def:libfftw3-3.def and created
libfftw3-3.lib (by default the machine is x64)
3)I put it in the directory Resource Files of my Project Solution Explorer
4)In the Project Properties I put:
the path of my lib in Additional Include Directories under Fortran General
the path of my lib in AdditionalLibrary DirectoriesunderLinker General
the name libfftw3-3.lib in Additional Dependencies in Linker Input
The Debug is under x64 platform.
I didn't added any particular include command at the beginning of my file .for thatI want to build .Inside I use commands like
call dfftw_execute (plan_forward).
If I build,it gives me the error:
error LNK2019:unresolved external symbol DFFTW_EXECUTE
This for all the fftw callings I have in my file .
Is it wrong what I did with the library or the problem is in the commands I used?
What I must do ?
Thanks a lot
i
Link Copied
5 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The FFTW sources were written in C; to call the FFTW routines from Fortran, you have to match the case and the underscoring added to external routine names. I don't have Win64 handy, but you may try the following, which is what I needed for Win32, at the command line:
ifort /I. /assume:underscore /Qlowercase ex.f90 libfftw3-3.lib
You have to enable the corresponding compiler options in the VS IDE.
ifort /I. /assume:underscore /Qlowercase ex.f90 libfftw3-3.lib
You have to enable the corresponding compiler options in the VS IDE.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks for the cue,that I will try to follow.Unfortunately I 'm rather slow because I'm not used to work from
the command line.Can't I try nothing before remaining inside Microsoft Visual Studio 2008?
the command line.Can't I try nothing before remaining inside Microsoft Visual Studio 2008?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
There are IDE equivalents of command-line options given by mecej4. For example, if you type /assume:underscore in the Ifort MSVS documentation, you will find that it is located in External Procedures > Append Underscore to External Names.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Excellent work guys!Now I see the light.Now the fftw seem to work,but a new problem has born that I didn't have before changes.My program uses,in addition to fftw,also imsl libraries.It is dynamically linked using the
'link_fnl_shared.h' include file precisely.It worked fine previously,but now if I build it gives errors like this:
error LNK2019:unresolved external symbol dcsper_referenced in function MAIN_
How to have both fftw and imsl work in my program?
'link_fnl_shared.h' include file precisely.It worked fine previously,but now if I build it gives errors like this:
error LNK2019:unresolved external symbol dcsper_referenced in function MAIN_
How to have both fftw and imsl work in my program?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Ok, time for me to get on my high horse.
PLEASE DO NOT USE /names or /iface to resolve such issues. They will generally create more problems than they solve. If you are calling C routines with lowercase names, I recommend either:
PLEASE DO NOT USE /names or /iface to resolve such issues. They will generally create more problems than they solve. If you are calling C routines with lowercase names, I recommend either:
- Write an interface block for the C routines with the BIND(C) attribute specified
- Add !DEC$ ATTRIBUTES ALIAS directives for the routines with non-uppercase names

Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page