Reputation: 1
I have downloaded FFTW library and I have followed the installation instruction by typing these commands (http://pblog.ebaker.me.uk/2014/12/installing-fftw-on-os-x-mavericks.html) on the terminal in order to install the FFTW but I got this error.
The commands are:
./configure --enable-float --enable-threads
make
make install
The error is:
./configure
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... configure: error: unsafe absolute working directory name
Any one have a solution for that, please?
Upvotes: 0
Views: 3645
Reputation: 66
This error message states that there is an illegal character in your path (probably one of $, \, #, ", ', `).
In response to one of the comments, it can make sense to build fftw yourself because there are many different choices to make when you build fftw depending on your hardware. Most likely you have AVX2 available on your machine, which was less common on Macs in 2014 when that blog was written. You probably also have multiple cores. To create single, double, and long double libraries use these three code blocks:
./configure CC=/usr/local/bin/gcc-7 --enable-openmp --enable-avx2 --enable-threads --enable-shared --prefix=/usr/local
make
sudo make install
and
./configure CC=/usr/local/bin/gcc-7 --enable-openmp --enable-avx2 --enable-threads --enable-shared --enable-float --prefix=/usr/local
make
sudo make install
and
./configure CC=/usr/local/bin/gcc-7 --enable-openmp --enable-threads --enable-shared --enable-long-double --prefix=/usr/local
make
sudo make install
Of course, /usr/local/bin/gcc-7
should be replaced with the compiler you want to use and /usr/local
should be replaced with the path where you want to install the fftw libraries. If you don't specify the compiler path then the default Apple clang compiler will be used... which currently doesn't play nicely with OpenMP, so you have to use another compiler if you want to use multithreading through OpenMP.
Upvotes: 1