summaryrefslogtreecommitdiff
path: root/examples/VFS/Makefile.in
blob: caf8f030aa48163bc132df0fe84d6f01b2fc54a4 (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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
CC		= @CC@
CFLAGS		= @CFLAGS@
CPPFLAGS	= @CPPFLAGS@
LDFLAGS		= @LDFLAGS@
LDSHFLAGS	= @LDSHFLAGS@
INSTALLCMD	= @INSTALL@
SAMBA_SOURCE	= @SAMBA_SOURCE@
SHLIBEXT	= @SHLIBEXT@
OBJEXT		= @OBJEXT@ 
FLAGS		=  $(CFLAGS) -Iinclude -I$(SAMBA_SOURCE)/include -I$(SAMBA_SOURCE)/popt -I$(SAMBA_SOURCE)/smbwrapper  -I. $(CPPFLAGS) -I$(SAMBA_SOURCE) -fPIC


prefix		= @prefix@
libdir		= @libdir@

VFS_LIBDIR	= $(libdir)/vfs

# Auto target
default: $(patsubst %.c,%.$(SHLIBEXT),$(wildcard *.c))

# Pattern rules

%.$(SHLIBEXT): %.$(OBJEXT)
	@echo "Linking $@"
	@$(CC) $(LDSHFLAGS) $(LDFLAGS) -o $@ $<

%.$(OBJEXT): %.c
	@echo "Compiling $<"
	@$(CC) $(FLAGS) -c $<


install: default
	$(INSTALLCMD) -d $(VFS_LIBDIR)
	$(INSTALLCMD) -m 755 *.$(SHLIBEXT) $(VFS_LIBDIR)

# Misc targets
clean:
	rm -rf .libs
	rm -f core *~ *% *.bak *.o *.$(SHLIBEXT)

distclean: clean
	rm config.* Makefile