简体   繁体   中英

Linux issue happens on Windows? "fatal error: fftw3.h: No such file or directory"

I am running MRO 3.5.0 on Win10, and trying to install a package image.CannyImage from bnosac/image on the github. But it keeps reporting fatal errors as following.

* installing *source* package 'image.CannyEdges' ...
** libs
c:/Rtools/mingw_64/bin/g++ -m64 -I"C:/PROGRA~1/MICROS~1/ROPEN~1/R-35~1.0/include" -DNDEBUG  -I"C:/Users/eric1/Documents/R/win-library/3.5/Rcpp/include"   -I"C:/swarm/workspace/External-R-3.5.0/vendor/extsoft/include"     -O2 -Wall  -mtune=core2 -c RcppExports.cpp -o RcppExports.o
c:/Rtools/mingw_64/bin/gcc -m64 -I"C:/PROGRA~1/MICROS~1/ROPEN~1/R-35~1.0/include" -DNDEBUG  -I"C:/Users/eric1/Documents/R/win-library/3.5/Rcpp/include"   -I"C:/swarm/workspace/External-R-3.5.0/vendor/extsoft/include"     -O2 -Wall  -std=gnu99 -mtune=core2 -c adsf.c -o adsf.o
c:/Rtools/mingw_64/bin/g++ -m64 -I"C:/PROGRA~1/MICROS~1/ROPEN~1/R-35~1.0/include" -DNDEBUG  -I"C:/Users/eric1/Documents/R/win-library/3.5/Rcpp/include"   -I"C:/swarm/workspace/External-R-3.5.0/vendor/extsoft/include"     -O2 -Wall  -mtune=core2 -c rcpp_canny.cpp -o rcpp_canny.o
In file included from rcpp_canny.cpp:13:0:
canny.h:8:19: fatal error: fftw3.h: No such file or directory
 #include <fftw3.h>
                   ^
compilation terminated.
make: *** [C:/PROGRA~1/MICROS~1/ROPEN~1/R-35~1.0/etc/x64/Makeconf:215: rcpp_canny.o] Error 1
ERROR: compilation failed for package 'image.CannyEdges'
* removing 'C:/Users/eric1/Documents/R/win-library/3.5/image.CannyEdges'
In R CMD INSTALL
Installation failed: Command failed (1)

                   ^
compilation terminated.

在此处输入图片说明

Google says I can solve the issue by sudo apt-get remove libfftw3-dev . Unfortunately, I am on Windows, and some advised, apply lib /machine:i386 /def:libfftw3-3.def on cmd mode. Ouch, there is no such command or file called lib.exe on Win10. Please advise, how I can solve this issue on my Win10+MRO system. Thanks.

Even though this question is already a bit old: By now (Feb 2020) there are precompiled packages available that work also under Windows:

Canny Edges - Package

and more general:

List of all available packages

I have tried installing them and (at least for me) it worked.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM