- unsigned i;
- char buf[EBUFSIZ];
-
- // Make undefined symbols GLOBL
- if (glob_flag)
- syg_fix();
-
- resfix(TEXT);
- resfix(DATA);
-
- // We need to do a final check of forward 'jump' destination addresses that are external
- for(i=0; i<MAXFWDJUMPS; i++)
- {
- if (fwdjump[i])
- {
- err_setup();
- sprintf(buf, "* \'jump\' at $%08X - destination address is external to this source file and cannot have its aligment validated", fwdjump[i]);
-
- if (listing > 0)
- ship_ln(buf);
-
- if (err_flag)
- write(err_fd, buf, (LONG)strlen(buf));
- else
- printf("%s\n", buf);
- }
- }
-
- return 0;
-}
-
-
-//
-// Resolve Fixups in a Section
-//
-int resfix(int sno)
-{
- SECT * sc; // Section
- CHUNK * ch;
- PTR fup; // Current fixup
- WORD * fuend; // End of last fixup (in this chunk)
- CHUNK * cch; // Cached chunk for target
- WORD w; // Fixup word (type+modes+flags)
- char * locp; // Location to fix (in cached chunk)
- LONG loc; // Location to fixup
- VALUE eval; // Expression value
- WORD eattr; // Expression attrib
- SYM * esym; // External symbol involved in expr
- SYM * sy; // (Temp) pointer to a symbol
- WORD i; // (Temp) word
- WORD tdb; // eattr & TDB
- LONG oaddr;
+ PTR fup; // Current fixup
+ uint16_t * fuend; // End of last fixup (in this chunk)
+ uint16_t w; // Fixup word (type+modes+flags)
+ uint8_t * locp; // Location to fix (in cached chunk)
+ uint32_t loc; // Location to fixup
+ VALUE eval; // Expression value
+ uint16_t eattr; // Expression attrib
+ SYM * esym; // External symbol involved in expr
+ SYM * sy; // (Temp) pointer to a symbol
+ uint16_t i; // (Temp) word
+ uint16_t tdb; // eattr & TDB
+ uint32_t oaddr;