embeddedsw/mcap/linux/Makefile
Kedareswara rao Appana e29e5689e0 mcap: Add MCAP Linux Library
The MCAP interface enables an embedded microprocessor, such as MicroBlaze,
    to read and write the FPGA configuration memory.
    This library allows user to access the MCAP i/f.

Signed-off-by: Srikanth Thokala <sthokal@xilinx.com>
Signed-off-by: Kedareswara rao Appana <appanad@xilinx.com>
2014-11-25 21:38:06 +05:30

35 lines
644 B
Makefile

# Makefile for Xilinx MCAP Interface Library
# (c) 2014 Xilinx Inc.
PCIUTILS_PATH =
PCILIB_PATH=$(PCIUTILS_PATH)/lib/
INCLUDES = -I$(PCILIB_PATH) -I$(PCIUTILS_PATH) -I.
OPT=-O2
CFLAGS=$(OPT) -Wall -W -Wno-parentheses -Wstrict-prototypes -Wmissing-prototypes $(INCLUDES)
LDFLAGS = -L$(PCILIB_PATH)
LDLIBS = -lpci
PCILIB = $(PCILIB_PATH)/libpci.a
MCAPLIB = libmcap.a
MCAPINC = mcap_lib.h
OBJ = mcap_lib.o
all: $(MCAPLIB) mcap
$(MCAPLIB): $(OBJ)
ar rcs $(MCAPLIB) $(OBJ)
$(OBJ):
gcc $(LDFLAGS) $(CFLAGS) -c mcap_lib.c $< -o $@ $(LDLIBS)
mcap: mcap.o
gcc $(CFLAGS) mcap.c $(MCAPLIB) $(PCILIB) -lz -o mcap
clean:
rm -f *.o *.a mcap