git clone https://github.com/matrix-io/xc3sprog.git cd xc3sprog mkdir build cmake ..Cmake warns about all kinds of things. Most of those warnings are things the developers should be worrying about and taking care of. Those warnings can be suppressed via -Wno-dev Once that switch is added, we see the show stopper errors:
cmake -Wno-dev .. -- Checking for module 'libftdi' -- Package 'libftdi', required by 'virtual:world', not found -- Could NOT find LIBFTDI (missing: LIBFTDI_LIBRARIES LIBFTDI_INCLUDE_DIR) -- Checking for module 'libftd2xx' -- Package 'libftd2xx', required by 'virtual:world', not found -- Could NOT find LIBFTD2XX (missing: LIBFTD2XX_INCLUDE_DIR) -- Configuring doneNow this is odd, because I did install the Fedora packages via:
dnf install libftdi-devel dnf install libftdi-c++-develUsing locate to look for ftdi.h, we see:
/usr/include/libftdi1/ftdi.hThat does seem like an obscure location for this important file. I'll just note in passing that on Ubuntu, xc3sprog is simply available via apt-get as a standard package.
The trick now is understanding cmake sufficiently to clue it in to the bizarre location of the include file on my Fedora system.
Sniffing around a bit, I find out that ftdi.h is provided by libftdi-devel-1.5-2.fc35.x86_64 Given the package name, I find out that it also provides /usr/lib64/libftdi1.so
So heaven only knows why we have ftdi1 rather than ftdi. As much as I am tempted to make links in /usr/include and /usr/lib64, I resist that temptation and focus on the cmake files that come with xc3sprog. The file to attack seems to be:
Findlibftdi.cmakeI will also note, for the record, that my Fedora system has a directory /usr/lib64/cmake/libftdi1 that has some unknown jive related to cmake.
My hacking on the Findlibftdi.cmake file works (at least cmake runs cleanly now), but when I type make I get:
wiringPi.h: No such file or directoryIn the file CMakeLists.txt I find the line:
option(USE_WIRINGPI "Use WiringPi" ON)I change this to OFF and try again.
I get brave and type "make install". I need to make /usr/local/bin writeable by tom, then:
-- Install configuration: "" -- Installing: /usr/local/bin/xc3sprog -- Installing: /usr/local/bin/xc2c_warp -- Installing: /usr/local/bin/readdna -- Installing: /usr/local/bin/bitparse -- Installing: /usr/local/bin/jedecparse -- Installing: /usr/local/bin/srecparse -- Installing: /usr/local/bin/detectchain
Tom's Computer Info / [email protected]