]> git.proxmox.com Git - ceph.git/blame - ceph/src/zstd/lib/dll/example/Makefile
update sources to ceph Nautilus 14.2.1
[ceph.git] / ceph / src / zstd / lib / dll / example / Makefile
CommitLineData
11fdf7f2 1# ################################################################
7c673cae
FG
2# Copyright (c) 2016-present, Yann Collet, Facebook, Inc.
3# All rights reserved.
4#
11fdf7f2
TL
5# This source code is licensed under both the BSD-style license (found in the
6# LICENSE file in the root directory of this source tree) and the GPLv2 (found
7# in the COPYING file in the root directory of this source tree).
8# ################################################################
7c673cae
FG
9
10VOID := /dev/null
11ZSTDDIR := ../include
12LIBDIR := ../static
13DLLDIR := ../dll
14
15CFLAGS ?= -O3 # can select custom flags. For example : CFLAGS="-O2 -g" make
16CFLAGS += -Wall -Wextra -Wundef -Wcast-qual -Wcast-align -Wshadow -Wswitch-enum \
17 -Wdeclaration-after-statement -Wstrict-prototypes \
18 -Wpointer-arith -Wstrict-aliasing=1
19CFLAGS += $(MOREFLAGS)
20CPPFLAGS:= -I$(ZSTDDIR) -DXXH_NAMESPACE=ZSTD_
21FLAGS := $(CFLAGS) $(CPPFLAGS) $(LDFLAGS)
22
23
24# Define *.exe as extension for Windows systems
25ifneq (,$(filter Windows%,$(OS)))
26EXT =.exe
27else
28EXT =
29endif
30
31.PHONY: default fullbench-dll fullbench-lib
32
33
34default: all
35
36all: fullbench-dll fullbench-lib
37
38
39fullbench-lib: fullbench.c datagen.c
40 $(CC) $(FLAGS) $^ -o $@$(EXT) $(LIBDIR)/libzstd_static.lib
41
42fullbench-dll: fullbench.c datagen.c
43 $(CC) $(FLAGS) $^ -o $@$(EXT) -DZSTD_DLL_IMPORT=1 $(DLLDIR)/libzstd.dll
44
45clean:
46 @$(RM) fullbench-dll$(EXT) fullbench-lib$(EXT) \
47 @echo Cleaning completed