⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 makefile.src

📁 操作系统SunOS 4.1.3版本的源码
💻 SRC
字号:
# @(#)Makefile.src 1.1 92/07/30## Makefile for Sun-3x SunOS## This makefile is constructed from a machine description:#	config machine# Most changes should be made in the machine description#	/sys/conf/``machineid''# after which you should do#	 config machineid# Generic makefile changes should be made in#	/sys/conf/Makefile.src# after which config should be rerun for all machines.## N.B.: NO DEPENDENCIES ON FOLLOWING FLAGS ARE VISIBLE TO MAKEFILE#	IF YOU CHANGE THE DEFINITION OF ANY OF THESE RECOMPILE EVERYTHING## -DTRACE	compile in kernel tracing hooks# -DQUOTA	compile in file system quotas#ARCH= 	sun3xCPP=	/lib/cpp -undef -Dmc68000 -Dmc68020 -DsunCC=	cc -fsoftAS=	as -m68020LD=	ldAWK=	awkGREP=	egrepDESTDIR=SYSDIR=	../..CONFDIR=../../conf.commonMACHINE= ..LDIR=	/usr/lib/lintLINT1=	${LDIR}/lint1LINT2=	${LDIR}/lint2LCOPTS=	-C -Dlint ${CPPOPTS}LOPTS=	-hbxnLTMP=	/usr/tmp/lint.kernelLTAIL=	${GREP} -v 'struct/union .* never defined' | \	${GREP} -v 'possible pointer alignment problem' ; trueCPPOPTS=${IDENT} -DKERNEL -I. -I${MACHINE} -I${SYSDIR}COPTS=	${CPPOPTS}CFLAGS=	-O ${COPTS}%OBJS%CONFFILES%CFILES%SFILES%LFILES%LOADinstall: $(INSTALLFILES)	install -d -o bin -m 755 ${DESTDIR}/usr/kvm/stand	install -m 0755 $(INSTALLFILES) ${DESTDIR}/usr/kvm/standclean:	$(RM) eddep $(INSTALLFILES) *.o *.pp *.L *errs makedep* makelinks	@set -x; if ls *.s | ${GREP} -v mbglue.s; then \	    $(RM) `ls *.s | ${GREP} -v mbglue.s`; filint: Locore.L ${LFILES}	@make lint2 LTMP=${LTMP}.$$$$lint2:	@cat Locore.L ${LFILES} > ${LTMP}	@echo "Global Cross-checks:"	@${LINT2} ${LTMP} ${LOPTS}	@-rm -f ${LTMP}${SYSDIR}/sun/symbols.sort: ${SYSDIR}/sun/symbols.raw	${GREP} -v '^#' ${SYSDIR}/sun/symbols.raw \	    | sed 's/^	//' | sort -u > ${SYSDIR}/sun/symbols.sortvers.o: ${CONFDIR}/newvers.sh ${CONFDIR}/RELEASE	@sh ${CONFDIR}/newvers.sh ${CONFDIR}/RELEASE  ${ARCH}	@${CC} ${CFLAGS} -c vers.c# the following is necessary because files depend on #if GENERICautoconf.o stubs.o : Makefile# the following are necessary because the files depend on the types of# sun cpu's included in the system configurationmachdep.o autoconf.o conf.o : Makefile# depend on network configurationaf.o uipc_proto.o : Makefile# depend on optionsinit_sysent.o vfs_conf.o : Makefile# depend on SystemV IPC optionsinit_main.o kern_exit.o kern_fork.o : Makefiledepend: makedep	echo '/^# DO NOT DELETE THIS LINE/+1,$$d' >eddep	echo '$$r makedep' >>eddep	echo 'w' >>eddep	cp Makefile Makefile.bak	ex - Makefile < eddep	rm eddep makedep makedep1 makedeperrsmakedep: ${CONFFILES} assym.s ${MACHINE}/Locore.c syssrc FRC	@cat /dev/null >makedep	-(for i in ${CFILES} ${SFILES} ${ARCH}/genassym.c ; do \		${CPP} -M ${CPPOPTS} ${SYSDIR}/$$i >> makedep; done) \		2>makedeperrs	sed \		-e 's,^.*genassym\.o:,assym.s assym.L:,' \		-e 's,^\(.*\)\.o:,\1.o \1.L:,' makedep > makedep1	-(for i in ${CONFFILES} ; do \		${CPP} -M ${CPPOPTS} $$i | sed \		-e 's,^\(.*\)\.o:,\1.o \1.L:,' >>makedep1; done) \		2>>makedeperrs	-(for i in ${MACHINE}/Locore.c ; do \		${CPP} -M -Dlint ${CPPOPTS} $$i | sed \		-e 's,^\(.*\)\.o:,\1.o \1.L:,' >>makedep1; done) \		2>>makedeperrs	${AWK} ' { if ($$1 != prev) { print rec; rec = $$0; prev = $$1; } \		else { if (length(rec $$3) > 78) { print rec; rec = $$0; } \		       else rec = rec " " $$3 } } \	      END { print rec } ' makedep1 > makedep	@cat makedeperrs >&- 1>&2	@(if [ -s makedeperrs ]; then false; fi)FRC:syssrc:	here=`pwd`; cd ${SYSDIR}; make -f $$here/Makefile dosyssrc## dosyssrc, made from the SYSDIR directory, ensures the latest sourcedosyssrc: ${CFILES} ${SFILES}links:	( cd ${SYSDIR}; ${GREP} '#if' ${CFILES} ) | \		sed -f ${CONFDIR}/defines | \		sed -e 's/:.*//' -e 's/\.c/.o/' | sort -u > dontlink	echo ${CFILES} | tr -s ' ' '\12' | sed 's/\.c/.o/' | \	  ${GREP} -v '^swap' | sort -u | comm -23 - dontlink | \	  sed 's,.*/\(.*.o\),rm -f \1;ln -s ../GENERIC/\1 \1,' > makelinks	echo 'rm -f movc.o;ln -s ../GENERIC/movc.o movc.o' >>makelinks	echo 'rm -f ocsum.o;ln -s ../GENERIC/ocsum.o ocsum.o' >>makelinks	echo 'rm -f setjmp.o;ln -s ../GENERIC/setjmp.o setjmp.o' >>makelinks	sh makelinks && rm -f dontlinktags: ../tags	@(cd ..; echo tags file is in `pwd`)# 1. Using ctags, build tags file for *.[ch]# 2. Grep thru *.s for files containing 'ENTRY(' or 'ENTRY2('# 3. Convert *ENTRY(sym) to a tags reference# 4. Convert ENTRY2(sym1,sym2) to two tags references# 5. Merge with tags file and resort../tags: ../tags.list	(cd ..; ctags -wt `$(GREP) -v '\.[sS]$$' tags.list`;		\	 $(GREP) 'ENTRY2*\(' `$(GREP) '\.[sS]$$' tags.list` | sed	\    -e 's|^\(.*\):\(.*ENTRY(\)\(.*\)\().*\)|\3	\1	/^\2\3\4$$/|'	\    -e 's|^\(.*\):\(.*ENTRY2(\)\(.*\),\(.*\)\().*\)|\3	\1	/^\2\3,\4\5$$/\\4	\1	/^\2\3,\4\5$$/|' >> tags;				\	 sort -u -o tags tags )# 1. Starting at the dependency list in this Makefile,# 2. remove the targets, leaving only the source names, one-per-line.# 3. Convert ../../ to ../  and  ../machine/ to ../ARCH/# 4. Convert ../ARCH/../ to ../  and remove references to Locore.c# 5. Convert ./ to ../ARCH/SYSNAME/# 6. Convert 'filename' to ../ARCH/SYSNAME/filenameSYSNAME=`basename \`pwd\``../tags.list: Makefile	@sed -e '/^[a-zA-Z0-9_]*\.o [a-zA-Z0-9_]*\.L:/,$$!d'		\	    -e 's/.*L:.//' Makefile | tr '\040' '\012' | sed		\	    -e 's,\.\./\.\./,../,' -e 's,\.\./machine/,../'${ARCH}/,	\            -e 's,\.\./machlwp,../'${ARCH}'/machlwp', 			\	    -e 's,\.\./'${ARCH}'/\.\./,../,' -e '/Locore/d'		\	    -e 's,^\./,../'${ARCH}/${SYSNAME}/,				\	    -e 's,^\([a-zA-Z0-9_]\),../'${ARCH}/${SYSNAME}'/\1,' |	\	    sort | uniq > ../tags.listassym.s: ${MACHINE}/genassym.c	${CC} -E ${CPPOPTS} ${MACHINE}/genassym.c > ./a.out.c	cc ${COPTS} ./a.out.c	./a.out >assym.s	rm -f ./a.out ./a.out.cLocore.L:	@echo Locore.c:	@-(${CPP} ${LCOPTS} ${MACHINE}/Locore.c | \	  ${LINT1} ${LOPTS} > Locore.L ) 2>&1 | ${LTAIL}mbglue.o:	${CPP} -DLOCORE ${CPPOPTS} mbglue.s >mbglue.pp	${AS} -o mbglue.o mbglue.pp	rm -f mbglue.ppioconf.o:	${CC} -c ${CFLAGS} ioconf.cioconf.L:	@echo ioconf.c:	@-(${CPP} ${LCOPTS} ioconf.c | \	  ${LINT1} ${LOPTS} > ioconf.L ) 2>&1 | ${LTAIL}param.c: ${CONFDIR}/param.c	-rm -f param.c	cp ${CONFDIR}/param.c .param.o: param.c Makefile	${CC} -c ${CFLAGS} ${PARAM} param.cparam.L:	@echo param.c:	@-(${CPP} ${LCOPTS} ${PARAM} ${CONFDIR}/param.c | \	  ${LINT1} ${LOPTS} > param.L ) 2>&1 | ${LTAIL}%RULES# DO NOT DELETE THIS LINE -- make depend uses it

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -