summaryrefslogtreecommitdiff
path: root/media-plugins/gmsynth-lv2/files/gmsynth-lv2-0.6.3-makefile.patch
blob: 027a3700b46a25dd0954df1c2f5de447d193ab43 (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
respect userflags
--- a/Makefile
+++ b/Makefile
@@ -17,18 +17,12 @@ gmsynth_VERSION?=$(shell git describe --tags HEAD 2>/dev/null | sed 's/-g.*$$//;
 
 ###############################################################################
 
-MACHINE=$(shell uname -m)
-ifneq (,$(findstring x64,$(MACHINE)))
-  HAVE_SSE=yes
-endif
-ifneq (,$(findstring 86,$(MACHINE)))
-  HAVE_SSE=yes
-endif
+HAVE_SSE ?= yes
 
 ifeq ($(HAVE_SSE),yes)
-  OPTIMIZATIONS ?= -msse -msse2 -mfpmath=sse -ffast-math -fomit-frame-pointer -O3 -fno-finite-math-only -DNDEBUG
+  OPTIMIZATIONS ?= -msse -msse2 -mfpmath=sse -ffast-math -fomit-frame-pointer -fno-finite-math-only -DNDEBUG
 else
-  OPTIMIZATIONS ?= -fomit-frame-pointer -O3 -fno-finite-math-only -DNDEBUG
+  OPTIMIZATIONS ?= -fomit-frame-pointer -fno-finite-math-only -DNDEBUG
 endif
 
 ###############################################################################
@@ -166,7 +160,7 @@ DSP_DEPS = $(DSP_SRC)
 
 $(BUILDDIR)$(LV2NAME)$(LIB_EXT): $(DSP_DEPS) Makefile
 	@mkdir -p $(BUILDDIR)
-	$(CC) $(CPPFLAGS) $(CFLAGS) -std=gnu99 \
+	$(CC) $(CPPFLAGS) -std=gnu99 $(CFLAGS) \
 	  -o $(BUILDDIR)$(LV2NAME)$(LIB_EXT) $(DSP_SRC) \
 	  -shared $(LV2LDFLAGS) $(LDFLAGS) $(LOADLIBES)
	$(STRIP) $(STRIPFLAGS) $(BUILDDIR)$(LV2NAME)$(LIB_EXT)