mirror of
https://github.com/intel/isa-l.git
synced 2024-12-13 09:52:56 +01:00
ex: Add makefile to build examples from installed lib
Change-Id: I10a51dfe90e0672bb33348de241a5be91c9caa37 Signed-off-by: Greg Tucker <greg.b.tucker@intel.com>
This commit is contained in:
parent
0f7bf1c04d
commit
628f4e91ea
24
examples/ec/Makefile
Normal file
24
examples/ec/Makefile
Normal file
@ -0,0 +1,24 @@
|
||||
# Build examples from installed lib
|
||||
|
||||
include Makefile.am
|
||||
|
||||
incdir = $(shell pkg-config --variable=includedir libisal)
|
||||
|
||||
CFLAGS += -include $(incdir)/isa-l.h # Add standard header
|
||||
CFLAGS += -I $(incdir)/isa-l # Add path to remove error
|
||||
LDFLAGS = $(shell pkg-config --libs libisal)
|
||||
|
||||
progs = $(notdir $(examples))
|
||||
|
||||
ex: $(progs)
|
||||
run: $(addsuffix .run,$(progs))
|
||||
|
||||
$(progs): % : %.c
|
||||
$(CC) $(CFLAGS) -o $@ $^ $(LDFLAGS)
|
||||
|
||||
$(addsuffix .run,$(progs)): %.run : %
|
||||
./$<
|
||||
@echo Completed run: $<
|
||||
|
||||
clean:
|
||||
$(RM) $(progs)
|
@ -1,8 +0,0 @@
|
||||
|
||||
default: ex
|
||||
|
||||
include ../../erasure_code/Makefile.am
|
||||
include Makefile.am
|
||||
include ../../make.inc
|
||||
|
||||
VPATH = . ../../erasure_code ../../include
|
Loading…
Reference in New Issue
Block a user