--- freem/src/service.c 2025/02/25 18:53:14 1.2 +++ freem/src/service.c 2025/02/25 18:55:13 1.3 @@ -74,11 +74,23 @@ int scosgr (short att, short bwflag); #endif /* system services */ -#if defined(__sun) || defined(__FreeBSD__) || defined(__NetBSD__) -# include +#if !defined(__APPLE__) && !defined(__gnu_hurd__) && !defined(EMSCRIPTEN) +# if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__AMIGA) +# include +# if !defined(__AMIGA) +# define TCGETA TIOCGETA +# define TCSETA TIOCSETA +# endif +# define termio termios +# else +# if !defined(MSDOS) +# include +# endif +# endif #else # include #endif + #include /* search 'string' for occurence of 'pattrn'