[R-pkg-devel] fftw linking

Denis Rastegaev leda82 at gmail.com
Sun Feb 4 13:38:25 CET 2018


Hello everyone!
I try to upload my package on CRAN but the package
does not pass the incoming checks. How to link external
compiler with fftw? My package on github:
https://github.com/drastega/specklestar

Installation log:

* installing *source* package 'specklestar' ...
** libs

*** arch - i386
d:/Compiler/gcc-4.9.3/mingw_32/bin/g++
-I"D:/RCompile/recent/R/include" -DNDEBUG
-I"d:/RCompile/CRANpkg/lib/3.5/Rcpp/include"
-I"d:/Compiler/gcc-4.9.3/local330/include"     -pedantic -O2 -Wall
-mtune=core2 -c RcppExports.cpp -o RcppExports.o
d:/Compiler/gcc-4.9.3/mingw_32/bin/g++
-I"D:/RCompile/recent/R/include" -DNDEBUG
-I"d:/RCompile/CRANpkg/lib/3.5/Rcpp/include"
-I"d:/Compiler/gcc-4.9.3/local330/include"     -pedantic -O2 -Wall
-mtune=core2 -c image_helper.cpp -o image_helper.o
d:/Compiler/gcc-4.9.3/mingw_32/bin/g++
-I"D:/RCompile/recent/R/include" -DNDEBUG
-I"d:/RCompile/CRANpkg/lib/3.5/Rcpp/include"
-I"d:/Compiler/gcc-4.9.3/local330/include"     -pedantic -O2 -Wall
-mtune=core2 -c middle_frame.cpp -o middle_frame.o
d:/Compiler/gcc-4.9.3/mingw_32/bin/g++
-I"D:/RCompile/recent/R/include" -DNDEBUG
-I"d:/RCompile/CRANpkg/lib/3.5/Rcpp/include"
-I"d:/Compiler/gcc-4.9.3/local330/include"     -pedantic -O2 -Wall
-mtune=core2 -c ps.cpp -o ps.o
d:/Compiler/gcc-4.9.3/mingw_32/bin/g++
-I"D:/RCompile/recent/R/include" -DNDEBUG
-I"d:/RCompile/CRANpkg/lib/3.5/Rcpp/include"
-I"d:/Compiler/gcc-4.9.3/local330/include"     -pedantic -O2 -Wall
-mtune=core2 -c ps_diff.cpp -o ps_diff.o
d:/Compiler/gcc-4.9.3/mingw_32/bin/g++
-I"D:/RCompile/recent/R/include" -DNDEBUG
-I"d:/RCompile/CRANpkg/lib/3.5/Rcpp/include"
-I"d:/Compiler/gcc-4.9.3/local330/include"     -pedantic -O2 -Wall
-mtune=core2 -c speckle_acf.cpp -o speckle_acf.o
d:/Compiler/gcc-4.9.3/mingw_32/bin/g++
-I"D:/RCompile/recent/R/include" -DNDEBUG
-I"d:/RCompile/CRANpkg/lib/3.5/Rcpp/include"
-I"d:/Compiler/gcc-4.9.3/local330/include"     -pedantic -O2 -Wall
-mtune=core2 -c speckle_generator.cpp -o speckle_generator.o
d:/Compiler/gcc-4.9.3/mingw_32/bin/g++
-I"D:/RCompile/recent/R/include" -DNDEBUG
-I"d:/RCompile/CRANpkg/lib/3.5/Rcpp/include"
-I"d:/Compiler/gcc-4.9.3/local330/include"     -pedantic -O2 -Wall
-mtune=core2 -c speckle_stat.cpp -o speckle_stat.o
d:/Compiler/gcc-4.9.3/mingw_32/bin/g++ -shared -s -static-libgcc -o
specklestar.dll tmp.def RcppExports.o image_helper.o middle_frame.o
ps.o ps_diff.o speckle_acf.o speckle_generator.o speckle_stat.o
-Ld:/Compiler/gcc-4.9.3/local330/lib/i386
-Ld:/Compiler/gcc-4.9.3/local330/lib -LD:/RCompile/recent/R/bin/i386
-lR
ps.o:ps.cpp:(.text+0x669): undefined reference to `fftw_malloc'
ps.o:ps.cpp:(.text+0x77d): undefined reference to `fftw_plan_dft_r2c_2d'
ps.o:ps.cpp:(.text+0x787): undefined reference to `fftw_execute'
ps.o:ps.cpp:(.text+0x78f): undefined reference to `fftw_destroy_plan'
ps.o:ps.cpp:(.text+0x7de): undefined reference to `fftw_free'
ps_diff.o:ps_diff.cpp:(.text+0x699): undefined reference to `fftw_malloc'
ps_diff.o:ps_diff.cpp:(.text+0xd27): undefined reference to
`fftw_plan_dft_r2c_2d'
ps_diff.o:ps_diff.cpp:(.text+0xd31): undefined reference to `fftw_execute'
ps_diff.o:ps_diff.cpp:(.text+0xd39): undefined reference to `fftw_destroy_plan'
ps_diff.o:ps_diff.cpp:(.text+0xda0): undefined reference to `fftw_free'
speckle_acf.o:speckle_acf.cpp:(.text+0x323): undefined reference to
`fftw_malloc'
speckle_acf.o:speckle_acf.cpp:(.text+0x349): undefined reference to
`fftw_plan_dft_c2r_2d'
speckle_acf.o:speckle_acf.cpp:(.text+0x354): undefined reference to
`fftw_execute'
speckle_acf.o:speckle_acf.cpp:(.text+0x35f): undefined reference to
`fftw_destroy_plan'
speckle_acf.o:speckle_acf.cpp:(.text+0x384): undefined reference to `fftw_free'
collect2.exe: error: ld returned 1 exit status
no DLL was created
ERROR: compilation failed for package 'specklestar'
* removing 'd:/RCompile/CRANincoming/R-devel/lib/specklestar'
In R CMD INSTALL

	[[alternative HTML version deleted]]



More information about the R-package-devel mailing list