view bootmatch/Makefile @ 24:b71216a5f3c3

doc/C1xx-flashing: proofreading fixes
author Mychaela Falconia <falcon@freecalypso.org>
date Sun, 11 Jun 2023 19:11:47 +0000
parents 39b921d851fb
children
line wrap: on
line source

CC=	gcc
CFLAGS=	-O2
BMC_PROG=bm-comp
BMC_OBJS=comp_main.o comp_output.o comp_ranges.o comp_readbin.o
OUTPUTS=c11x_lockable.c c11x_nolock.c c139_lockable.c c139_nolock.c \
	c155_boot.c fc_patched_boot.c

C11XNEW_BIN=	../bootref/c11x-lockable.bin
C11XNEW_RNG=	../bootref/c11x-lockable.ranges
C11XOLD_BIN=	../bootref/c11x-nolock.bin
C11XOLD_RNG=	../bootref/c11x-nolock.ranges
C139NEW_BIN=	../bootref/c139-lockable.bin
C139NEW_RNG=	../bootref/c139-lockable.ranges
C139OLD_BIN=	../bootref/c139-nolock.bin
C139OLD_RNG=	../bootref/c139-nolock.ranges
C155BOOT_BIN=	../bootref/c156-boot.bin
C155BOOT_RNG=	../bootref/c156-boot.ranges
FCPATCH_BIN=	../target-bin/compal-flash-boot-for-fc.bin

all:	${BMC_PROG} ${OUTPUTS}

${BMC_PROG}:	${BMC_OBJS}
	${CC} ${CFLAGS} -o $@ ${BMC_OBJS}

c11x_lockable.c:	${BMC_PROG} ${C11XNEW_BIN} ${C11XNEW_RNG}
	./${BMC_PROG} ${C11XNEW_BIN} ${C11XNEW_RNG} bootmatch_c11x_lockable $@

c11x_nolock.c:		${BMC_PROG} ${C11XOLD_BIN} ${C11XOLD_RNG}
	./${BMC_PROG} ${C11XOLD_BIN} ${C11XOLD_RNG} bootmatch_c11x_nolock $@

c139_lockable.c:	${BMC_PROG} ${C139NEW_BIN} ${C139NEW_RNG}
	./${BMC_PROG} ${C139NEW_BIN} ${C139NEW_RNG} bootmatch_c139_lockable $@

c139_nolock.c:		${BMC_PROG} ${C139OLD_BIN} ${C139OLD_RNG}
	./${BMC_PROG} ${C139OLD_BIN} ${C139OLD_RNG} bootmatch_c139_nolock $@

c155_boot.c:		${BMC_PROG} ${C155BOOT_BIN} ${C155BOOT_RNG}
	./${BMC_PROG} ${C155BOOT_BIN} ${C155BOOT_RNG} bootmatch_c155 $@

fc_patched_boot.c:	${BMC_PROG} ${FCPATCH_BIN} ${C11XOLD_RNG}
	./${BMC_PROG} ${FCPATCH_BIN} ${C11XOLD_RNG} bootmatch_fc_patch $@

clean:
	rm -f *.o ${BMC_PROG} ${OUTPUTS}