forked from osxmidi/LinVst
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile-standalone-64
70 lines (44 loc) · 1.81 KB
/
Makefile-standalone-64
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
67
68
69
70
#!/usr/bin/make -f
# Makefile for LinVst #
CXX = g++
WINECXX = wineg++
CXX_FLAGS =
PREFIX = /usr
BIN_DIR = $(DESTDIR)$(PREFIX)/bin
VST_DIR = ./vst
BUILD_FLAGS = -fPIC -O2 -DLVRT -DWAVES -DVESTIGE $(CXX_FLAGS)
BUILD_FLAGS_WIN = -m64 -O2 -DDRAG -DWINONTOP -DWAVES -DWAVESLOOP -DVESTIGE -I/usr/include/wine-development/windows -I/usr/include/wine-development/wine/windows -I/usr/include/wine/wine/windows
# undefine WINONTOP for standard window behaviour
LINK_FLAGS = $(LDFLAGS)
LINK_PLUGIN = -shared -lpthread -ldl -lX11 -lrt $(LINK_FLAGS)
LINK_WINE = -lpthread -lrt $(LINK_FLAGS)
TARGETS = linvst.so lin-vst-serverst.exe
# --------------------------------------------------------------
all: $(TARGETS)
linvst.so: linvst.unix.o remotevstclient.unix.o remotepluginclient.unix.o paths.unix.o
$(CXX) $^ $(LINK_PLUGIN) -o $@
lin-vst-serverst.exe: lin-vst-server.wine.o remotepluginserver.wine.o paths.wine.o
$(WINECXX) $^ $(LINK_WINE) -o $@
# --------------------------------------------------------------
linvst.unix.o: linvst.cpp
$(CXX) $(BUILD_FLAGS) -c $^ -o $@
remotevstclient.unix.o: remotevstclient.cpp
$(CXX) $(BUILD_FLAGS) -c $^ -o $@
remotepluginclient.unix.o: remotepluginclient.cpp
$(CXX) $(BUILD_FLAGS) -c $^ -o $@
paths.unix.o: paths.cpp
$(CXX) $(BUILD_FLAGS) -c $^ -o $@
# --------------------------------------------------------------
lin-vst-server.wine.o: lin-vst-server.cpp
$(WINECXX) $(BUILD_FLAGS_WIN) -c $^ -o $@
remotepluginserver.wine.o: remotepluginserver.cpp
$(WINECXX) $(BUILD_FLAGS_WIN) -c $^ -o $@
paths.wine.o: paths.cpp
$(WINECXX) $(BUILD_FLAGS_WIN) -c $^ -o $@
clean:
rm -fR *.o *.exe *.so vst $(TARGETS)
install:
install -d $(BIN_DIR)
install -d $(VST_DIR)
install -m 755 linvst.so $(VST_DIR)
install -m 755 lin-vst-serverst.exe lin-vst-serverst.exe.so $(BIN_DIR)