Home | History | Annotate | Line # | Download | only in prekern
Makefile revision 1.1
      1 #	$NetBSD: Makefile,v 1.1 2017/10/10 09:29:14 maxv Exp $
      2 
      3 PROG=		prekern
      4 SRCS=	locore.S trap.S prekern.c mm.c console.c elf.c
      5 
      6 NOSSP=		# defined
      7 NOPIE=		# defined
      8 NOMAN=		1
      9 
     10 S=	${.CURDIR}/../../../..
     11 
     12 .PATH: ${.CURDIR}
     13 
     14 BINDIR=		/usr/mdec
     15 BINMODE=	444
     16 
     17 .include <bsd.own.mk>
     18 
     19 CPPFLAGS+=	-I. -I${S}
     20 
     21 .include <bsd.klinks.mk>
     22 
     23 CPPFLAGS+=	-DKERNEL -D__x86_64__
     24 CFLAGS+=	-Wall -Werror -mno-red-zone -mno-mmx -mno-sse -mno-avx -ffreestanding
     25 STRIPFLAG=
     26 LINKFLAGS=	-X -z max-page-size=0x100000 -Ttext 0x100000 -T prekern.ldscript
     27 
     28 LIBCRT0=	# nothing
     29 LIBCRTI=	# nothing
     30 LIBC=		# nothing
     31 LIBCRTBEGIN=	# nothing
     32 LIBCRTEND=	# nothing
     33 
     34 ${PROG}: ${OBJS}
     35 	${LD} ${LINKFLAGS} -o ${.TARGET} ${OBJS}
     36 
     37 all:	${PROG}
     38 
     39 .include <bsd.prog.mk>
     40 
     41