Ignore:
Timestamp:
Apr 12, 2014, 11:24:51 AM (11 years ago)
Author:
Ben Rietbroek
Message:

Fixed Installer to handle packed hideparttable [2012-04-23]

WARNING!!

All commits upto and including the commit of [2012-05-13] contain
a severe bug!! Building from these sources and then disabling
the 'force LBA' feature while also using the drive-letter feature or
editing the label can DESTROY THE MBR on ALL ATTACHED DISKS!!
DO NOT DISABLE 'FORCE LBA USAGE' WHEN BUILT FROM THE THESE COMMITS!!

Changes

o Installer can now handle packed hideparttable
o Implemented upgrading from v1.06 directly to v1.0.8
o Fixed minor stuff when upgrading from v1.06 to v1.07
o Implemented DOS code in C cross-platform installer

There is now one C source for 4 platforms:
DOS,WIN32,OS2 and LINUX (Linux portion not ready yet)
This obsoletes AIRBOOT.ASM/AIRBOOT.COM.
DOS Installer is now AIRBOOTD.EXE.

o This commit is prepairing for v1.0.8-rc2

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/TOOLS/INTERNAL/FIXCODE.C

    r46 r47  
    2222//  It is a quick-and-dirty translation of the original DOS-only ASM file.
    2323//  Of course it's not as small but it's much easier to maintain across
    24 //  multiple platforms.
     24//  multiple platforms. A small change with regard to the old ASM version is
     25//  that it directly writes AIRBOOT.BIN instead of writing AIR-BOOT.COM.
     26//  This way the pre and post situations are kept valid.
    2527*/
    2628
     
    4951#define     IN_FILE     "AIR-BOOT.COM"              // Target from assembly.
    5052#ifdef      PLATFORM_LINUX
    51 #define     MERGE_FILE  "MBR-PROT/MBR-PROT.BIN"     // MBR protection TSR.
     53#define     MERGE_FILE  "MBR-PROT/MBR-PROT.BIN"     // MBR Protection Image.
    5254#else
    53 #define     MERGE_FILE  "MBR-PROT\\MBR-PROT.BIN"    // MBR protection TSR.
     55#define     MERGE_FILE  "MBR-PROT\\MBR-PROT.BIN"    // MBR Protection Image.
    5456#endif
    5557#define     OUT_FILE    "AIRBOOT.BIN"               // Generated loader image.
     
    158160    /*
    159161    // Find Protection Image Signature.
    160     // Note that this signature must reside on a sector boundary.
     162    // Note that this signature must reside on a sector boundary in the
     163    // AIR-BOOT.COM image.
    161164    */
    162165    for (i=0; i<55; i++) {
     
    168171
    169172    /*
    170     // Merge Protection Image.
     173    // Abort if not found.
    171174    */
    172175    printf("%s",MergeMBR);
     
    175178        exit(2);
    176179    }
     180
     181    /*
     182    // Merge Protection Image.
     183    */
    177184    memcpy(&BootCode[i*SECSIZE], MBRProtection, MBRPROT_SIZE);
    178185    printf("%s", Okay);
     
    181188    /*
    182189    // Count Code Sectors.
    183     // Obsolete now since the Protection Image has moved just below the
    184     // Configuration and the code is always max. size.
     190    // Obsolete now because since v1.0.8 the Protection Image has moved just
     191    // below the Configuration and the code is always max. size.
    185192    // Overlap checking is done while assembling AIR-BOOT.ASM.
     193    // So we just write the max. code sectors here.
    186194    */
    187195    printf("%s", CountCode);
Note: See TracChangeset for help on using the changeset viewer.