aboutsummaryrefslogtreecommitdiffstats
path: root/fs/Makefile
blob: e3b647745f0941c573be1872fdbca5c27360c1f8 (plain)
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
27
28
29
TARGETS = tabfs

# Root for OSXFUSE includes and libraries
OSXFUSE_ROOT = /usr/local
#OSXFUSE_ROOT = /opt/local

CFLAGS_EXTRA = -DFUSE_USE_VERSION=26 -D_FILE_OFFSET_BITS=64 -Wall -Wno-unused-function -g

ifeq ($(shell uname -s),Linux)
	CFLAGS = $(CFLAGS_EXTRA)
	LIBS = -lfuse
endif
ifeq ($(shell uname -s),Darwin)
	CFLAGS = -I$(OSXFUSE_ROOT)/include/osxfuse/fuse -L$(OSXFUSE_ROOT)/lib -D_DARWIN_USE_64_BIT_INODE $(CFLAGS_EXTRA)
	LIBS = -losxfuse
endif

all: $(TARGETS)

tabfs: tabfs.c
	cc $(CFLAGS) -o $@ $^ $(LIBS)

clean:
	rm -f $(TARGETS) *.o
	rm -rf *.dSYM

unmount:
	killall -9 tabfs || true
	diskutil unmount force mnt || true