--- yambo-3.2.1-r.448/configure.orig	2009-07-07 13:58:52.000000000 +0200
+++ yambo-3.2.1-r.448/configure	2013-01-17 11:06:06.164402000 +0100
@@ -11639,7 +11639,7 @@
 fi;
 echo "$as_me:$LINENO: checking for FFTW" >&5
 echo $ECHO_N "checking for FFTW... $ECHO_C" >&6
-FFTW_LIBS="-lfftw3"
+FFTW_LIBS=${FFTW_LIBS:-"-lfftw3"}
 FFTW_PATH=""
 case $with_fftw in
   no )
@@ -11683,7 +11683,7 @@
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
   HAVE_FFTW="yes"; FFT_CPP="-D_FFTW";
- FFT_DESCRIPTION="FFTW Fast Fourier transform";LDFLAGS="$FFTW_PATH"
+ FFT_DESCRIPTION="FFTW Fast Fourier transform";LDFLAGS+=" $FFTW_PATH"
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
