diff options
Diffstat (limited to 'decompress/Makefile')
| -rw-r--r-- | decompress/Makefile | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/decompress/Makefile b/decompress/Makefile new file mode 100644 index 0000000..f3d0d32 --- /dev/null +++ b/decompress/Makefile @@ -0,0 +1,25 @@ +CC ?= gcc +TARGET := decompress +SRC := decompress.c + +PKGS := doca-compress doca-common + +CFLAGS ?= -O2 -g -Wall -Wextra -Wno-deprecated-declarations -DALLOW_EXPERIMENTAL_API +CFLAGS += $(shell pkg-config --cflags $(PKGS) 2>/dev/null) + +LDLIBS += $(shell pkg-config --libs $(PKGS) 2>/dev/null) + +ifeq ($(strip $(LDLIBS)),) +CFLAGS += -I/opt/mellanox/doca/include -I/usr/include/libnl3 +LDLIBS += -L/opt/mellanox/doca/lib/aarch64-linux-gnu \ + -L/opt/mellanox/doca/lib64 \ + -ldoca_compress -ldoca_common +endif + +all: $(TARGET) + +$(TARGET): $(SRC) + $(CC) $(CFLAGS) $< -o $@ $(LDLIBS) + +clean: + rm -f $(TARGET) *.o decompressed.out |
