-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmakefile
More file actions
27 lines (20 loc) · 703 Bytes
/
makefile
File metadata and controls
27 lines (20 loc) · 703 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
# kindly set these env vars for us befure running (DIRSAMPLING prefix optional)
LIBEXECDIR?=$(DIRSAMPLING_LIBEXECDIR)
MAX_INCLUDE?=$(DIRSAMPLING_MAX_INCLUDE)
CC=x86_64-w64-mingw32-gcc
CFLAGS=-std=gnu11 -DWIN_VERSION -DWIN_EXT_VERSION -I"$(MAX_INCLUDE)"
LDFLAGS=-L"$(MAX_INCLUDE)/x64"
LIBS=-lMaxAPI
lib/dirsampling.mxe64 : build/dirsampling.o
$(CC) -shared -o lib/dirsampling.mxe64 build/dirsampling.o \
$(LDFLAGS) $(LIBS)
build/dirsampling.o : src/dirsampling.c
$(CC) -c $(CFLAGS) -o build/dirsampling.o src/dirsampling.c
.PHONY : install
install :
cp lib/dirsampling.mxe64 "$(LIBEXECDIR)"
.PHONY : clean
clean :
rm -rf build/* lib/*
.PHONY : all
all : lib/dirsampling.mxe64 install clean