summaryrefslogtreecommitdiff
path: root/src/Makefile
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2017-01-17 19:20:15 +0100
committerBram Moolenaar <Bram@vim.org>2017-01-17 19:20:15 +0100
commit6e78e27b8aace2e4c2412bfc4de6567509258d28 (patch)
tree5795a4feee689f9b03df01c8d7d0b866a877f323 /src/Makefile
parent4007ed4a5e8c34197078e9d5718bd1d4a429dd23 (diff)
downloadvim-6e78e27b8aace2e4c2412bfc4de6567509258d28.zip
patch 8.0.0203: order of complication flags is sometimes wrong
Problem: Order of complication flags is sometimes wrong. Solution: Put interface-specific flags before ALL_CFLAGS. (idea by Yousong Zhou, closes #1100)
Diffstat (limited to 'src/Makefile')
-rw-r--r--src/Makefile25
1 files changed, 14 insertions, 11 deletions
diff --git a/src/Makefile b/src/Makefile
index 38ca4cd16..1070b23f7 100644
--- a/src/Makefile
+++ b/src/Makefile
@@ -1877,7 +1877,9 @@ myself:
# The normal command to compile a .c file to its .o file.
-CCC = $(CC) -c -I$(srcdir) $(ALL_CFLAGS)
+# Without or with ALL_CFLAGS.
+CCC_NF = $(CC) -c -I$(srcdir)
+CCC = $(CCC_NF) $(ALL_CFLAGS)
# Link the target for normal use or debugging.
@@ -2976,7 +2978,7 @@ objects/gui_gtk_f.o: gui_gtk_f.c
$(CCC) -o $@ gui_gtk_f.c
objects/gui_gtk_gresources.o: auto/gui_gtk_gresources.c
- $(CCC) $(PERL_CFLAGS) -o $@ auto/gui_gtk_gresources.c
+ $(CCC_NF) $(PERL_CFLAGS) $(ALL_CFLAGS) -o $@ auto/gui_gtk_gresources.c
objects/gui_gtk_x11.o: gui_gtk_x11.c
$(CCC) -o $@ gui_gtk_x11.c
@@ -3009,7 +3011,7 @@ objects/if_xcmdsrv.o: if_xcmdsrv.c
$(CCC) -o $@ if_xcmdsrv.c
objects/if_lua.o: if_lua.c
- $(CCC) $(LUA_CFLAGS) -o $@ if_lua.c
+ $(CCC_NF) $(LUA_CFLAGS) $(ALL_CFLAGS) -o $@ if_lua.c
objects/if_mzsch.o: if_mzsch.c $(MZSCHEME_EXTRA)
$(CCC) -o $@ $(MZSCHEME_CFLAGS_EXTRA) if_mzsch.c
@@ -3018,27 +3020,28 @@ mzscheme_base.c:
$(MZSCHEME_MZC) --c-mods mzscheme_base.c ++lib scheme/base
objects/if_perl.o: auto/if_perl.c
- $(CCC) $(PERL_CFLAGS) -o $@ auto/if_perl.c
+ $(CCC_NF) $(PERL_CFLAGS) $(ALL_CFLAGS) -o $@ auto/if_perl.c
objects/if_perlsfio.o: if_perlsfio.c
- $(CCC) $(PERL_CFLAGS) -o $@ if_perlsfio.c
+ $(CCC_NF) $(PERL_CFLAGS) $(ALL_CFLAGS) -o $@ if_perlsfio.c
objects/py_getpath.o: $(PYTHON_CONFDIR)/getpath.c
- $(CCC) $(PYTHON_CFLAGS) -o $@ $(PYTHON_CONFDIR)/getpath.c \
+ $(CCC_NF) $(PYTHON_CFLAGS) $(ALL_CFLAGS) -o $@ \
+ $(PYTHON_CONFDIR)/getpath.c \
-I$(PYTHON_CONFDIR) -DHAVE_CONFIG_H -DNO_MAIN \
$(PYTHON_GETPATH_CFLAGS)
objects/if_python.o: if_python.c if_py_both.h
- $(CCC) $(PYTHON_CFLAGS) $(PYTHON_CFLAGS_EXTRA) -o $@ if_python.c
+ $(CCC_NF) $(PYTHON_CFLAGS) $(PYTHON_CFLAGS_EXTRA) $(ALL_CFLAGS) -o $@ if_python.c
objects/if_python3.o: if_python3.c if_py_both.h
- $(CCC) $(PYTHON3_CFLAGS) $(PYTHON3_CFLAGS_EXTRA) -o $@ if_python3.c
+ $(CCC_NF) $(PYTHON3_CFLAGS) $(PYTHON3_CFLAGS_EXTRA) $(ALL_CFLAGS) -o $@ if_python3.c
objects/if_ruby.o: if_ruby.c
- $(CCC) $(RUBY_CFLAGS) -o $@ if_ruby.c
+ $(CCC_NF) $(RUBY_CFLAGS) $(ALL_CFLAGS) -o $@ if_ruby.c
objects/if_tcl.o: if_tcl.c
- $(CCC) $(TCL_CFLAGS) -o $@ if_tcl.c
+ $(CCC_NF) $(TCL_CFLAGS) $(ALL_CFLAGS) -o $@ if_tcl.c
objects/integration.o: integration.c
$(CCC) -o $@ integration.c
@@ -3095,7 +3098,7 @@ objects/ops.o: ops.c
$(CCC) -o $@ ops.c
objects/option.o: option.c
- $(CCC) $(LUA_CFLAGS) $(PERL_CFLAGS) $(PYTHON_CFLAGS) $(PYTHON3_CFLAGS) $(RUBY_CFLAGS) $(TCL_CFLAGS) -o $@ option.c
+ $(CCC_NF) $(LUA_CFLAGS) $(PERL_CFLAGS) $(PYTHON_CFLAGS) $(PYTHON3_CFLAGS) $(RUBY_CFLAGS) $(TCL_CFLAGS) $(ALL_CFLAGS) -o $@ option.c
objects/os_beos.o: os_beos.c
$(CCC) -o $@ os_beos.c