changeset 9979:3878bae57c12

Clean liboctave/Makefile.am to use more standard automake syntax and reduce unnecessary compilations.
author Rik <rdrider0-list@yahoo.com>
date Sun, 13 Dec 2009 20:01:16 -0800
parents 13a85d3e13bb
children e352f8366b02
files liboctave/ChangeLog liboctave/Makefile.am
diffstat 2 files changed, 12 insertions(+), 13 deletions(-) [+]
line wrap: on
line diff
--- a/liboctave/ChangeLog
+++ b/liboctave/ChangeLog
@@ -1,3 +1,10 @@
+2009-12-13  Rik <octave@nomad.inbox5.com>
+
+	* Makefile.am: Use DISTCLEANFILES rather than distclean-local rule.
+	Use PERL variable defined by autoconf rather than direct call.  Use
+	simple_move_if_change rule to reduce useless compiles if OPTS_INC have not
+	changed.
+
 2009-12-12  Jaroslav Hajek  <highegg@gmail.com>
 
 	* oct-shlib.h: Remove stray declarations.
--- a/liboctave/Makefile.am
+++ b/liboctave/Makefile.am
@@ -23,8 +23,6 @@
  
 include ../common.mk
 
-octlib_LTLIBRARIES = liboctave.la
-
 AM_CPPFLAGS = -I$(top_srcdir)/libgnu -I$(top_srcdir)/libcruft/misc
 
 EXTRA_DIST = \
@@ -271,11 +269,6 @@
 
 BUILT_SOURCES = $(BUILT_INCS)
 
-## FIXME -- These files don't need to be distributed.  They do need
-## to be installed.  So we need to add them to a list somewhere so
-## that happens correctly.
-BUILT_NODISTFILES = $(BUILT_INCS)
-
 TEMPLATE_SRC = \
   Array.cc \
   DiagArray2.cc \
@@ -404,6 +397,8 @@
   uint64NDArray.cc \
   uint8NDArray.cc
 
+octlib_LTLIBRARIES = liboctave.la
+
 LIBOCTAVE_CXX_SOURCES = \
   CollocWt.cc \
   DASPK.cc \
@@ -537,8 +532,8 @@
 
 $(OPT_INC) : %.h : %.in $(top_srcdir)/mk-opts.pl
 	@echo making $@ from $<
-	@perl $(top_srcdir)/mk-opts.pl --opt-class-header $< > $@-t
-	@mv $@-t $@
+	@$(PERL) $(top_srcdir)/mk-opts.pl --opt-class-header $< > $@-t
+	$(simple_move_if_change_rule)
 
 $(VX_OP_INC) $(VX_OP_SRC) : $(srcdir)/mk-ops.awk vx-ops
 	$(AWK) -f $(srcdir)/mk-ops.awk prefix=vx $(srcdir)/vx-ops
@@ -553,8 +548,5 @@
 	$(AWK) -f $(srcdir)/mk-ops.awk prefix=mx make_inclusive_header=mx-ops.h $(srcdir)/mx-ops > $@-t
 	$(simple_move_if_change_rule)
 
-distclean-local:
-	rm -f $(BUILT_INCS) $(BUILT_LIBOCTAVE_CXX_SOURCES)
+DISTCLEANFILES = $(BUILT_INCS) $(BUILT_LIBOCTAVE_CXX_SOURCES)
 
-#distclean-local maintainer-clean-local:
-#.PHONY: distclean-local maintainer-clean-local