145f39b7b6
there are two variants of boot.atari per machine types (std or milan) and they should be selected and copied from /usr/mdec/{std,milan} dirs to /targetroot during installation. Problem on default installation with sysinst was reported by David Ross.
60 lines
1.2 KiB
Makefile
60 lines
1.2 KiB
Makefile
# $NetBSD: Makefile.bootxxx,v 1.5 2009/01/13 13:44:01 tsutsui Exp $
|
|
|
|
NOMAN= # defined
|
|
|
|
# for OBJECT_FMT
|
|
.include <bsd.own.mk>
|
|
|
|
PROG= boot.atari
|
|
|
|
STRIPFLAG=
|
|
BINMODE=${NONBINMODE}
|
|
|
|
# XXX SHOULD NOT NEED TO DEFINE THESE!
|
|
LIBCRT0=
|
|
LIBC=
|
|
LIBCRTBEGIN=
|
|
LIBCRTEND=
|
|
|
|
# logically src/sys
|
|
S=${.CURDIR}/../../../../..
|
|
S_SA=${S}/lib/libsa
|
|
S_KERN=${S}/lib/libkern
|
|
S_MACHSA=${S}/arch/atari/stand/libsa
|
|
S_LIBTOS=${S}/arch/atari/stand/tostools/libtos
|
|
|
|
S_MACHSAOBJ!= cd ${S_MACHSA} && ${PRINTOBJDIR}
|
|
|
|
LIBSA=${S_MACHSAOBJ}/libsa.a
|
|
|
|
.include "../../Makefile.booters"
|
|
.include "../../xxboot/${BTYPE}_LOADADDR"
|
|
|
|
CPPFLAGS+= -I. -I${S_LIBTOS} -I${S_MACHSA} -I${S_KERN} -I${S_SA} -I${S}
|
|
.if ${OBJECT_FMT} == "ELF"
|
|
LINKFLAGS= -static -N -e start -Ttext ${LOADADDR3}
|
|
.else
|
|
LINKFLAGS= -static -N -Ttext ${LOADADDR3}
|
|
.endif
|
|
|
|
.PATH: ${.CURDIR}/.. ${S_LIBTOS}
|
|
|
|
#
|
|
# Warning: start.S should be the first source!
|
|
#
|
|
SRCS= start.S bootxxx.c aout.c bsdstart.s elf.c filesystem.c sysinfo.c
|
|
|
|
LIBS= ${LIBSA}
|
|
|
|
beforeinstall:
|
|
${INSTALL_DIR} ${DESTDIR}${BINDIR}
|
|
|
|
${PROG}: ${OBJS} ${LIBS}
|
|
${_MKTARGET_LINK}
|
|
${LD} ${LINKFLAGS} -o ${.TARGET}.elf ${OBJS} ${LIBS}
|
|
${OBJCOPY} -O binary ${PROG}.elf ${.TARGET}
|
|
|
|
CLEANFILES+= ${PROG}.elf
|
|
|
|
.include <bsd.prog.mk>
|