libcvd-members
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[libcvd-members] libcvd Makefile.in


From: Edward Rosten
Subject: [libcvd-members] libcvd Makefile.in
Date: Tue, 19 May 2009 16:04:30 +0000

CVSROOT:        /cvsroot/libcvd
Module name:    libcvd
Changes by:     Edward Rosten <edrosten>        09/05/19 16:04:30

Modified files:
        .              : Makefile.in 

Log message:
        Fixed makefile so it doesn't die when some debug directories are 
missing.

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/libcvd/Makefile.in?cvsroot=libcvd&r1=1.89&r2=1.90

Patches:
Index: Makefile.in
===================================================================
RCS file: /cvsroot/libcvd/libcvd/Makefile.in,v
retrieving revision 1.89
retrieving revision 1.90
diff -u -b -r1.89 -r1.90
--- Makefile.in 13 May 2009 19:01:04 -0000      1.89
+++ Makefile.in 19 May 2009 16:04:29 -0000      1.90
@@ -19,6 +19,7 @@
 includedir = @includedir@
 oldincludedir = /usr/include
 arch= @build_cpu@
address@hidden@
 
 
 CC = @CC@
@@ -168,9 +169,17 @@
        $(AR) crvs libcvd_debug.a $(DEBUG_OBJS)
        $(RANLIB) libcvd_debug.a
 
-debug:
-       mkdir -p debug/cvd_src debug/cvd_src/IRIX debug/cvd_src/Linux 
debug/cvd_src/OSX debug/cvd_src/fast debug/cvd_src/i686 debug/cvd_src/noarch 
debug/pnm_src debug/cvd_src/thread debug/cvd_src/nothread
+#Automatically deduce the debug directories
+DEBUG_DIRS=$(shell find ???_src -type d -not -name 'CVS' -printf 'debug/%p\n')
 
+#This the debug subdir all debug directories, so specifying a dependency on 
this
+#will ensure that all subdirs get created
+debug:$(DEBUG_DIRS)
+
+#Multiple targets are allowed on the left, so all directories can be created 
in batch
+#with a single rule
+$(DEBUG_DIRS):
+       mkdir -p $(DEBUG_DIRS)
 
 # Before we compile the test programs we need to augment the
 # search paths with the path to libcvd, and also add libcvd to the
@@ -295,7 +304,7 @@
 debug/%.o: %.C debug
        $(CXX) -I. $(CPPFLAGS) $(CXXFLAGS) $(DEBUGEXTRA) -c $< -o $@
 
-debug/%.o: %.s
+debug/%.o: %.s debug
        as -g -o $@ $<
 
 %: %.o




reply via email to

[Prev in Thread] Current Thread [Next in Thread]