Fix the way this checks the object files so it works correctly with make -j
This commit is contained in:
parent
f9bdf3cd08
commit
355c871f88
|
@ -1,4 +1,4 @@
|
||||||
# $NetBSD: Makefile,v 1.3 2004/11/07 21:58:45 christos Exp $
|
# $NetBSD: Makefile,v 1.4 2004/11/29 15:19:26 jmc Exp $
|
||||||
|
|
||||||
PROG= xxboot
|
PROG= xxboot
|
||||||
SRCS= start.S main.c readufs.c readufs_ffs.c readufs_lfs.c milli_tiny.S
|
SRCS= start.S main.c readufs.c readufs_ffs.c readufs_lfs.c milli_tiny.S
|
||||||
|
@ -26,7 +26,7 @@ LIBCRT0=
|
||||||
LIBCRTEND=
|
LIBCRTEND=
|
||||||
LIBC=
|
LIBC=
|
||||||
|
|
||||||
${PROG}: iplsum
|
${PROG}: iplsum ${OBJS}
|
||||||
${LD} -Ttext 0 -Tdata 0 -e '$$START$$' -N -o $@1 $(OBJS)
|
${LD} -Ttext 0 -Tdata 0 -e '$$START$$' -N -o $@1 $(OBJS)
|
||||||
${LD} -Ttext 0x100 -Tdata 0x23456780 -e '$$START$$' -N -o $@2 $(OBJS)
|
${LD} -Ttext 0x100 -Tdata 0x23456780 -e '$$START$$' -N -o $@2 $(OBJS)
|
||||||
${SIZE} $@1
|
${SIZE} $@1
|
||||||
|
@ -58,6 +58,8 @@ CLEANFILES+= ${SRCS:M*.c:S/.c$/.o.S/}
|
||||||
# are relative to $global$.
|
# are relative to $global$.
|
||||||
.c.o:
|
.c.o:
|
||||||
${CC} ${CFLAGS} ${CPPFLAGS} -o $@.S -S ${.IMPSRC}
|
${CC} ${CFLAGS} ${CPPFLAGS} -o $@.S -S ${.IMPSRC}
|
||||||
@grep -i 'ldil' $@.S | egrep -v "ldil L'-?[0-9]*," || exit 0; \
|
grep -i 'ldil' $@.S | egrep -v "ldil L'-?[0-9]*," > /dev/null 2>&1; \
|
||||||
echo 'found non-relocatable code' >&2; exit 1
|
if [ $$? = 0 ]; then \
|
||||||
|
echo 'found non-relocatable code' >&2 && exit 1; \
|
||||||
|
fi
|
||||||
sed -e 's/\.text/.data/' $@.S | ${AS} -o ${.TARGET}
|
sed -e 's/\.text/.data/' $@.S | ${AS} -o ${.TARGET}
|
||||||
|
|
Loading…
Reference in New Issue