-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
49 lines (38 loc) · 1.15 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
##############################
# spcaview Makefile
##############################
INSTALLROOT=$(PWD)
CC=gcc
CPP=g++
INSTALL=install
APP_BINARY=luvcview
BIN=/usr/local/bin
MATH_LIB = -lm
SDLLIBS = $(shell sdl-config --libs)
SDLFLAGS = $(shell sdl-config --cflags)
#LIBX11FLAGS= -I/usr/X11R6/include -L/usr/X11R6/lib
VERSION = 0.2.6
#WARNINGS = -Wall \
# -Wundef -Wpointer-arith -Wbad-function-cast \
# -Wcast-align -Wwrite-strings -Wstrict-prototypes \
# -Wmissing-prototypes -Wmissing-declarations \
# -Wnested-externs -Winline -Wcast-qual -W \
# -Wno-unused
# -Wunused
CFLAGS += -DUSE_SDL -O2 -DLINUX -DVERSION=\"$(VERSION)\" -I$(SDLFLAGS) $(WARNINGS)
CPPFLAGS = $(CFLAGS)
OBJECTS= luvcview.o color.o utils.o v4l2uvc.o gui.o avilib.o
all: luvcview
clean:
@echo "Cleaning up directory."
rm -f *.a *.o $(APP_BINARY) core *~ log errlog *.avi
# Applications:
luvcview: $(OBJECTS)
$(CC) $(CFLAGS) $(OBJECTS) $(X11_LIB) $(XPM_LIB)\
$(MATH_LIB) \
$(SDLLIBS)\
-o $(APP_BINARY)
chmod 755 $(APP_BINARY)
install: luvcview
$(INSTALL) -s -m 755 -g root -o root $(APP_BINARY) $(BIN)
rm -f $(BIN)/uvcview