--- ./src/gui/Makefile.in.save	Fri Mar 15 20:10:54 2019
+++ ./src/gui/Makefile.in	Fri Mar 15 20:31:41 2019
@@ -100,8 +100,8 @@
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
 LIBRARIES = $(noinst_LIBRARIES)
-AR = ar
-ARFLAGS = cru
+AR = CC -ar
+ARFLAGS = -WR,-suv -o
 AM_V_AR = $(am__v_AR_@AM_V@)
 am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@)
 am__v_AR_0 = @echo "  AR      " $@;
--- ./src/debug/Makefile.in.save	Fri Mar 15 20:11:59 2019
+++ ./src/debug/Makefile.in	Fri Mar 15 20:46:48 2019
@@ -100,8 +100,8 @@
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
 LIBRARIES = $(noinst_LIBRARIES)
-AR = ar
-ARFLAGS = cru
+AR = CC -ar
+ARFLAGS = -WR,-suv -o
 AM_V_AR = $(am__v_AR_@AM_V@)
 am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@)
 am__v_AR_0 = @echo "  AR      " $@;
--- ./src/libs/gui_tk/Makefile.in.save	Fri Mar 15 20:13:14 2019
+++ ./src/libs/gui_tk/Makefile.in	Fri Mar 15 20:49:57 2019
@@ -100,8 +100,8 @@
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
 LIBRARIES = $(noinst_LIBRARIES)
-AR = ar
-ARFLAGS = cru
+AR = CC -ar
+ARFLAGS = -WR,-suv -o
 AM_V_AR = $(am__v_AR_@AM_V@)
 am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@)
 am__v_AR_0 = @echo "  AR      " $@;
--- ./src/shell/Makefile.in.save	Fri Mar 15 20:14:31 2019
+++ ./src/shell/Makefile.in	Fri Mar 15 20:48:50 2019
@@ -100,8 +100,8 @@
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
 LIBRARIES = $(noinst_LIBRARIES)
-AR = ar
-ARFLAGS = cru
+AR = CC -ar
+ARFLAGS = -WR,-suv -o
 AM_V_AR = $(am__v_AR_@AM_V@)
 am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@)
 am__v_AR_0 = @echo "  AR      " $@;
--- ./src/ints/Makefile.in.save	Fri Mar 15 20:15:01 2019
+++ ./src/ints/Makefile.in	Fri Mar 15 20:50:23 2019
@@ -100,8 +100,8 @@
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
 LIBRARIES = $(noinst_LIBRARIES)
-AR = ar
-ARFLAGS = cru
+AR = CC -ar
+ARFLAGS = -WR,-suv -o
 AM_V_AR = $(am__v_AR_@AM_V@)
 am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@)
 am__v_AR_0 = @echo "  AR      " $@;
--- ./src/cpu/cpu.cpp.save	Fri Mar 15 10:47:45 2019
+++ ./src/cpu/cpu.cpp	Fri Mar 15 10:48:21 2019
@@ -36,7 +36,7 @@
 
 #if 1
 #undef LOG
-#if defined (_MSC_VER)
+#if defined (_MSC_VER) || defined (__sgi)
 #define LOG(X,Y)
 #else
 #define LOG(X,Y) CPU_LOG
--- ./src/cpu/Makefile.in.save	Fri Mar 15 20:15:26 2019
+++ ./src/cpu/Makefile.in	Fri Mar 15 20:49:13 2019
@@ -100,8 +100,8 @@
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
 LIBRARIES = $(noinst_LIBRARIES)
-AR = ar
-ARFLAGS = cru
+AR = CC -ar
+ARFLAGS = -WR,-suv -o
 AM_V_AR = $(am__v_AR_@AM_V@)
 am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@)
 am__v_AR_0 = @echo "  AR      " $@;
--- ./src/fpu/Makefile.in.save	Fri Mar 15 20:15:52 2019
+++ ./src/fpu/Makefile.in	Fri Mar 15 20:49:30 2019
@@ -100,8 +100,8 @@
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
 LIBRARIES = $(noinst_LIBRARIES)
-AR = ar
-ARFLAGS = cru
+AR = CC -ar
+ARFLAGS = -WR,-suv -o
 AM_V_AR = $(am__v_AR_@AM_V@)
 am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@)
 am__v_AR_0 = @echo "  AR      " $@;
--- ./src/hardware/mame/emu.h.save	Fri Mar 15 10:59:39 2019
+++ ./src/hardware/mame/emu.h	Fri Mar 15 11:03:07 2019
@@ -4,9 +4,13 @@
 
 #include "dosbox.h"
 #if defined(_MSC_VER) && (_MSC_VER  <= 1500) 
-#include <SDL.h>
+ #include <SDL.h>
 #else
-#include <stdint.h>
+ #if defined(__sgi) && !defined(__GNUC__) && defined(_LANGUAGE_C_PLUS_PLUS)
+  #include <inttypes.h>
+ #else
+  #include <stdint.h> /* intptr_t uint64_t */
+ #endif
 #endif
 #include <math.h>
 #include <float.h>
--- ./src/hardware/mame/Makefile.in.save	Fri Mar 15 20:17:43 2019
+++ ./src/hardware/mame/Makefile.in	Fri Mar 15 20:51:00 2019
@@ -100,8 +100,8 @@
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
 LIBRARIES = $(noinst_LIBRARIES)
-AR = ar
-ARFLAGS = cru
+AR = CC -ar
+ARFLAGS = -WR,-suv -o
 AM_V_AR = $(am__v_AR_@AM_V@)
 am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@)
 am__v_AR_0 = @echo "  AR      " $@;
--- ./src/hardware/serialport/Makefile.in.save	Fri Mar 15 20:18:09 2019
+++ ./src/hardware/serialport/Makefile.in	Fri Mar 15 20:51:18 2019
@@ -100,8 +100,8 @@
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
 LIBRARIES = $(noinst_LIBRARIES)
-AR = ar
-ARFLAGS = cru
+AR = CC -ar
+ARFLAGS = -WR,-suv -o
 AM_V_AR = $(am__v_AR_@AM_V@)
 am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@)
 am__v_AR_0 = @echo "  AR      " $@;
--- ./src/hardware/Makefile.in.save	Fri Mar 15 20:17:18 2019
+++ ./src/hardware/Makefile.in	Fri Mar 15 20:50:42 2019
@@ -100,8 +100,8 @@
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
 LIBRARIES = $(noinst_LIBRARIES)
-AR = ar
-ARFLAGS = cru
+AR = CC -ar
+ARFLAGS = -WR,-suv -o
 AM_V_AR = $(am__v_AR_@AM_V@)
 am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@)
 am__v_AR_0 = @echo "  AR      " $@;
--- ./src/dos/Makefile.in.save	Fri Mar 15 20:16:21 2019
+++ ./src/dos/Makefile.in	Fri Mar 15 20:48:00 2019
@@ -100,8 +100,8 @@
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
 LIBRARIES = $(noinst_LIBRARIES)
-AR = ar
-ARFLAGS = cru
+AR = CC -ar
+ARFLAGS = -WR,-suv -o
 AM_V_AR = $(am__v_AR_@AM_V@)
 am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@)
 am__v_AR_0 = @echo "  AR      " $@;
--- ./src/misc/Makefile.in.save	Fri Mar 15 20:16:53 2019
+++ ./src/misc/Makefile.in	Fri Mar 15 20:48:26 2019
@@ -100,8 +100,8 @@
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
 LIBRARIES = $(noinst_LIBRARIES)
-AR = ar
-ARFLAGS = cru
+AR = CC -ar
+ARFLAGS = -WR,-suv -o
 AM_V_AR = $(am__v_AR_@AM_V@)
 am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@)
 am__v_AR_0 = @echo "  AR      " $@;
--- configure.save	Sun Mar 17 13:27:55 2019
+++ configure	Sun Mar 17 13:28:26 2019
@@ -5226,7 +5226,7 @@
   $as_echo_n "(cached) " >&6
 else
   ac_cv_c_inline=no
-for ac_kw in inline __inline__ __inline; do
+for ac_kw in __inline __inline__ inline; do
   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 #ifndef __cplusplus
--- ./include/ipx.h.save	Sat Mar 16 22:31:25 2019
+++ ./include/ipx.h	Sat Mar 16 22:32:18 2019
@@ -27,7 +27,7 @@
 #ifdef IPX_DEBUGMSG
 #define LOG_IPX LOG_MSG
 #else
-#if defined (_MSC_VER)
+#if defined (_MSC_VER) || defined (__sgi)
 #define LOG_IPX
 #else
 #define LOG_IPX(...)
@@ -66,7 +66,7 @@
 #define COMP_UNDELIVERABLE    0xfe
 #define COMP_HARDWAREERROR    0xff
 
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack(1)
 #endif
 
@@ -154,7 +154,7 @@
 void UnpackIP(PackedIP ipPack, IPaddress * ipAddr);
 void PackIP(IPaddress ipAddr, PackedIP *ipPack);
 
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack()
 #endif
 
--- ./include/paging.h.save	Sat Mar 16 22:28:01 2019
+++ ./include/paging.h	Sat Mar 16 22:28:50 2019
@@ -100,7 +100,7 @@
 void MEM_ResetPageHandler(Bitu phys_page, Bitu pages);
 
 
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__SGI)
 #pragma pack (1)
 #endif
 struct X86_PageEntryBlock{
@@ -130,7 +130,7 @@
 	Bit32u		base:20;
 #endif
 } GCC_ATTRIBUTE(packed);
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__SGI)
 #pragma pack ()
 #endif
 
--- ./include/dos_inc.h.save	Sat Mar 16 22:21:57 2019
+++ ./include/dos_inc.h	Sat Mar 16 22:26:02 2019
@@ -30,7 +30,7 @@
 
 #include <stddef.h> //for offsetof
 
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack (1)
 #endif
 struct CommandTail{
@@ -37,7 +37,7 @@
   Bit8u count;				/* number of bytes returned */
   char buffer[127];			 /* the buffer itself */
 } GCC_ATTRIBUTE(packed);
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack ()
 #endif
 
@@ -52,7 +52,7 @@
 };
 
 
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack (1)
 #endif
 union bootSector {
@@ -66,7 +66,7 @@
 	} bootdata;
 	Bit8u rawdata[512];
 } GCC_ATTRIBUTE(packed);
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack ()
 #endif
 
@@ -308,7 +308,7 @@
 	Bit16u	FindEntryByHandle	(Bit8u handle);
 			
 private:
-	#ifdef _MSC_VER
+	#if defined(_MSC_VER) || defined(__sgi)
 	#pragma pack(1)
 	#endif
 	struct sPSP {
@@ -339,7 +339,7 @@
 		Bit8u	fill_4[4];			/* unused */
 		CommandTail cmdtail;		
 	} GCC_ATTRIBUTE(packed);
-	#ifdef _MSC_VER
+	#if defined(_MSC_VER) || defined(__sgi)
 	#pragma pack()
 	#endif
 	Bit16u	seg;
@@ -353,7 +353,7 @@
 	void Clear(void);
 	void LoadData(void);
 	void SaveData(void);		/* Save it as an exec block */
-	#ifdef _MSC_VER
+	#if defined(_MSC_VER) || defined(__sgi)
 	#pragma pack (1)
 	#endif
 	struct sOverlay {
@@ -368,7 +368,7 @@
 		RealPt initsssp;
 		RealPt initcsip;
 	}GCC_ATTRIBUTE(packed);
-	#ifdef _MSC_VER
+	#if defined(_MSC_VER) || defined(__sgi)
 	#pragma pack()
 	#endif
 	sExec exec;
@@ -392,7 +392,7 @@
 	RealPt	GetPointer(void);
 	Bit32u GetDeviceChain(void);
 
-	#ifdef _MSC_VER
+	#if defined(_MSC_VER) || defined(__sgi)
 	#pragma pack(1)
 	#endif
 	struct sDIB {		
@@ -445,7 +445,7 @@
 		Bit16u	startOfUMBChain;		//  0x66 segment of first UMB-MCB
 		Bit16u	memAllocScanStart;		//  0x68 start paragraph for memory allocation
 	} GCC_ATTRIBUTE(packed);
-	#ifdef _MSC_VER
+	#if defined(_MSC_VER) || defined(__sgi)
 	#pragma pack ()
 	#endif
 	Bit16u	seg;
@@ -467,7 +467,7 @@
 	Bit16u	GetDirID(void)				{ return (Bit16u)sGet(sDTA,dirID); };
 	Bit16u	GetDirIDCluster(void)		{ return (Bit16u)sGet(sDTA,dirCluster); };
 private:
-	#ifdef _MSC_VER
+	#if defined(_MSC_VER) || defined(__sgi)
 	#pragma pack(1)
 	#endif
 	struct sDTA {
@@ -484,7 +484,7 @@
 		Bit32u size;
 		char name[DOS_NAMELENGTH_ASCII];
 	} GCC_ATTRIBUTE(packed);
-	#ifdef _MSC_VER
+	#if defined(_MSC_VER) || defined(__sgi)
 	#pragma pack()
 	#endif
 };
@@ -512,7 +512,7 @@
 private:
 	bool extended;
 	PhysPt real_pt;
-	#ifdef _MSC_VER
+	#if defined(_MSC_VER) || defined(__sgi)
 	#pragma pack (1)
 	#endif
 	struct sFCB {
@@ -534,7 +534,7 @@
 		Bit8u  cur_rec;			/* Current record in current block */
 		Bit32u rndm;			/* Current relative record number */
 	} GCC_ATTRIBUTE(packed);
-	#ifdef _MSC_VER
+	#if defined(_MSC_VER) || defined(__sgi)
 	#pragma pack ()
 	#endif
 };
@@ -551,7 +551,7 @@
 	Bit16u GetSize(void) { return (Bit16u)sGet(sMCB,size);}
 	Bit16u GetPSPSeg(void) { return (Bit16u)sGet(sMCB,psp_segment);}
 private:
-	#ifdef _MSC_VER
+	#if defined(_MSC_VER) || defined(__sgi)
 	#pragma pack (1)
 	#endif
 	struct sMCB {
@@ -561,7 +561,7 @@
 		Bit8u unused[3];
 		Bit8u filename[8];
 	} GCC_ATTRIBUTE(packed);
-	#ifdef _MSC_VER
+	#if defined(_MSC_VER) || defined(__sgi)
 	#pragma pack ()
 	#endif
 };
@@ -579,7 +579,7 @@
 	
 	
 private:
-	#ifdef _MSC_VER
+	#if defined(_MSC_VER) || defined(__sgi)
 	#pragma pack (1)
 	#endif
 	struct sSDA {
@@ -599,7 +599,7 @@
 		Bit8u extended_break_flag; 	/* 0x17 extended break flag */
 		Bit8u fill[2];			/* 0x18 flag: code page switching || flag: copy of previous byte in case of INT 24 Abort*/
 	} GCC_ATTRIBUTE(packed);
-	#ifdef _MSC_VER
+	#if defined(_MSC_VER) || defined(__sgi)
 	#pragma pack()
 	#endif
 };
--- ./include/cpu.h.save	Sat Mar 16 22:29:22 2019
+++ ./include/cpu.h	Sat Mar 16 22:30:57 2019
@@ -223,7 +223,7 @@
 #define DESC_CODE_R_C_A				0x1e
 #define DESC_CODE_R_C_NA			0x1f
 
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack (1)
 #endif
 
@@ -320,7 +320,7 @@
     Bit32u ldt;                  /* The local descriptor table */
 } GCC_ATTRIBUTE(packed);
 
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack()
 #endif
 class Descriptor
--- ./src/dos/wnaspi32.h.save	Sat Mar 16 22:51:15 2019
+++ ./src/dos/wnaspi32.h	Sat Mar 16 22:53:02 2019
@@ -25,7 +25,7 @@
 #pragma option -a1
 #endif //__BORLANDC__
 
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack(1)
 #endif //__MSC_VER
 
@@ -343,7 +343,7 @@
 #pragma option -a.
 #endif //__BORLANDC__
 
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack()
 #endif //_MSC_VER
 
--- ./src/dos/dos_mscdex.cpp.save	Sat Mar 16 22:58:13 2019
+++ ./src/dos/dos_mscdex.cpp	Sat Mar 16 22:59:26 2019
@@ -70,7 +70,7 @@
 	void	SetStrategy			(Bit16u ofs)	{ sSave(sDeviceHeader,strategy,ofs);			};
 
 public:
-	#ifdef _MSC_VER
+	#if defined(_MSC_VER) || defined(__sgi)
 	#pragma pack(1)
 	#endif
 	struct sDeviceHeader{
@@ -83,7 +83,7 @@
 		Bit8u	driveLetter;
 		Bit8u	numSubUnits;
 	} GCC_ATTRIBUTE(packed) TDeviceHeader;
-	#ifdef _MSC_VER
+	#if defined(_MSC_VER) || defined(__sgi)
 	#pragma pack()
 	#endif
 };
--- ./src/dos/drives.h.save	Sat Mar 16 22:53:20 2019
+++ ./src/dos/drives.h	Sat Mar 16 22:55:03 2019
@@ -87,7 +87,7 @@
 	} allocation;
 };
 
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack (1)
 #endif
 struct bootstrap {
@@ -140,7 +140,7 @@
 	Bit8u  magic2; /* 0xaa */
 } GCC_ATTRIBUTE(packed);
 
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack ()
 #endif
 
@@ -232,7 +232,7 @@
 	char driveLetter;
 };
 
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack (1)
 #endif
 struct isoPVD {
@@ -285,7 +285,7 @@
 	Bit8u ident[222];
 } GCC_ATTRIBUTE(packed);
 
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack ()
 #endif
 
--- ./src/dos/dos_execute.cpp.save	Sat Mar 16 22:55:27 2019
+++ ./src/dos/dos_execute.cpp	Sat Mar 16 22:56:38 2019
@@ -30,7 +30,7 @@
 
 const char * RunningProgram="DOSBOX";
 
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack(1)
 #endif
 struct EXE_Header {
@@ -49,7 +49,7 @@
 	Bit16u reloctable;
 	Bit16u overlay;
 } GCC_ATTRIBUTE(packed);
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack()
 #endif
 
--- ./src/dos/dos_tables.cpp.save	Sat Mar 16 22:59:38 2019
+++ ./src/dos/dos_tables.cpp	Sat Mar 16 23:00:27 2019
@@ -23,7 +23,7 @@
 #include "dos_inc.h"
 #include "callback.h"
 
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack(1)
 #endif
 struct DOS_TableCase {	
@@ -31,7 +31,7 @@
 	Bit8u chars[256];
 }
 GCC_ATTRIBUTE (packed);
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack ()
 #endif
 
--- ./src/dos/dos_files.cpp.save	Sat Mar 16 22:56:59 2019
+++ ./src/dos/dos_files.cpp	Sat Mar 16 22:57:53 2019
@@ -785,7 +785,7 @@
 	Bitu index=0;
 	Bit8u fill=' ';
 /* First get the old data from the fcb */
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack (1)
 #endif
 	union {
@@ -796,7 +796,7 @@
 		} GCC_ATTRIBUTE (packed) part;
 		char full[DOS_FCBNAME];
 	} fcb_name;
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack()
 #endif
 	/* Get the old information from the previous fcb */
--- ./src/hardware/adlib.cpp.save	Sat Mar 16 23:01:24 2019
+++ ./src/hardware/adlib.cpp	Sat Mar 16 23:02:09 2019
@@ -99,7 +99,7 @@
 
 /* Raw DRO capture stuff */
 
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack (1)
 #endif
 
@@ -120,7 +120,7 @@
 	Bit8u delayShift8;			/* 0x18, Bit8u (delay + 1)*256 */			
 	Bit8u conversionTableSize;	/* 0x191, Bit8u Raw Conversion Table size */
 } GCC_ATTRIBUTE(packed);
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack()
 #endif
 /*
--- ./src/ints/xms.cpp.save	Sat Mar 16 23:06:22 2019
+++ ./src/ints/xms.cpp	Sat Mar 16 23:07:00 2019
@@ -81,7 +81,7 @@
 	bool	free;
 };
 
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack (1)
 #endif
 struct XMS_MemMove{
@@ -98,7 +98,7 @@
 	} dest;
 
 } GCC_ATTRIBUTE(packed);
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack ()
 #endif
 
--- ./src/ints/int10_vesa.cpp.save	Sat Mar 16 23:04:49 2019
+++ ./src/ints/int10_vesa.cpp	Sat Mar 16 23:05:37 2019
@@ -41,7 +41,7 @@
 static char string_productname[]="DOSBox - The DOS Emulator";
 static char string_productrev[]="DOSBox " VERSION;
 
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack (1)
 #endif
 struct MODE_INFO{
@@ -79,7 +79,7 @@
 	Bit16u OffScreenMemSize;
 	Bit8u Reserved[206];
 } GCC_ATTRIBUTE(packed);
-#ifdef _MSC_VER
+#if defined(_MSC_VER) || defined(__sgi)
 #pragma pack()
 #endif
 
--- ./src/dos/cdrom_image.cpp.save	Wed May  1 21:31:55 2019
+++ ./src/dos/cdrom_image.cpp	Wed May  1 22:16:31 2019
@@ -39,6 +39,11 @@
 #include <string.h>
 #endif
 
+#if defined(__sgi)
+extern long int lround(double x);
+#pragma optional lround
+#endif
+
 using namespace std;
 
 #define MAX_LINE_LENGTH 512
