Makefile.i386 revision 1.135
11.135Sthorpej# $NetBSD: Makefile.i386,v 1.135 2004/06/04 04:45:50 thorpej Exp $ 21.62Smycroft 31.8Scgd# Makefile for NetBSD 41.1Scgd# 51.1Scgd# This makefile is constructed from a machine description: 61.1Scgd# config machineid 71.1Scgd# Most changes should be made in the machine description 81.36Sderaadt# /sys/arch/i386/conf/``machineid'' 91.1Scgd# after which you should do 101.62Smycroft# config machineid 111.62Smycroft# Machine generic makefile changes should be made in 121.36Sderaadt# /sys/arch/i386/conf/Makefile.i386 131.42Smycroft# after which config should be rerun for all machines of that type. 141.119Satatat# 151.120Slukem# To specify debugging, add the config line: makeoptions DEBUG="-g" 161.119Satatat# A better way is to specify -g only for a few files. 171.119Satatat# 181.119Satatat# makeoptions DEBUGLIST="uvm* trap if_*" 191.117Sthorpej 201.119SatatatMACHINE_ARCH= i386 211.118SjmcUSETOOLS?= no 221.119SatatatNEED_OWN_INSTALL_TARGET?=no 231.119Satatat.include <bsd.own.mk> 241.42Smycroft 251.119Satatat## 261.119Satatat## (1) port identification 271.119Satatat## 281.119SatatatI386= $S/arch/i386 291.119SatatatGENASSYM= ${I386}/i386/genassym.cf 301.119Satatat 311.119Satatat## 321.119Satatat## (2) compile settings 331.119Satatat## 341.121SatatatCPPFLAGS+= -Di386 351.121SatatatAFLAGS+= -x assembler-with-cpp -traditional-cpp 361.97Schristos 371.119Satatat## 381.120Slukem## (3) libkern and compat 391.119Satatat## 401.119SatatatKERN_AS= obj 411.62Smycroft 421.119Satatat## 431.119Satatat## (4) local objects, compile rules, and dependencies 441.119Satatat## 451.129SchristosMD_OBJS= locore.o spl.o vector.o microtime.o 461.119SatatatMD_CFILES= 471.131SyamtMD_SFILES= ${I386}/i386/locore.S ${I386}/i386/spl.S \ 481.131Syamt ${I386}/i386/vector.S ${I386}/i386/microtime.S 491.1Scgd 501.125Sfvdllocore.o: ${I386}/i386/locore.S assym.h 511.125Sfvdl ${NORMAL_S} 521.125Sfvdl 531.125Sfvdlspl.o: ${I386}/i386/spl.S assym.h 541.125Sfvdl ${NORMAL_S} 551.125Sfvdl 561.125Sfvdlvector.o: ${I386}/i386/vector.S assym.h 571.129Schristos ${NORMAL_S} 581.129Schristos 591.129Schristosmicrotime.o: ${I386}/i386/microtime.S assym.h 601.119Satatat ${NORMAL_S} 611.116Sthorpej 621.119Satatat## 631.119Satatat## (5) link settings 641.119Satatat## 651.116SthorpejTEXTADDR?= c0100000 661.122SatatatLINKFLAGS_NORMAL= -X 671.97Schristos.if (${OBJECT_FMT} == "ELF") 681.111SthorpejKERN_LDSCRIPT?= kern.ldscript 691.119SatatatLINKFORMAT= -T ${I386}/conf/${KERN_LDSCRIPT} 701.97Schristos.else 711.119SatatatLINKFORMAT= -z 721.107Sthorpej.endif 731.107Sthorpej 741.119Satatat## 751.119Satatat## (6) port specific target dependencies 761.119Satatat## 771.98Smrg 781.126Schristosfreebsd_sigcode.o ibcs2_sigcode.o linux_sigcode.o: assym.h 791.126Schristossvr4_sigcode.o mach_sigcode.o: assym.h 801.130Schristosapmcall.o in_cksum.o pnpbioscall.o bioscall.o: assym.h 811.132Ssimonbmptramp.o: assym.h 821.128Schristosclock.o: config_time.h 831.119Satatat 841.119Satatat## 851.119Satatat## (7) misc settings 861.119Satatat## 871.119Satatat 881.119Satatat## 891.119Satatat## (8) config(8) generated machinery 901.119Satatat## 911.98Smrg%INCLUDES 921.74Smycroft 931.1Scgd%OBJS 941.1Scgd 951.1Scgd%CFILES 961.1Scgd 971.62Smycroft%SFILES 981.62Smycroft 991.1Scgd%LOAD 1001.50Smycroft 1011.119Satatat%RULES 1021.1Scgd 1031.133Sjmc# XXX - Ugly, but make doesn't easily handle .o.uue (assumes it's a suffix) 1041.133Sjmc# XXX - Also, config has no simple was to just add foo.o to the Makefile. 1051.133Sjmc# It needs a pathname of some sort for "object" 1061.133Sjmc.if !empty(OBJS:M\/athhal-elf.o) 1071.133SjmcOBJS:=${OBJS:C/\/athhal-elf.o/athhal-elf.o/} 1081.133Sjmc 1091.133SjmcUUDECODE_FILES=athhal-elf-o 1101.133SjmcUUDECODE_FILES_RENAME_athhal-elf-o=athhal-elf.o 1111.133Sjmc 1121.133Sjmcathhal-elf.o: athhal-elf-o 1131.133Sjmc 1141.134SheEXTRA_CLEAN+= athhal-elf-o 1151.134She 1161.133Sjmc.PATH: $S/../contrib/sys/arch/i386/dev 1171.133Sjmc 1181.133Sjmc.include <bsd.files.mk> 1191.133Sjmc.endif 1201.133Sjmc 1211.119Satatat## 1221.119Satatat## (9) port independent kernel machinery 1231.119Satatat## 1241.119Satatat.include "$S/conf/Makefile.kern.inc" 1251.135Sthorpej 1261.135Sthorpej## 1271.135Sthorpej## (10) Appending make options. 1281.135Sthorpej## 1291.135Sthorpej%MAKEOPTIONSAPPEND 130