Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!rpi!uwm.edu!bionet!apple!well!gregs From: gregs@well.sf.ca.us (Greg Strockbine) Newsgroups: comp.unix.shell Subject: a make question Message-ID: <23323@well.sf.ca.us> Date: 25 Feb 91 16:46:28 GMT Lines: 35 Here is a 'make' question. I run a make at a top level directory to do a link. Before the link is done make descends into 2 sub directories and builds libraries needed for the link. So far so good. My problem is, if one of the libraries fails to build how do I abort the link? Do I check the return code from the makes? If the first library does not build I would like 'make' to still try to build the second library. 1550 | (make link) +------+------+ | | comn pdbb (lib1) (lib2) relevant parts of Makefile extracted below (this is gnu make): --------------------- SUBDIRS = pdbb comn link: SubDirs $(LD) -c $(LDCMD) -o $(LN).X -H $(LN).L $(LDFLAGS) > $(LN).map SubDirs: @echo "Checking subdirectories..." @for i in $(SUBDIRS);do \ echo "---"$$i"---";\ (cd $$i;$(MAKE);)\ done;\ echo "---Done checking subdirectories---"; ---------------------------- thanx in advance, greg strockbine, dataproducts, woodland hills, ca. Brought to you by Super Global Mega Corp .com