|
|
1.1 ! root 1: ! 2: # If you want or need to change something herein, please look approx. 30 lines ! 3: # below for the 'User Config Section' ! 4: ! 5: ######################################################################## ! 6: # The next lines are hacks for automatic detection of different kernel setups. ! 7: # These things must happen first, please don't change them here. They can be ! 8: # overridden later. ! 9: # ! 10: # we try to guess some settings from kernel configuration :) ! 11: -include /usr/src/linux/.config ! 12: # ! 13: # guess some special flags for CPU type - used for optimization only ! 14: CPUFLAGS= ! 15: ifeq ($(CONFIG_M386),y) ! 16: CPUFLAGS= -m386 -DCPU=386 -DUSE_ASM ! 17: endif ! 18: ifeq ($(CONFIG_M486),y) ! 19: CPUFLAGS= -m486 -DCPU=486 -DUSE_ASM ! 20: endif ! 21: ifeq ($(CONFIG_M586),y) ! 22: CPUFLAGS= -m486 -DCPU=586 -DUSE_ASM ! 23: endif ! 24: ifeq ($(CONFIG_M686),y) ! 25: CPUFLAGS= -m486 -DCPU=686 -DUSE_ASM ! 26: endif ! 27: # ! 28: # Okay, that's it :) ! 29: ######################################################################## ! 30: ! 31: ######################################################################## ! 32: # *** User Config Section *** ! 33: # Here you can look for settings to change if the code refuses to compile ! 34: # out of the box. There are so many different systems. So many versions ! 35: # of compilers. So many different bugs. :( ! 36: # ! 37: # Select compiler ! 38: CC=gcc ! 39: # ! 40: # If cpu specific optimization fails, uncomment the next line to switch it ! 41: # off - there are some gas versions around that don't like the cpu specific ! 42: # asm instructions in dmsdos... ! 43: # CPUFLAGS= ! 44: # ! 45: # Some gnu assembler versions have a bug in the syntax for the xlat ! 46: # instruction. This enables a workaround. It should only be needed for very ! 47: # old binutils versions. I don't know for which ones :( ! 48: # CPUFLAGS+= -DGAS_XLAT_BUG ! 49: # ! 50: # The next lines should detect SMP configuration automatically. ! 51: # Comment them out or set it manually if it fails. ! 52: ifeq ($(SMP),1) ! 53: CPUFLAGS+= -D__SMP__ ! 54: endif ! 55: # ! 56: # The next lines are for libc6 and enable some compatibility hacks - ! 57: # uncomment the line with -D__FOR_LIBC6 if the code does not compile ! 58: # *** Currently not used - code should compile under libc6 without hacks ! 59: LIBC6FLAGS= ! 60: #LIBC6FLAGS= -D__FOR_LIBC6 ! 61: # ! 62: # CFLAGS for dmsdos module ! 63: # note: some macro expansions require at least -O ! 64: CFLAGS= -Wall -Wstrict-prototypes -O3 -fomit-frame-pointer -D__KERNEL__ -DMODULE ! 65: CFLAGS+= $(CPUFLAGS) ! 66: # ! 67: # The next lines add some stuff automatically for people using modversions ! 68: # if they fail, comment them out and set the required flags manually ! 69: ifeq ($(CONFIG_MODVERSIONS),y) ! 70: CFLAGS+= -DMODVERSIONS -include /usr/include/linux/modversions.h ! 71: endif ! 72: # ! 73: # CFLAGS for the dmsdos daemon ! 74: # note: some macro expansions require at least -O ! 75: DCFLAGS= -Wall -O3 -D__DMSDOS_DAEMON__ ! 76: DCFLAGS+= $(CPUFLAGS) ! 77: # ! 78: # CFLAGS for the dmsdos library ! 79: # note: some macro expansions require at least -O ! 80: LCFLAGS= -Wall -O -ggdb -D__DMSDOS_LIB__ ! 81: LCFLAGS+= $(CPUFLAGS) $(LIBC6FLAGS) ! 82: # ! 83: # locations where to install the module, the executables and the manpages ! 84: # note: `uname -r` expands to the *currently running* kernel version - if it ! 85: # is different from that in /usr/src/linux you'd better edit the next line :) ! 86: MODULE_PREFIX=/lib/modules/`uname -r`/fs ! 87: #MODULE_PREFIX=/lib/modules/misc ! 88: EXEC_PREFIX=/usr/local/bin ! 89: MAN_PREFIX=/usr/local/man ! 90: # ! 91: # Okay, that's the end of the User Config Section. ! 92: ########################################################################## ! 93: ! 94: ########################################################################## ! 95: # The rest of this file are rules how to build which programs. ! 96: ! 97: all: dmsdos-config.h dmsdos.o dutil dmsdosd libdmsdos.a dcread dmsdosfsck ! 98: ! 99: min: dmsdos-config.h dmsdos.o dutil ! 100: ! 101: dmsdos-config.h: ! 102: /bin/bash conf-wrapper.sh ! 103: make dep ! 104: ! 105: config: ! 106: /bin/bash Configure ! 107: make dep ! 108: ! 109: menuconfig: ! 110: /bin/bash Menuconfig ! 111: make dep ! 112: ! 113: dep: ! 114: ./check.sh ! 115: $(CC) -w -E -MM -D__KERNEL__ -D__MODULE__ -DMODULE dblspace*.c dstacker*.c > depend ! 116: ! 117: depend: ! 118: @touch depend ! 119: ! 120: DBL_OBJS = dblspace_compr.o dblspace_tables.o \ ! 121: dblspace_alloc.o dblspace_dec.o dblspace_virtual.o \ ! 122: dblspace_buffer.o dblspace_methsq.o \ ! 123: dblspace_chk.o dblspace_interface.o \ ! 124: dstacker_alloc.o dstacker_compr.o dstacker_dec.o \ ! 125: dblspace_fileops.o dblspace_ioctl.o ! 126: ! 127: $(DBL_OBJS): dmsdos.h dmsdos-config.h ! 128: ! 129: dmsdos.o: $(DBL_OBJS) ! 130: ld -r -o dmsdos.o $(DBL_OBJS) ! 131: ! 132: dutil: dutil.c dmsdos.h dmsdos-config.h ! 133: $(CC) $(DCFLAGS) -o dutil dutil.c ! 134: ! 135: DAEMON_OBJS = daemon_actions.do dblspace_compr.do dstacker_compr.do \ ! 136: dblspace_methsq.do ! 137: ! 138: $(DAEMON_OBJS): dmsdos.h dmsdos-config.h ! 139: ! 140: %.do: %.c ; $(CC) -o $@ $(DCFLAGS) -c $< ! 141: ! 142: dmsdosd: $(DAEMON_OBJS) ! 143: $(CC) -o dmsdosd $^ ! 144: ! 145: clean: ! 146: rm -f *.o *.a *.i *.s *.lo *.do *.so dutil dmsdosd dcread dmsdosfsck cvftest ! 147: ! 148: mrproper: clean ! 149: rm -f core *~ depend ! 150: rm -f .config* dmsdos-config.h .menuconfig* ! 151: ! 152: install: all ! 153: ./check.sh ! 154: install dmsdos.o -m 644 $(MODULE_PREFIX)/dmsdos.o ! 155: install dutil $(EXEC_PREFIX)/dutil ! 156: install dmsdosd $(EXEC_PREFIX)/dmsdosd ! 157: install dmsdosfsck $(EXEC_PREFIX)/dmsdosfsck ! 158: install dutil.1 -m 644 $(MAN_PREFIX)/man1/dutil.1 ! 159: install dmsdosd.1 -m 644 $(MAN_PREFIX)/man1/dmsdosd.1 ! 160: install dmsdosfsck.8 -m 644 $(MAN_PREFIX)/man8/dmsdosfsck.8 ! 161: ! 162: install-min: min ! 163: ./check.sh ! 164: install dmsdos.o $(MODULE_PREFIX)/dmsdos.o ! 165: install dutil $(EXEC_PREFIX)/dutil ! 166: install dutil.1 -m 644 $(MAN_PREFIX)/man1/dutil.1 ! 167: ! 168: uninstall: ! 169: rm -f $(MODULE_PREFIX)/dmsdos.o ! 170: rm -f $(EXEC_PREFIX)/dutil ! 171: rm -f $(EXEC_PREFIX)/dmsdosd ! 172: rm -f $(EXEC_PREFIX)/dmsdosfsck ! 173: rm -f $(MAN_PREFIX)/man1/dutil.1 ! 174: rm -f $(MAN_PREFIX)/man1/dmsdosd.1 ! 175: rm -f $(MAN_PREFIX)/man8/dmsdosfsck.8 ! 176: ! 177: messages: ! 178: grep DMSDOS ../doc/messages.doc | sort -d -b -f > /tmp/messdoc ! 179: ./listmsg.sh -LOG > /tmp/messsrc ! 180: diff -d -U 0 -w /tmp/messdoc /tmp/messsrc | grep DMSDOS ! 181: ! 182: LIB_OBJS = lib_interface.lo dblspace_interface.lo dblspace_dec.lo \ ! 183: dblspace_compr.lo dblspace_methsq.lo dblspace_alloc.lo \ ! 184: dblspace_chk.lo dblspace_tables.lo dstacker_compr.lo \ ! 185: dstacker_dec.lo dstacker_alloc.lo ! 186: ! 187: $(LIB_OBJS): dmsdos.h dmsdos-config.h lib_interface.h ! 188: ! 189: %.lo: %.c ; $(CC) -o $@ $(LCFLAGS) -c $< ! 190: ! 191: dmsdos_library.lo: $(LIB_OBJS) ! 192: ld -r -o dmsdos_library.lo $^ ! 193: ! 194: libdmsdos.a: dmsdos_library.lo ! 195: ar rcs libdmsdos.a dmsdos_library.lo ! 196: ! 197: libdmsdos.so: dmsdos_library.lo ! 198: ld -shared -o libdmsdos.so dmsdos_library.lo ! 199: ! 200: dcread: dcread.c libdmsdos.a dmsdos.h dmsdos-config.h ! 201: $(CC) -Wall -ggdb -o dcread dcread.c -L. -ldmsdos ! 202: ! 203: dmsdosfsck: dmsdosfsck.c libdmsdos.a dmsdos.h dmsdos-config.h ! 204: $(CC) -Wall -o dmsdosfsck dmsdosfsck.c -L. -ldmsdos ! 205: ! 206: cvftest: cvftest.c ! 207: @echo "WARNING: Using cvftest is discouraged. Use file(1) instead." ! 208: $(CC) -Wall -o cvftest cvftest.c ! 209: ! 210: -include depend
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.