blob: 3fc1428ac0702d40a2195eed53140ccf948bb87d (
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
44
45
46
47
|
diff --git a/vst3/buildLinux.sh b/vst3/buildLinux.sh
index 647969a..2ac4034 100755
--- a/vst3/buildLinux.sh
+++ b/vst3/buildLinux.sh
@@ -1,15 +1,19 @@
#!/bin/bash
-VST_SDK_DIR=../../VST_SDK
+VST_SDK_DIR="${VST_SDK_DIR:-../../VST_SDK}"
rm -rf build
mkdir -p build/asid.vst3/Contents
cp -R asid.vst3/Contents/Resources build/asid.vst3/Contents
-mkdir -p build/asid.vst3/Contents/x86_64-linux
+mkdir -p build/asid.vst3/Contents/$(uname -m)-linux
g++ \
+ -DRELEASE=1 \
+ -I../src \
+ -Isrc \
+ -I$VST_SDK_DIR/vst3sdk/ \
src/vst3/entry.cpp \
src/vst3/plugin.cpp \
src/vst3/controllerLinux.cpp \
@@ -42,16 +46,11 @@ g++ \
src/asid_gui.c \
src/gui-x.c \
\
- -DRELEASE=1 \
- -I../src \
- -Isrc \
- -I$VST_SDK_DIR/vst3sdk/ \
-fPIC -shared \
- -lxcb \
- -o build/asid.vst3/Contents/x86_64-linux/asid.so \
- -O3 \
- -ffast-math
-
+ $(pkg-config --cflags --libs xcb) \
+ -o build/asid.vst3/Contents/$(uname -m)-linux/asid.so \
+ ${CXXFLAGS:--O3 -ffast-math} $LDFLAGS
+
# for a more static build we probably need
# -static-libgcc -static-libstdc++ -l:library.a...
# with static libraries built with -fPIC
|