aboutsummaryrefslogtreecommitdiff
path: root/contrib/long_distance_matching/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/long_distance_matching/Makefile')
-rw-r--r--contrib/long_distance_matching/Makefile36
1 files changed, 36 insertions, 0 deletions
diff --git a/contrib/long_distance_matching/Makefile b/contrib/long_distance_matching/Makefile
new file mode 100644
index 000000000000..6ed1fab45f5b
--- /dev/null
+++ b/contrib/long_distance_matching/Makefile
@@ -0,0 +1,36 @@
+# ################################################################
+# Copyright (c) 2017-present, Facebook, Inc.
+# All rights reserved.
+#
+# This source code is licensed under both the BSD-style license (found in the
+# LICENSE file in the root directory of this source tree) and the GPLv2 (found
+# in the COPYING file in the root directory of this source tree).
+# ################################################################
+
+# This Makefile presumes libzstd is installed, using `sudo make install`
+
+CPPFLAGS+= -I../../lib/common
+CFLAGS ?= -O3
+DEBUGFLAGS = -Wall -Wextra -Wcast-qual -Wcast-align -Wshadow \
+ -Wstrict-aliasing=1 -Wswitch-enum -Wdeclaration-after-statement \
+ -Wstrict-prototypes -Wundef -Wpointer-arith -Wformat-security \
+ -Wvla -Wformat=2 -Winit-self -Wfloat-equal -Wwrite-strings \
+ -Wredundant-decls
+CFLAGS += $(DEBUGFLAGS) $(MOREFLAGS)
+FLAGS = $(CPPFLAGS) $(CFLAGS)
+
+LDFLAGS += -lzstd
+
+.PHONY: default all clean
+
+default: all
+
+all: ldm
+
+ldm: ldm_common.c ldm.c main.c
+ $(CC) $(CPPFLAGS) $(CFLAGS) $^ $(LDFLAGS) -o $@
+
+clean:
+ @rm -f core *.o tmp* result* *.ldm *.ldm.dec \
+ ldm
+ @echo Cleaning completed