Both compilers which are used for building firmware (sdcc for FX2 and gcc for FX3) come from the Unix-world. They have been ported to Windows but unfortunately Windows is a quite unfriendly environment for such programs. Some SDK's hide this behind an IDE (e.g. the Cypress FX3 SDK is delivered with Eclipse). ZTEX does no go this way.
The building rules of the ZTEX SDK are described by platform and IDE independent Makfiles. This tutorial gives you some hints for setting up the development environment and describes how the SDK can be integrated into an IDE.
pacman -S msys/make
pacman -S msys/mc
mc
cd /c/
Makfile.conf
, see Tutorial -- Compilation of an example. Spaces and other odd signs in directory names cause a lot of trouble. In order to prevent this, create a few symlinks without spaces, e.g. link the installation directory of the Cypress FX3 SDK to /c/cypress
(= c:\cypress
) libusb-1.0
and gcc
are required: pacman -S mingw64/mingw-w64-x86_64-gcc mingw64/mingw-w64-x86_64-libusb
for 64 Bit binaries or
pacman -S mingw32/mingw-w64-i686-gcc mingw32/mingw-w64-i686-libusb
for 32 Bit binaries
make
sh.exe
or bash.exe
of your MSys(2) Installation. Both shells work. On the test system it is c:\mingw\msys\1.0\bin\bash.exe
and the SDK is installed in s:\ztex
c:\mingw\msys\1.0\bin\bash -l -c "make -C /s/ztex/examples/memfifo [<target>]"
This builds a target of the memfifo example in examples/memfifo
. Typical targets are all
, img
, ihx
, jar
, claen
or distclean
, see makefiles
Java host software can be compiled and executed without GNU tools. Just the class and JNI library location (in the example above: s:\ztex\java\java
and s:\ztex\usb4java
) has to be added to the CLASSPATH
environment variable.