Home | History | Annotate | Line # | Download | only in dirshack
Makefile revision 1.2
      1  1.2  mrg #	$NetBSD: Makefile,v 1.2 2011/04/17 01:29:06 mrg Exp $
      2  1.1  mrg 
      3  1.1  mrg # hacky method to get compat multilib base objdirs created before
      4  1.1  mrg # make tries to go create the subdirs used for builds.
      5  1.1  mrg 
      6  1.1  mrg # the problem is that make handles objdir creation for subdirs before it
      7  1.1  mrg # handles this current directory, so when make cd's into $arch/$libtype
      8  1.1  mrg # and from there into the ../../lib dirs, it ends up setting the forced
      9  1.2  mrg # MAKEOBJDIR to something based upon ${.CURDIR}, since the objdir
     10  1.1  mrg # doesn't exist yet.
     11  1.1  mrg # 
     12  1.1  mrg # our solution is simple - from this Makefile we traverse the same list
     13  1.1  mrg # of $arch/$libtype's with "BOOTSTRAP_SUBDIR=".  then the compat/Makefile
     14  1.1  mrg # handles these subdirs as normal, with the base objdir created.
     15  1.1  mrg 
     16  1.1  mrg .include <bsd.own.mk>
     17  1.1  mrg 
     18  1.1  mrg .if ${MKCOMPAT} != "no"
     19  1.1  mrg .if make(obj)
     20  1.1  mrg 
     21  1.1  mrg .include "../archdirs.mk"
     22  1.1  mrg 
     23  1.1  mrg MAKEDIRTARGETENV=	BOOTSTRAP_SUBDIRS=
     24  1.1  mrg 
     25  1.1  mrg SUBDIR=	${ARCHDIR_SUBDIR:C/^/..\//}
     26  1.1  mrg 
     27  1.1  mrg .endif	# make(obj)
     28  1.1  mrg .endif	# MKCOMPAT != no
     29  1.1  mrg 
     30  1.1  mrg .include <bsd.subdir.mk>
     31