[CMake] fftw-3.2.2 linking porblems to CMake 2.6

Ryan Pavlik rpavlik at iastate.edu
Wed Jan 6 09:57:03 EST 2010


You should be able to do something like:

find_library(FFTW_LIBRARY
     NAMES fftw3 fftw)
set(FFTW_LIBRARIES "${FFTW_LIBRARY}")
if(UNIX AND NOT WIN32)
     find_library(FFTW_libm_LIBRARY
         NAMES m)
     list(APPEND FFTW_LIBRARIES "${FFTW_libm_LIBRARY}")
endif()

target_link_libraries(yourtargetname ${FFTW_LIBRARIES})

Ryan


On 01/06/2010 05:33 AM, Lucian Goron wrote:
> hello,
>
> I use the ubuntu 9.04 jaunty jackalope along with other open source 
> C++ libraries.
> Recently I discovered the/ fftw-3.2.2/ libraries, but trying linking 
> it is harder then I thought.
> Basically, I have to link these libraries /-lfftw3 -lm /but I do not 
> know how ?
>
> Has somebody encountered this problem before ? /
> /
> Thank you in advance./
> /
>
>
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.cmake.org/mailman/listinfo/cmake

-- 
Ryan Pavlik
HCI Graduate Student
Virtual Reality Applications Center
Iowa State University

rpavlik at iastate.edu
http://academic.cleardefinition.com
Internal VRAC/HCI Site: http://tinyurl.com/rpavlik

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20100106/b6e534bb/attachment.htm>


More information about the CMake mailing list