-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathMakefile
66 lines (45 loc) · 1.67 KB
/
Makefile
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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
#
# FullFAT root Makefile for the Linux demo.
#
MAKEFLAGS += -rR --no-print-directory
BASE=$(shell pwd)/
MODULE_NAME="FullFAT"
TARGETS = libfullfat.so libfullfat.a
include $(BASE).vebuild/vebuild.mk
include objects.mk
CC=gcc
CXX=g++
CFLAGS=-c -Wall -Werror -fPIC
all: $(TARGETS) $(SUBDIRS) libfullfat.a
$(SUBDIRS):MODULE_NAME=$@
default:
@echo "###################################################"
@echo "# FullFAT build environment for linux. #"
@echo "# by James Walmsley v0.2.1 #"
@echo "###################################################"
@cat Makefile | grep ":" | grep -v "default:"
demo:
./Demo/UNIX/demo.sh
fullfat: # Default FullFAT build command (calls fullfat.build).
make fullfat.build
fullfat.build: # Build the entire FullFAT library, with integrated demo.
make -C Demo/UNIX/ clean
make -C Demo/UNIX/ FullFAT
fullfat.lib: # Build a static FullFAT library for linking with a commercial project.
make -C src/ libfullfat.a
image: # Create a FAT32 formatted image file.
make -C Demo/UNIX/ image
check:
fsck.vfat Demo/UNIX/ffimage.img
testsuite:
make image; make fullfat; echo "testsuite; exit;" | make demo
make demo
verify: $(TARGETS) $(SUBDIRS)
$(Q) cd testsuite/verification && ./ffverify
config: # Enable/Disable FullFAT features (interactively)
@echo "Not yet implemented."
libfullfat.a: $(OBJECTS)
libfullfat.so: $(OBJECTS)
libfullfat.so: LDFLAGS += -shared -Wl,-soname,libfullfat.so
install:
@sudo cp libfullfat.so /usr/lib/