libftdi Archives

Subject: libftdi 0.17 broken on cygwin

From: Thomas Kindler <mail+ocd@xxxxxxxxxxxx>
To: libftdi@xxxxxxxxxxxxxxxxxxxxxxx
Date: Thu, 14 Jan 2010 19:47:07 +0100
Hi!

I'm trying to compile libftdi (from git) on cygwin. This is what happens when trying to compile with cmake:

tkindler@pc-kindler ~/libftdi
$ cmake .
-- The C compiler identification is GNU
-- The CXX compiler identification is GNU
-- Check for working C compiler: /usr/bin/gcc.exe
-- Check for working C compiler: /usr/bin/gcc.exe -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++.exe
-- Check for working CXX compiler: /usr/bin/c++.exe -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Build type: Debug
-- Found LIBUSB: /lib/libusb.dll.a
CMake Error at src/CMakeLists.txt:29 (install):
  install Library TARGETS given no DESTINATION!


-- Boost version: 1.33.1
-- Found the following Boost libraries:
-- Building libftdi++
CMake Error at ftdipp/CMakeLists.txt:40 (install):
  install Library TARGETS given no DESTINATION!


-- Found PythonLibs: /lib/python2.5/config/libpython2.5.dll.a
-- Building python bindings via swig. Will be installed under
/lib/python2.5/site-packages
-- Building libftdi++ examples.
-- Found Doxygen: /cygdrive/c/Programme/doxygen/bin/doxygen.exe
-- Doxygen found.
-- Configuring incomplete, errors occurred!


According to some mailing list posting:

  http://www.cmake.org/pipermail/cmake/2008-September/023876.html

I single-handedly fixed this by adding

  ARCHIVE DESTINATION lib${LIB_SUFFIX}

to  src/CMakeLists.txt     (for the ftdi target)
and ftdipp/CMakeLists.txt  (for the ftdipp target)

(Much later, I discovered, that the libftdi-tarball still contains the good, old autoconf-scripts which I could have used instead.. grr!)




But it still won't build:

$ make
[...]
-- Building libftdi++
-- Building python bindings via swig. Will be installed under /lib/python2.5/sit
e-packages
-- Building libftdi++ examples.
-- Doxygen found.
-- Configuring done
-- Generating done
-- Build files have been written to: /home/tkindler/libftdi
[  5%] Built target ftdi
[ 11%] Building CXX object ftdipp/CMakeFiles/ftdipp.dir/ftdi.cpp.o
In file included from /home/tkindler/libftdi/ftdipp/ftdi.cpp:29:
/home/tkindler/libftdi/ftdipp/ftdi.hpp:34:32: error: boost/shared_ptr.hpp: No su
ch file or directory
In file included from /home/tkindler/libftdi/ftdipp/ftdi.cpp:29:
/home/tkindler/libftdi/ftdipp/ftdi.hpp:144: error: 'boost' has not been declared

/home/tkindler/libftdi/ftdipp/ftdi.hpp:144: error: ISO C++ forbids declaration o
f 'shared_ptr' with no type
/home/tkindler/libftdi/ftdipp/ftdi.hpp:144: error: expected ';' before '<' token

/home/tkindler/libftdi/ftdipp/ftdi.hpp:169: error: 'boost' has not been declared

/home/tkindler/libftdi/ftdipp/ftdi.hpp:169: error: ISO C++ forbids declaration o
f 'shared_ptr' with no type

[...]

(cygwin packages for boost, boost-devel & libboost 1.33.1-4 _are_ installed of course..)



So, I disabled the cpp library (which I don't need anyways) by commenting out the respective lines in CMakeLists.txt.

Is there a better way?! The old ./configure had a --disable-ftdipp option or similar.


Next problem:

-- Build type: Debug
-- Building python bindings via swig. Will be installed under /lib/python2.5/site-packages
-- Doxygen found.
-- Configuring done
-- Generating done
-- Build files have been written to: /home/tkindler/libftdi
[  7%] Built target ftdi
[  7%] Generating doc
[  7%] Generating doc/html/index.html
Error: configuration file /home/tkindler/libftdi/doxy.config not found!


This was easily explained -- I had doxygen installed natively on Windows, and it didn't like the forward-slashes. Same thing again: How do I tell cmake to not build the documentation?! Uninstalling doxygen, and re-installing cygwin's doxygen solved it.



Next one:

[ 28%] Built target ftdi-static
[ 35%] Swig source
Scanning dependencies of target _ftdi
[ 42%] Building C object bindings/CMakeFiles/_ftdi.dir/ftdiPYTHON_wrap.c.o
/home/tkindler/libftdi/bindings/ftdiPYTHON_wrap.c: In function '_wrap_ftdi_enabl
e_bitbang':
/home/tkindler/libftdi/bindings/ftdiPYTHON_wrap.c:6286: warning: 'ftdi_enable_bi tbang' is deprecated (declared at /home/tkindler/libftdi/bindings/../src/ftdi.h:
331)
Linking C shared module _ftdi.dll
CMakeFiles/_ftdi.dir/ftdiPYTHON_wrap.c.o: In function `_wrap_ftdi_init':
/home/tkindler/libftdi/bindings/ftdiPYTHON_wrap.c:5258: undefined reference to `
_ftdi_init'
CMakeFiles/_ftdi.dir/ftdiPYTHON_wrap.c.o: In function `_wrap_ftdi_new':
/home/tkindler/libftdi/bindings/ftdiPYTHON_wrap.c:5271: undefined reference to `
_ftdi_new'



Gaaahrgh!!

I'm giving up. I fiddled for a day with this thing, and still no success. There are no binaries for windows, and the build process is not documented anywhere. How is this supposed to work?


Best regards,
--
Thomas Kindler <mail@xxxxxxxxxxxx>

--
libftdi - see http://www.intra2net.com/en/developer/libftdi for details.
To unsubscribe send a mail to libftdi+unsubscribe@xxxxxxxxxxxxxxxxxxxxxxx
Current Thread