admin ·¢±íÓÚ 2013-4-17 13:41:55

[Tech Memo]FFTW and fatal error LNK1104 in Win7

Topic:
How to solve the problem of' fatal error LNK1104 ' when you are generating .lib and .obj files of FFTW in Win7 using following commands.
lib /machine:i386 /def:libfftw3-3.def
lib /machine:i386 /def:libfftw3f-3.def
lib /machine:i386 /def:libfftw3l-3.def

Annoucement:
The inspiration of solving this problem is from http://liuxingguang.blogspot.jp/2012/05/use-fftw-in-c.html byLior Ella.
¡ª¡ª¡ªOriginal¡ª¡ª¡ª
Lior Ella said...Hi Antonio and Xingguang,

I ran into the same problem as Antonio, and after messing around with it for about an hour I figured it out. The problem was that I tried to create the *.lib files in the visual studio directory itself. Because admin privileges are required to add files to that directory, it failed.

The solution is to run lib.exe through the visual studio command prompt, but to do it in a "neutral" directory, where the *.def files are found. This will work.

Thanks a lot!
Dec 26, 2012, 5:03:00 AM¡ª¡ª¡ªOriginal¡ª¡ª¡ª

Problem Discription:
When you are using lib.exe in visual studio to generate corresponding .lib and .obj files,the error is shown as follows.
LINK: fatal error LNK1104: file 'libfftw3-3.lib' can not be opened.

Detailed FFTW configuration introduction:
(English) http://liuxingguang.blogspot.jp/2012/05/use-fftw-in-c.html
(Chinese)WindowsÏÂFFTW¿âµÄ°²×°ÅäÖÃ
http://ruanyuan.net/forum.php?mod=viewthread&tid=2814&fromuid=1

Solution:
As Lior Ella said, the reason for this error is 'Win7 admin privilege'. However, neither Libaray Manager nor Win7 gives the CORRECT debug info. It is easy to be confused here.

To solve this problem is easy, just COPY the files in /Program Files/MicrosoftVisual Studio 9.0/VC/bin to a ¡¯Neutual¡¯ path, i.e. D:/. Then execute the lib commandagainand theLNK1104 error is gone :)

Anyway, this issue is DISGUSTING:(

RuanYuan.Net@admin
2013.4.17



ÑÖħ¤¢¤¤ ·¢±íÓÚ 2013-4-17 23:17:48

ÓÖÊÇÓ¢Óï¡£¡£¡£¡£±ÉÊÓÓ¢Ó£¡£¡£¡£¡{:5_137:}

admin ·¢±íÓÚ 2013-4-18 08:20:05

ÑÖħ¤¢¤¤ ·¢±íÓÚ 2013-4-17 23:17 static/image/common/back.gif
ÓÖÊÇÓ¢Óï¡£¡£¡£¡£±ÉÊÓÓ¢Ó£¡£¡£¡£¡

Try to fall in love with English, you may benefit from it{:6_204:}

ÑÖħ¤¢¤¤ ·¢±íÓÚ 2013-4-19 17:15:47

admin ·¢±íÓÚ 2013-4-18 08:20 static/image/common/back.gif
Try to fall in love with English, you may benefit from it

I¡®m sorry............I can't.................

admin ·¢±íÓÚ 2013-4-19 22:19:58

ÑÖħ¤¢¤¤ ·¢±íÓÚ 2013-4-19 17:15 static/image/common/back.gif
I¡®m sorry............I can't.................

Ma...... Forget it....

ÑÖħ¤¢¤¤ ·¢±íÓÚ 2013-4-19 23:18:20

admin ·¢±íÓÚ 2013-4-19 22:19 static/image/common/back.gif
Ma...... Forget it....

Thank you for your forgive.......
Ò³: [1]
²é¿´ÍêÕû°æ±¾: [Tech Memo]FFTW and fatal error LNK1104 in Win7