Line 1... |
Line 1... |
prefix = /usr/local
|
prefix = /usr/local
|
|
|
# These are for native Linux. You may need to put the path to libusb.a into the LIBS variable
|
# These are for native Linux. You may need to put the path to libusb.a into the LIBS variable
|
# with the -L command.
|
# with the -L command. You may also need to add the path to usb.h in INCLUDEDIRS -
|
|
# the default install location is already listed.
|
#CFLAGS = -g -O2 -Wall
|
#CFLAGS = -g -O2 -Wall
|
#CC = gcc
|
#CC = gcc
|
#LIBS = -lusb -lpthread
|
#LIBS = -lusb -lpthread
|
|
#INCLUDEDIRS = -I/usr/local/include/libusb-1.0/ -I/usr/local/include/
|
|
|
# These are for cygwin. It assumes libusb.a is in the current directory.
|
# These are for cygwin. It assumes libusb.a and usb.h are in the current directory.
|
CFLAGS = -g -O2 -Wall
|
CFLAGS = -g -O2 -Wall
|
CC = gcc
|
CC = gcc
|
LIBS = -L. -lioperm -lusb -lpthread
|
LIBS = -L. -lioperm -lusb -lpthread
|
|
INCLUDEDIRS = -I/usr/local/include/
|
|
|
|
|
|
|
|
|
PROGRAMS = adv_jtag_bridge
|
PROGRAMS = adv_jtag_bridge
|
|
|
HEADERS = adv_jtag_bridge.h adv_debug_module.h chain_commands.h opencores_tap.h \
|
HEADERS = adv_jtag_bridge.h adv_debug_module.h chain_commands.h opencores_tap.h \
|
altera_virtual_jtag.h rsp-server.h bsdl.h usb.h or32_selftest.c cable_common.h \
|
altera_virtual_jtag.h rsp-server.h bsdl.h or32_selftest.c cable_common.h \
|
cable_parallel.h cable_sim.h cable_usbblaster.h cable_xpc_dlc9.h \
|
cable_parallel.h cable_sim.h cable_usbblaster.h cable_xpc_dlc9.h \
|
bsdl_parse.h errcodes.h spr-defs.h except.h
|
bsdl_parse.h errcodes.h spr-defs.h except.h
|
|
|
SOURCES = adv_jtag_bridge.c rsp-server.c chain_commands.c cable_common.c bsdl.c \
|
SOURCES = adv_jtag_bridge.c rsp-server.c chain_commands.c cable_common.c bsdl.c \
|
or32_selftest.c cable_parallel.c cable_sim.c cable_usbblaster.c cable_xpc_dlc9.c \
|
or32_selftest.c cable_parallel.c cable_sim.c cable_usbblaster.c cable_xpc_dlc9.c \
|
Line 35... |
Line 37... |
default: $(PROGRAMS)
|
default: $(PROGRAMS)
|
|
|
.c.o:
|
.c.o:
|
$(CC) $(CFLAGS) -c $<
|
$(CC) $(CFLAGS) -c $<
|
|
|
adv_jtag_bridge: Makefile $(OBJECTS) $(HEADERS) libusb.a
|
adv_jtag_bridge: Makefile $(OBJECTS) $(HEADERS)
|
rm -f $@
|
rm -f $@
|
$(CC) -o $@ $(CFLAGS) $(OBJECTS) $(LIBS)
|
$(CC) -o $@ $(CFLAGS) $(OBJECTS) $(LIBS) $(INCLUDEDIRS)
|
|
|
|
|
install: all
|
install: all
|
[ -d $(prefix)/bin ] || mkdir -p $(prefix)/bin
|
[ -d $(prefix)/bin ] || mkdir -p $(prefix)/bin
|
for p in $(PROGRAMS) ; do \
|
for p in $(PROGRAMS) ; do \
|