diff --git a/include/m2/types.h b/include/m2/types.h index c5547f5c..91360223 100644 --- a/include/m2/types.h +++ b/include/m2/types.h @@ -20,6 +20,13 @@ #ifndef __M2_TYPES_H #define __M2_TYPES_H 1 +// FIXME M2_Planet chokes on -1, even inside #if ! __M2__ +#if __arm__ || __i386__ +#define EOF 0xffffffff +#else +#define EOF 0xffffffffffffffff +#endif + /* #ifndef __MES_CLOCK_T #define __MES_CLOCK_T diff --git a/include/mes/cc.h b/include/mes/cc.h index 1255537b..0c8cc794 100644 --- a/include/mes/cc.h +++ b/include/mes/cc.h @@ -21,6 +21,12 @@ #ifndef __MES_CC_H #define __MES_CC_H +#define EOF -1 + +#if SYSTEM_LIBC +#define __raise(x) -1 +#endif + typedef struct scm* SCM; #if __MESC__ diff --git a/include/mes/lib-system.h b/include/mes/lib-system.h deleted file mode 100644 index cf95bf56..00000000 --- a/include/mes/lib-system.h +++ /dev/null @@ -1,27 +0,0 @@ -/* -*-comment-start: "//";comment-end:""-*- - * GNU Mes --- Maxwell Equations of Software - * Copyright © 2022 Jan (janneke) Nieuwenhuizen - * - * This file is part of GNU Mes. - * - * GNU Mes is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 3 of the License, or (at - * your option) any later version. - * - * GNU Mes is distributed in the hope that it will be useful, but - * WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with GNU Mes. If not, see . - */ -#ifndef __MES_LIB_SYSTEM_H -#define __MES_LIB_SYSTEM_H - -#if SYSTEM_LIBC -#define __raise(x) -1 -#endif - -#endif //__MES_LIB_SYSTEM_H diff --git a/include/mes/mes.h b/include/mes/mes.h index be2dc194..0323b2dc 100644 --- a/include/mes/mes.h +++ b/include/mes/mes.h @@ -185,6 +185,5 @@ long seconds_and_nanoseconds_to_long (long s, long ns); #include "mes/builtins.h" #include "mes/constants.h" #include "mes/symbols.h" -#include "mes/lib-system.h" #endif /* __MES_MES_H */ diff --git a/include/sys/types.h b/include/sys/types.h index 368dd12f..d7733bf6 100644 --- a/include/sys/types.h +++ b/include/sys/types.h @@ -31,15 +31,6 @@ #define __MESCCLIB__ 15 #endif -#ifndef EOF -// FIXME M2_Planet chokes on -1, even inside #if ! __M2__ -#if __arm__ || __i386__ -#define EOF 0xffffffff -#else -#define EOF 0xffffffffffffffff -#endif -#endif - #ifndef NULL #define NULL 0 #endif