From: Erik van der Kouwe Date: Tue, 16 Feb 2010 19:19:42 +0000 (+0000) Subject: Throw out obsolete Atari, Macintosh and Sun code to un-break packages; X-Git-Tag: v3.1.7~285 X-Git-Url: http://zhaoyanbai.com/repos/html/index.html?a=commitdiff_plain;h=5af2471a9a56ee7a850f5d9eb24fcfe8dab65678;p=minix.git Throw out obsolete Atari, Macintosh and Sun code to un-break packages; credits to Sernin van de Krol's zip-2.31 patch for showing this problem --- diff --git a/commands/mdb/mdb.h b/commands/mdb/mdb.h index 62cff8841..e2160d196 100644 --- a/commands/mdb/mdb.h +++ b/commands/mdb/mdb.h @@ -51,12 +51,8 @@ #if (CHIP == M68000) #define __mc68000__ /* controls processor-dependent stuff */ -#if (MACHINE == ATARI) -#define MINIX_ST /* controls system-dependent stuff */ -#else #error "only the MINIX_ST 1.5.x implementation works on 68K's" #endif -#endif #if (CHIP == INTEL) #if (MACHINE == IBM_PC) diff --git a/commands/simple/mkfs.c b/commands/simple/mkfs.c index dcac038a6..7e7dd49d4 100644 --- a/commands/simple/mkfs.c +++ b/commands/simple/mkfs.c @@ -66,10 +66,6 @@ maybedefine O_RDONLY 4 /* O_RDONLY | BINARY_BIT */ maybedefine BWRITE 5 /* O_WRONLY | BINARY_BIT */ #endif -#if (MACHINE == ATARI) -int isdev; -#endif - extern char *optarg; extern int optind; @@ -1504,17 +1500,6 @@ char *string; close(fd); fd = open(string, O_RDWR); if (fd < 0) pexit("Can't open special file"); -#if (MACHINE == ATARI) - { - struct stat statbuf; - - if (fstat(fd, &statbuf) < 0) return; - isdev = (statbuf.st_mode & S_IFMT) == S_IFCHR - || - (statbuf.st_mode & S_IFMT) == S_IFBLK - ; - } -#endif } diff --git a/commands/simple/origmkfs.c b/commands/simple/origmkfs.c index c437b6f50..7d70f7443 100644 --- a/commands/simple/origmkfs.c +++ b/commands/simple/origmkfs.c @@ -69,10 +69,6 @@ maybedefine O_RDONLY 4 /* O_RDONLY | BINARY_BIT */ maybedefine BWRITE 5 /* O_WRONLY | BINARY_BIT */ #endif -#if (MACHINE == ATARI) -int isdev; -#endif - extern char *optarg; extern int optind; @@ -297,25 +293,7 @@ char *argv[]; cache_init(); -#if (MACHINE == ATARI) - if (isdev) { - char block0[BLOCK_SIZE]; - get_block((block_t) 0, block0); - /* Need to read twice; first time gets an empty block */ - get_block((block_t) 0, block0); - /* Zero parts of the boot block so the disk won't be - * recognized as a tos disk any more. */ - block0[0] = block0[1] = 0; /* branch code to boot code */ - strncpy(&block0[2], "MINIX ", (size_t) 6); - block0[16] = 0; /* number of FATS */ - block0[17] = block0[18] = 0; /* number of dir entries */ - block0[22] = block0[23] = 0; /* sectors/FAT */ - bzero(&block0[30], 480);/* boot code */ - put_block((block_t) 0, block0); - } else -#endif - - put_block((block_t) 0, zero); /* Write a null boot block. */ + put_block((block_t) 0, zero); /* Write a null boot block. */ zone_shift = 0; /* for future use */ zones = nrblocks >> zone_shift; @@ -1306,17 +1284,6 @@ char *string; close(fd); fd = open(string, O_RDWR); if (fd < 0) pexit("Can't open special file"); -#if (MACHINE == ATARI) - { - struct stat statbuf; - - if (fstat(fd, &statbuf) < 0) return; - isdev = (statbuf.st_mode & S_IFMT) == S_IFCHR - || - (statbuf.st_mode & S_IFMT) == S_IFBLK - ; - } -#endif } diff --git a/include/minix/config.h b/include/minix/config.h index d353cb2c5..c2c53a61a 100644 --- a/include/minix/config.h +++ b/include/minix/config.h @@ -25,10 +25,6 @@ #define MACHINE _MINIX_MACHINE #define IBM_PC _MACHINE_IBM_PC -#define SUN_4 _MACHINE_SUN_4 -#define SUN_4_60 _MACHINE_SUN_4_60 -#define ATARI _MACHINE_ATARI -#define MACINTOSH _MACHINE_MACINTOSH /* Number of slots in the process table for non-kernel processes. The number * of system processes defines how many processes with special privileges diff --git a/include/minix/sys_config.h b/include/minix/sys_config.h index 05702c4bf..7505e260a 100644 --- a/include/minix/sys_config.h +++ b/include/minix/sys_config.h @@ -7,10 +7,6 @@ #define _MINIX_MACHINE _MACHINE_IBM_PC #define _MACHINE_IBM_PC 1 /* any 8088 or 80x86-based system */ -#define _MACHINE_SUN_4 40 /* any Sun SPARC-based system */ -#define _MACHINE_SUN_4_60 40 /* Sun-4/60 (aka SparcStation 1 or Campus) */ -#define _MACHINE_ATARI 60 /* ATARI ST/STe/TT (68000/68030) */ -#define _MACHINE_MACINTOSH 62 /* Apple Macintosh (68000) */ /* Word size in bytes (a constant equal to sizeof(int)). */ #if __ACK__ || __GNUC__ @@ -37,20 +33,6 @@ #define _MINIX_CHIP _CHIP_INTEL #endif -#if (_MINIX_MACHINE == _MACHINE_ATARI) || (_MINIX_MACHINE == _MACHINE_MACINTOSH) -#define _MINIX_CHIP _CHIP_M68000 -#endif - -#if (_MINIX_MACHINE == _MACHINE_SUN_4) || (_MINIX_MACHINE == _MACHINE_SUN_4_60) -#define _MINIX_CHIP _CHIP_SPARC -#define _MINIX_FP_FORMAT _FP_IEEE -#endif - -#if (_MINIX_MACHINE == _MACHINE_ATARI) || (_MINIX_MACHINE == _MACHINE_SUN_4) -#define _ASKDEV 1 /* ask for boot device */ -#define _FASTLOAD 1 /* use multiple block transfers to init ram */ -#endif - #ifndef _MINIX_FP_FORMAT #define _MINIX_FP_FORMAT _FP_NONE #endif