📄 makefile
字号:
# Makefile for MemTest-86## Author: Chris Brady# Created: January 1, 1996## Path for the floppy disk device#FDISK=/dev/fd0CC=gcc## gcc compiler options, these settings should suffice#CCFLAGS=-Wall -m32 -march=i486 -Os -fomit-frame-pointer -fno-builtin -ffreestandingAS=as -32OBJS= head.o reloc.o main.o test.o init.o lib.o patn.o screen_buffer.o config.o linuxbios.o memsize.o pci.o controller.o extra.o random.o dmi.oall: memtest.bin memtestreloc.o: reloc.c $(CC) -c -m32 -march=i486 -fPIC -Wall -g -O2 -fno-strict-aliasing reloc.ctest.o: test.c test.h defs.h config.h $(CC) -c $(CCFLAGS) test.cmain.o: main.c test.h defs.h $(CC) -c $(CCFLAGS) -fPIC main.cinit.o: init.c test.h defs.h io.h config.h controller.h pci.h $(CC) -c $(CCFLAGS) -fPIC init.clinuxbios.o: linuxbios.c test.h linuxbios_tables.h defs.h config.h $(CC) -c $(CCFLAGS) -fPIC linuxbios.cmemsize.o: memsize.c test.h defs.h config.h $(CC) -c $(CCFLAGS) -fPIC memsize.clib.o: lib.c test.h defs.h io.h screen_buffer.h serial.h config.h $(CC) -c $(CCFLAGS) -fPIC lib.cscreen_buffer.o: screen_buffer.c screen_buffer.h test.h config.h $(CC) -c $(CCFLAGS) -fPIC screen_buffer.crandom.o: random.c $(CC) -c $(CCFLAGS) -fPIC random.cpatn.o: patn.c $(CC) -c $(CCFLAGS) -fPIC patn.cconfig.o: config.c test.h controller.h screen_buffer.h $(CC) -c $(CCFLAGS) -fPIC config.cpci.o: pci.c pci.h io.h $(CC) -c $(CCFLAGS) -fPIC pci.ccontroller.o: controller.c defs.h config.h test.h pci.h controller.h $(CC) -c $(CCFLAGS) -fPIC controller.cextra.o: config.c test.h screen_buffer.h extra.h $(CC) -c $(CCFLAGS) -fPIC extra.ccontroller.s: controller.c defs.h config.h test.h pci.h controller.h $(CC) -S $(CCFLAGS) -fPIC controller.chead.s: head.S $(CC) -E -m32 -traditional $< -o $@head.o: head.s $(AS) -o $@ $<dmi.o: dmi.c test.h $(CC) -c $(CCFLAGS) -fPIC dmi.cmakedefs: makedefs.c defs.h $(CC) $(CCFLAGS) makedefs.c -o $@# Link it statically once so I know I don't have undefined# symbols and then link it dynamically so I have full# relocation informationmemtest_shared: $(OBJS) memtest_shared.lds Makefile $(LD) --warn-constructors --warn-common -static -T memtest_shared.lds -o $@ $(OBJS) && \ $(LD) -shared -Bsymbolic -T memtest_shared.lds -o $@ $(OBJS)memtest_shared.bin: memtest_shared objcopy -O binary $< memtest_shared.binmemtest: memtest_shared.bin memtest.lds $(LD) -s -T memtest.lds -b binary memtest_shared.bin -o $@bootsect.s: bootsect.S defs.h $(CC) -E -traditional $< -o $@bootsect.o: bootsect.s $(AS) -o $@ $<bootsect: bootsect.o $(LD) -Ttext 0x00 -s --oformat binary -e _main --just-symbols=memtest_shared.o -o $@ $<setup.s: setup.S config.h defs.h $(CC) -E -traditional $< -o $@setup.o: setup.s $(AS) -o $@ $<memtest.bin: memtest_shared.bin bootsect.o setup.o memtest.bin.lds $(LD) -T memtest.bin.lds bootsect.o setup.o -b binary memtest_shared.bin -o memtest.binclean: rm -f *.o *.s memtest.bin bootsect setup low_mapfile high_mapfile \ memtest memtest.out makedefs defs.lds memtest_shared memtest_shared.binwormkill: rm -f *~install: all dd <memtest.bin >$(FDISK) bs=8192install-bin: dd <precomp.bin >$(FDISK) bs=8192
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -