[gforth] / gforth / Attic / main.c  

gforth: gforth/Attic/main.c

Diff for /gforth/Attic/main.c between version 1.35 and 1.36

version 1.35, Wed Apr 17 16:39:42 1996 UTC version 1.36, Fri May 3 13:05:05 1996 UTC
Line 61 
Line 61 
 /* image file format:  /* image file format:
  *  "#! binary-path -i\n" (e.g., "#! /usr/local/bin/gforth-0.2.0 -i\n")   *  "#! binary-path -i\n" (e.g., "#! /usr/local/bin/gforth-0.2.0 -i\n")
  *   padding to a multiple of 8   *   padding to a multiple of 8
  *   magic: "gforth1x" means format 0.2,   *   magic: "Gforth1x" means format 0.2,
  *              where x is even for big endian and odd for little endian   *              where x is even for big endian and odd for little endian
  *              and x & ~1 is the size of the cell in bytes.   *              and x & ~1 is the size of the cell in bytes.
  *  padding to max alignment (no padding necessary on current machines)   *  padding to max alignment (no padding necessary on current machines)
Line 166 
Line 166 
   do    do
     {      {
       if(fread(magic,sizeof(Char),8,imagefile) < 8) {        if(fread(magic,sizeof(Char),8,imagefile) < 8) {
         fprintf(stderr,"%s: image doesn't seem to be a Gforth image.\n",progname);          fprintf(stderr,"%s: image doesn't seem to be a Gforth (>=0.2) image.\n",progname);
         exit(1);          exit(1);
       }        }
       preamblesize+=8;        preamblesize+=8;
Line 227 
Line 227 
     ((ImageHeader *)imp)->checksum=check_sum;      ((ImageHeader *)imp)->checksum=check_sum;
   }    }
   else if(header.base!=imp) {    else if(header.base!=imp) {
     fprintf(stderr,"%s: Cannot load nonrelocatable image (compiled for address 0x%lx) at address 0x%lx\nThe Gforth installer should look into the INSTALL file\n",      fprintf(stderr,"%s: Cannot load nonrelocatable image (compiled for address $%lx) at address $%lx\nThe Gforth installer should look into the INSTALL file\n",
             progname, (unsigned long)header.base, (unsigned long)imp);              progname, (unsigned long)header.base, (unsigned long)imp);
     exit(1);      exit(1);
   } else if (header.checksum != check_sum) {    } else if (header.checksum != check_sum) {
     fprintf(stderr,"%s: Checksum of image (0x%lx) does not match the executable (0x%lx)\nThe Gforth installer should look into the INSTALL file\n",      fprintf(stderr,"%s: Checksum of image ($%lx) does not match the executable ($%lx)\nThe Gforth installer should look into the INSTALL file\n",
             progname, (unsigned long)(header.checksum),(unsigned long)check_sum);              progname, (unsigned long)(header.checksum),(unsigned long)check_sum);
     exit(1);      exit(1);
   }    }


Generate output suitable for use with a patch program
Legend:
Removed from v.1.35  
changed lines
  Added in v.1.36

CVS Admin

Powered by ViewCVS 1.0-dev
(Powered by ViewCVS)

ViewCVS and CVS Help