Makefile.inc revision 1.10
1#	$OpenBSD: Makefile.inc,v 1.10 2012/09/02 23:07:24 deraadt Exp $
2#	$NetBSD: Makefile.inc,v 1.1 1996/09/30 16:34:59 ws Exp $
3
4.if !defined(__stand_makefile_inc)
5__stand_makefile_inc=1
6
7KERN_AS=	library
8
9S=$(.CURDIR)/../../../$(R)
10
11.if !make(libdep) && !make(sadep) && !make(salibdir) && !make(obj) && !defined(NOMACHINE)
12.BEGIN:
13	@([ -h machine ] || ln -s $(S)/arch/$(MACHINE)/include machine)
14.endif
15
16#
17EXTRACFLAGS=	-msoft-float
18REAL_VIRT?=	-v
19ENTRY?=	_start
20
21INCLUDES+=	-I. -I$(.OBJDIR) -I$(.CURDIR)/.. -I$(S)/arch -I$(S)
22INCLUDES+=	-I$(S)/lib/libsa
23DEFS+=		-DSTANDALONE
24CFLAGS+=	$(INCLUDES) $(DEFS) $(EXTRACFLAGS)
25CFLAGS+=	-fno-stack-protector
26CFLAGS+=	-fno-builtin -fno-pie
27AFLAGS+=	-fno-pie
28LDFLAGS?=	-X -N -Ttext $(RELOC) -e $(ENTRY)
29
30cleandir:
31	rm -rf lib machine
32
33.endif
34