diff libinterp/corefcn/module.mk @ 17830:f22714d4a5da

build: Don't use JAVA_CPPFLAGS, FT2_CPPFLAGS everywhere when making .df files. *.cc -> *.df rule now stops build when it fails (as it should have done before). * libinterp/Makefile.am: Remove FONTCONFIG_CPPFLAGS, FT2_CPPFLAGS, JAVA_CPPFLAGS from defaulte *.cc -> *.df rule. Abort make if rule errors out. * libinterp/corefcn/module.mk: Add overriding *.cc -> *.df rule for files which use (FONTCONFIG|FT2)_CPPFLAGS. * libinterp/octave-value/module.mk: Add overriding *.cc -> *.df rule for files which use JAVA_CPPFLAGS.
author Rik <rik@octave.org>
date Sat, 02 Nov 2013 14:34:02 -0700
parents 3488d987eb50
children 25601fe8c6f7
line wrap: on
line diff
--- a/libinterp/corefcn/module.mk	Sat Nov 02 14:46:43 2013 -0400
+++ b/libinterp/corefcn/module.mk	Sat Nov 02 14:34:02 2013 -0700
@@ -261,12 +261,28 @@
   $(JIT_SRC) \
   $(C_COREFCN_SRC)
 
+COREFCN_FT2_DF = \
+  corefcn/graphics.df \
+  corefcn/gl-render.df \
+  corefcn/toplev.df \
+  corefcn/txt-eng-ft.df
+
 ## FIXME: Automake does not support per-object rules.
 ##        These rules could be emulated by creating a new convenience
 ##        library and using per-library rules.  Or we can just live
 ##        without the rule since there haven't been any problems. (09/18/2012)
 #display.df display.lo: CPPFLAGS += $(X11_FLAGS)
 
+## Special rules for FreeType .df files so that not all .df files are built
+## with FT2_CPPFLAGS, FONTCONFIG_CPPFLAGS
+$(COREFCN_FT2_DF) : corefcn/%.df : corefcn/%.cc
+	$(CXXCPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
+	  $(AM_CPPFLAGS) $(FONTCONFIG_CPPFLAGS) $(FT2_CPPFLAGS) $(CPPFLAGS) \
+	  $(AM_CXXFLAGS) $(CXXFLAGS) \
+	  -DMAKE_BUILTINS $< > $@-t
+	$(srcdir)/mkdefs $(srcdir) $< < $@-t > $@
+	rm $@-t
+
 ## Special rules for sources which must be built before rest of compilation.
 
 ## defaults.h and graphics.h must depend on Makefile.  Calling configure