X-Git-Url: http://shamusworld.gotdns.org/cgi-bin/gitweb.cgi?p=rln;a=blobdiff_plain;f=rln.h;h=e9daf2a9bfb9d102d080366ece7a8793d3bf106f;hp=0db3cc65557d0cc304d2798575a700dde94fc78f;hb=05f3a96e41a1c2ad78a080a192876517a8aefc78;hpb=52b539ef196822e2e1c3baf8f9e21e9a6b5f1ddc diff --git a/rln.h b/rln.h index 0db3cc6..e9daf2a 100644 --- a/rln.h +++ b/rln.h @@ -1,17 +1,11 @@ // -// RLN - Reboot's Linker for the Atari Jaguar Console System -// RLN.H - Application Header -// Copyright (C) 199x Allan K. Pratt, 2011 Reboot & Friends +// RLN - Reboot's Linker for the Atari Jaguar console system +// Copyright (C) 199x Allan K. Pratt, 2011-2015 Reboot & Friends // #ifndef __RLN_H__ #define __RLN_H__ -// Required Include Files - -// Macro Definitions - -// Requirements for Windows Compilation #ifdef WIN32 //#define _OPEN_FLAGS _O_BINARY|_O_RDWR @@ -33,8 +27,6 @@ #include #endif -// Requirements for Mac OS-X or Linux Compilation - #ifdef __GCCUNIX__ //#define _OPEN_FLAGS O_RDWR #define _OPEN_FLAGS O_RDONLY @@ -51,7 +43,7 @@ #endif #define MAJOR 1 // Major version number -#define MINOR 4 // Minor version number +#define MINOR 5 // Minor version number #define PATCH 1 // Patch release number #ifdef WIN32 @@ -131,7 +123,9 @@ struct ARHEADER #define new_arheader() (struct ARHEADER *)malloc(sizeof(struct ARHEADER)) -// Object File Structure and Related Items +// Object file structure and related items + +enum { TEXT=0, DATA=1, BSS=2 }; struct OFILE { @@ -144,6 +138,10 @@ struct OFILE struct OHEADER o_header; // Header of this file uint8_t * o_image; // Image of this file uint8_t isArchiveFile; // Temporary extra flag +//These are likely redundant, and can probably be removed with judicious +//editing of where they are used (in favor of OHEADER vars) + uint32_t segSize[3]; // Size of TEXT, DATA & BSS (aligned) + uint32_t segBase[3]; // Accumulated base address of TDB }; #define new_ofile() (struct OFILE *)malloc(sizeof(struct OFILE)) @@ -151,6 +149,7 @@ struct OFILE // Flags in an Object File's o_flags field // O_USED: means this ofile is used or is on the command line or in a -x #define O_USED 0x0001 +// N.B.: This is *never* set anywhere in the linker code... #define O_ARCHIVE 0x0002 // This is a dummy archive entry // Symbol Record