libmpsse
libmpsse copied to clipboard
fix: examples build Makefile
Build examples with libftdi1, for disable - change in Makefile LIBFTDI1=1 to LIBFTDI1=0
Are you sure the examples need such a flag for building?
os: CentOS 7
uname -a: Linux 3.10.0-862.11.6.el7.x86_64 #1 SMP Tue Aug 14 21:49:04 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
$ gcc --version
gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-28)
i'am build libftdi1, and never install libftdi2xx (official src). Without fix have errors: for lib:
gcc -Wall -fPIC -fno-strict-aliasing -g -O2 -lftdi1 -DLIBFTDI1=1 -c support.c
gcc -Wall -fPIC -fno-strict-aliasing -g -O2 -lftdi1 -DLIBFTDI1=1 -c mpsse.c
gcc -Wall -fPIC -fno-strict-aliasing -g -O2 -lftdi1 -c fast.c
In file included from fast.c:10:0:
mpsse.h:9:18: fatal error: ftdi.h: No such file or directory
#include <ftdi.h>
^
compilation terminated.
make: *** [fast.o] Error 1
and for examples:
$ make example-code
make -C examples
make[1]: Entering directory `/..../libmpsse/src/examples'
cc spiflash.c -o spiflash -lmpsse
In file included from spiflash.c:3:0:
/usr/local/include/mpsse.h:9:18: fatal error: ftdi.h: No such file or directory
#include <ftdi.h>
^
compilation terminated.
make[1]: *** [spiflash] Error 1
make[1]: Leaving directory `/.../libmpsse_my/src/examples'
make: *** [example-code] Error 2
Okay, thanks, should be fixed in my repo.