try to reduce some Amiga cross-compile warnings

This commit is contained in:
nhmall
2026-03-25 08:48:14 -04:00
parent 3c89dc2387
commit b58d2d4096
5 changed files with 20 additions and 4 deletions

View File

@@ -17,6 +17,10 @@
#ifdef CROSS_TO_AMIGA #ifdef CROSS_TO_AMIGA
#include <stdlib.h> #include <stdlib.h>
#include <string.h> #include <string.h>
#include <unistd.h>
#include <dos/dos.h>
#include <clib/dos_protos.h>
#include <proto/dos.h>
#endif #endif
#ifdef __SASC_60 /* since SAS can prevent re-inclusion */ #ifdef __SASC_60 /* since SAS can prevent re-inclusion */

View File

@@ -110,10 +110,14 @@ enum optchoice { opt_in, opt_out};
typedef uchar nhsym; typedef uchar nhsym;
#ifndef STRNCMPI #ifndef STRNCMPI
#ifndef __SASC_60 /* SAS/C already shifts to stricmp */ /* SAS/C already shifts to stricmp */
#if !defined(__SASC_60) && !defined(CROSS_TO_AMIGA)
#define strcmpi(a, b) strncmpi((a), (b), -1) #define strcmpi(a, b) strncmpi((a), (b), -1)
#endif #endif
#endif #endif
#ifdef CROSS_TO_AMIGA
#define strcmpi(a, b) stricmp(a, b)
#endif
/* #define SPECIALIZATION */ /* do "specialized" version of new topology */ /* #define SPECIALIZATION */ /* do "specialized" version of new topology */

View File

@@ -450,7 +450,11 @@ fopenp(const char *name, const char *mode)
static BPTR OrgDirLock = NO_LOCK; static BPTR OrgDirLock = NO_LOCK;
int int
chdir(char *dir) chdir(
#ifdef CROSS_TO_AMIGA
const
#endif
char *dir)
{ {
extern char orgdir[]; extern char orgdir[];

View File

@@ -31,10 +31,10 @@ void getreturn(const char *);
#ifndef msmsg #ifndef msmsg
void msmsg( const char *, ... ); void msmsg( const char *, ... );
#endif #endif
#if !defined(__SASC_60) && !defined(_DCC) #if !defined(__SASC_60) && !defined(_DCC) && !defined(CROSS_TO_AMIGA)
int chdir(char *); int chdir(char *);
#endif #endif
#ifndef strcmpi #ifndef strcmpi
int strcmpi(char * , char *); int strcmpi(char * , char *);
#endif #endif
#if !defined(memcmp) && !defined(AZTEC_C) && !defined(_DCC) && !defined(__GNUC__) #if !defined(memcmp) && !defined(AZTEC_C) && !defined(_DCC) && !defined(__GNUC__)

View File

@@ -891,6 +891,10 @@ amii_loadlib(void)
{ {
} }
#ifdef CROSS_TO_AMIGA
extern void Abort(long) NORETURN;
#endif
/* fatal error */ /* fatal error */
/*VARARGS1*/ /*VARARGS1*/
void error void error