Use genassym.sh script to make assym.h, for cross-compiling.
Remove dependencies on genassym.
This commit is contained in:
parent
d27d7804f7
commit
ab9bbd64d6
71
sys/arch/mips/mips/genassym.cf
Normal file
71
sys/arch/mips/mips/genassym.cf
Normal file
@ -0,0 +1,71 @@
|
||||
|
||||
#
|
||||
# Copyright (c) 1997
|
||||
# Jonathan Stone. All rights reserved.
|
||||
# Copyright (c) 1992, 1993
|
||||
# The Regents of the University of California. All rights reserved.
|
||||
#
|
||||
# This code is derived from software contributed to Berkeley by
|
||||
# Ralph Campbell.
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions
|
||||
# are met:
|
||||
# 1. Redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer.
|
||||
# 2. Redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in the
|
||||
# documentation and/or other materials provided with the distribution.
|
||||
# 3. All advertising materials mentioning features or use of this software
|
||||
# must display the following acknowledgement:
|
||||
# This product includes software developed by the University of
|
||||
# California, Berkeley and its contributors.
|
||||
# 4. Neither the name of the University nor the names of its contributors
|
||||
# may be used to endorse or promote products derived from this software
|
||||
# without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
|
||||
# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
||||
# ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
|
||||
# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
||||
# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
||||
# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
||||
# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
||||
# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
# SUCH DAMAGE.
|
||||
#
|
||||
# @(#)genassym.c 8.2 (Berkeley) 9/23/93
|
||||
#
|
||||
|
||||
include <sys/param.h>
|
||||
include <sys/buf.h>
|
||||
include <sys/map.h>
|
||||
include <sys/proc.h>
|
||||
include <sys/mbuf.h>
|
||||
include <sys/user.h>
|
||||
|
||||
include <machine/reg.h>
|
||||
|
||||
|
||||
define P_FORW offsetof(struct proc, p_forw)
|
||||
define P_BACK offsetof(struct proc, p_back)
|
||||
define P_PRIORITY offsetof(struct proc, p_priority)
|
||||
define P_ADDR offsetof(struct proc, p_addr)
|
||||
|
||||
define P_UPTE offsetof(struct proc, p_md.md_upte)
|
||||
define U_PCB_REGS offsetof(struct user, u_pcb.pcb_regs)
|
||||
|
||||
define U_PCB_FPREGS offsetof(struct user, u_pcb.pcb_regs[F0])
|
||||
define U_PCB_CONTEXT offsetof(struct user, u_pcb.pcb_context)
|
||||
define U_PCB_ONFAULT offsetof(struct user, u_pcb.pcb_onfault)
|
||||
define U_PCB_SEGTAB offsetof(struct user, u_pcb.pcb_segtab)
|
||||
|
||||
define VM_MIN_ADDRESS VM_MIN_ADDRESS
|
||||
define VM_MIN_KERNEL_ADDRESS VM_MIN_KERNEL_ADDRESS
|
||||
|
||||
define V_SWTCH offsetof(struct vmmeter, v_swtch)
|
||||
|
||||
define SIGILL SIGILL
|
||||
define SIGFPE SIGFPE
|
@ -1,4 +1,4 @@
|
||||
# $NetBSD: Makefile.pmax,v 1.43 1997/03/05 04:41:57 jonathan Exp $
|
||||
# $NetBSD: Makefile.pmax,v 1.44 1997/03/16 11:54:03 jonathan Exp $
|
||||
|
||||
# Makefile for NetBSD
|
||||
#
|
||||
@ -45,9 +45,6 @@ AFLAGS= -x assembler-with-cpp -traditional-cpp -D_LOCORE
|
||||
LINKFLAGS= -N -Ttext 80030000 -e start
|
||||
STRIPFLAGS= -d
|
||||
|
||||
HOSTED_CC= ${CC}
|
||||
HOSTED_CPPFLAGS=${CPPFLAGS:S/^-nostdinc$//}
|
||||
HOSTED_CFLAGS= ${CFLAGS:S/-mno-abicalls//:S/-mno-half-pic//}
|
||||
|
||||
### find out what to use for libkern
|
||||
.include "$S/lib/libkern/Makefile.inc"
|
||||
@ -71,8 +68,6 @@ LIBCOMPAT= ${COMPATLIB_PROF}
|
||||
NORMAL_C= ${CC} ${CFLAGS} ${CPPFLAGS} ${PROF} -c $<
|
||||
NORMAL_S= ${CC} ${AFLAGS} ${CPPFLAGS} -c $<
|
||||
|
||||
HOSTED_C= ${HOSTED_CC} ${HOSTED_CFLAGS} ${HOSTED_CPPFLAGS} -c $<
|
||||
|
||||
%OBJS
|
||||
|
||||
%CFILES
|
||||
@ -109,14 +104,11 @@ SYSTEM_LD_TAIL+=;\
|
||||
|
||||
%LOAD
|
||||
|
||||
assym.h: genassym
|
||||
./genassym >assym.h
|
||||
assym.h: $S/kern/genassym.sh ${MIPS}/mips/genassym.cf
|
||||
sh $S/kern/genassym.sh ${CC} ${CFLAGS} ${CPPFLAGS} ${PROF} \
|
||||
< ${MIPS}/mips/genassym.cf > assym.h.tmp && \
|
||||
mv -f assym.h.tmp assym.h
|
||||
|
||||
genassym: genassym.o
|
||||
${CC} -o $@ genassym.o
|
||||
|
||||
genassym.o: $S/arch/mips/mips/genassym.c
|
||||
${HOSTED_C}
|
||||
|
||||
param.c: $S/conf/param.c
|
||||
rm -f param.c
|
||||
@ -136,7 +128,7 @@ newvers: ${SYSTEM_DEP} ${SYSTEM_SWAP_DEP}
|
||||
clean: cleankernel
|
||||
cleankernel:
|
||||
rm -f eddep *netbsd netbsd.gdb tags *.[io] [a-z]*.s \
|
||||
[Ee]rrs linterrs makelinks genassym genassym.o assym.h
|
||||
[Ee]rrs linterrs makelinks assym.h.tmp assym.h
|
||||
|
||||
lint:
|
||||
@lint -hbxncez -Dvolatile= ${CPPFLAGS} -UKGDB \
|
||||
@ -164,8 +156,6 @@ depend: .depend
|
||||
${MKDEP} ${AFLAGS} ${CPPFLAGS} ${PMAX}/pmax/locore_machdep.S
|
||||
${MKDEP} -a ${CFLAGS} ${CPPFLAGS} param.c ioconf.c ${CFILES}
|
||||
${MKDEP} -a ${AFLAGS} ${CPPFLAGS} ${SFILES}
|
||||
${MKDEP} -a ${HOSTED_CFLAGS} ${HOSTED_CPPFLAGS} \
|
||||
$S/arch/mips/mips/genassym.c
|
||||
|
||||
|
||||
# depend on root or device configuration
|
||||
@ -175,7 +165,7 @@ autoconf.o conf.o: Makefile
|
||||
uipc_proto.o vfs_conf.o: Makefile
|
||||
|
||||
# depend on maxusers
|
||||
genassym.o machdep.o: Makefile
|
||||
machdep.o: Makefile
|
||||
|
||||
# depend on CPU configuration
|
||||
machdep.o mainbus.o trap.o: Makefile
|
||||
|
Loading…
x
Reference in New Issue
Block a user