From 4e8a248d98a453a045973aa514289b5f1faf01a8 Mon Sep 17 00:00:00 2001 From: Hourier Date: Sat, 25 Jan 2020 17:51:49 +0900 Subject: [PATCH] =?utf8?q?[Refactor]=20#37353=20ACORN=20(=E6=97=A7?= =?utf8?q?=E5=BC=8FRISC=20OS)=E3=81=AE=E3=82=B5=E3=83=9D=E3=83=BC=E3=83=88?= =?utf8?q?=E3=81=AB=E7=94=B1=E6=9D=A5=E3=81=99=E3=82=8B=E3=83=97=E3=83=AA?= =?utf8?q?=E3=83=97=E3=83=AD=E3=82=92=E5=89=8A=E9=99=A4=20/=20Removed=20pr?= =?utf8?q?eprocessors=20'ACORN'=20(support=20for=20old=20RISC=20OS)?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- src/files.c | 2 +- src/h-config.h | 16 +++------------- src/h-define.h | 10 ---------- src/h-system.h | 5 ++--- src/main.c | 2 +- src/util.c | 33 --------------------------------- 6 files changed, 7 insertions(+), 61 deletions(-) diff --git a/src/files.c b/src/files.c index 55e4c78bd..13530d7fb 100644 --- a/src/files.c +++ b/src/files.c @@ -5614,7 +5614,7 @@ void process_player_name(player_type *creature_ptr, bool sf) if (current_world_ptr->character_generated) strcpy(old_player_base, creature_ptr->base_name); /* Cannot be too long */ -#if defined(MACINTOSH) || defined(ACORN) +#if defined(MACINTOSH) if (strlen(creature_ptr->name) > 15) { /* Name too long */ diff --git a/src/h-config.h b/src/h-config.h index 674bcd8ad..d600c8ae4 100644 --- a/src/h-config.h +++ b/src/h-config.h @@ -102,15 +102,6 @@ #endif /* - * Extract the "ACORN" flag from the compiler - */ -#ifdef __riscos -# ifndef ACORN -# define ACORN -# endif -#endif - -/* * Extract the "SGI" flag from the compiler */ #ifdef sgi @@ -154,8 +145,7 @@ * Basically, SET_UID should *only* be set for "Unix" machines, * or for the "Atari" platform which is Unix-like, apparently */ -#if !defined(MACINTOSH) && !defined(WINDOWS) && \ - !defined(ACORN) && !defined(VM) +#if !defined(MACINTOSH) && !defined(WINDOWS) && !defined(VM) # define SET_UID #endif @@ -181,8 +171,8 @@ * Every system seems to use its own symbol as a path separator. * Default to the standard Unix slash, but attempt to change this * for various other systems. Note that any system that uses the - * "period" as a separator (i.e. ACORN) will have to pretend that - * it uses the slash, and do its own mapping of period <-> slash. + * "period" as a separator will have to pretend that it uses the + * slash, and do its own mapping of period <-> slash. * Note that the VM system uses a "flat" directory, and thus uses * the empty string for "PATH_SEP". */ diff --git a/src/h-define.h b/src/h-define.h index 868e87d0f..74d58febd 100644 --- a/src/h-define.h +++ b/src/h-define.h @@ -11,16 +11,6 @@ /* - * Hack -- assist "main-acn.c" - */ -#ifdef ACORN -# define O_RDONLY 0 -# define O_WRONLY 1 -# define O_RDWR 2 -#endif - - -/* * The constants "TRUE" and "FALSE" */ diff --git a/src/h-system.h b/src/h-system.h index 80d2c053e..8b5106c44 100644 --- a/src/h-system.h +++ b/src/h-system.h @@ -72,8 +72,7 @@ # include #endif -#if !defined(MACINTOSH) && \ - !defined(ACORN) && !defined(VM) +#if !defined(MACINTOSH) && !defined(VM) # if defined(__TURBOC__) || defined(__WATCOMC__) # include # else @@ -82,7 +81,7 @@ #endif -#if !defined(NeXT) && !defined(__MWERKS__) && !defined(ACORN) +#if !defined(NeXT) && !defined(__MWERKS__) # include #endif diff --git a/src/main.c b/src/main.c index 0fae8c3b5..86c2d334c 100644 --- a/src/main.c +++ b/src/main.c @@ -30,7 +30,7 @@ */ -#if !defined(MACINTOSH) && !defined(WINDOWS) && !defined(ACORN) +#if !defined(MACINTOSH) && !defined(WINDOWS) /* diff --git a/src/util.c b/src/util.c index c05d357b3..bb897ee04 100644 --- a/src/util.c +++ b/src/util.c @@ -261,17 +261,6 @@ void user_name(char *buf, int id) */ -#ifdef ACORN - - - /* - * Most of the "file" routines for "ACORN" should be in "main-acn.c" - */ - - -#else /* ACORN */ - - #ifdef SET_UID /* @@ -492,9 +481,6 @@ errr my_fclose(FILE *fff) } -#endif /* ACORN */ - - #ifdef HAVE_MKSTEMP FILE *my_fopen_temp(char *buf, int max) @@ -641,20 +627,6 @@ errr my_fputs(FILE *fff, concptr buf, huge n) } -#ifdef ACORN - - -/* - * Most of the "file" routines for "ACORN" should be in "main-acn.c" - * - * Many of them can be rewritten now that only "fd_open()" and "fd_make()" - * and "my_fopen()" should ever create files. - */ - - -#else /* ACORN */ - - /* * The Macintosh is a little bit brain-dead sometimes */ @@ -995,11 +967,6 @@ errr fd_close(int fd) } -#endif /* ACORN */ - - - - /* * Important note about "colors" * -- 2.11.0