DragonFly BSD
DragonFly users List (threaded) for 2005-05
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

Re: programming: Makefile


From: "Simon 'corecode' Schubert" <corecode@xxxxxxxxxxxx>
Date: Fri, 27 May 2005 21:52:39 +0200

George Georgalis wrote:
> But now, when I do this (home/geo is a cvs module):
> 
> include function.mk
> geo :
> 	make -C home/geo MAKE_REAL_HARD_LINKS REAL=/home/geo
> 
> I get...
> 
> % make geo       
> make -C home/geo MAKE_REAL_HARD_LINKS REAL=/home/geo
> make: don't know how to make MAKE_REAL_HARD_LINKS. Stop
> *** Error code 2
> 
> 
> So how does one "include" targets, or am I going about this wrong?

hmm... either you want to use -f function.mk to use the correct makefile
in your recursive make, or you might want to restructure your system to
use .for loops in the makefile like

DIRS=home/geo home/foo

. for REAL in ${DIRS}
. for _targ in do_${REAL:C,/,_,g}
all: ${_targ}
${_targ}:
	<code to make hardlinks>
. endfor
. endfor

cheers
  simon

-- 
Serve - BSD     +++  RENT this banner advert  +++    ASCII Ribbon   /"\
Work - Mac      +++  space for low $$$ NOW!1  +++      Campaign     \ /
Party Enjoy Relax   |   http://dragonflybsd.org      Against  HTML   \
Dude 2c 2 the max   !   http://golden-apple.biz       Mail + News   / \



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