Chameleon

Chameleon Commit Details

Date:2010-08-21 02:44:06 (9 years 2 months ago)
Author:Azimutz
Commit:399
Parents: 398
Message:Same as rev 398, plus some comment cleaning.
Changes:
M/branches/azimutz/Chazileon/i386/boot2/drivers.c
M/branches/azimutz/Chazileon/i386/libsaio/acpi_patcher.c
M/branches/azimutz/Chazileon/i386/boot2/boot.c
M/branches/azimutz/Chazileon/i386/libsaio/fake_efi.c
M/branches/azimutz/Chazileon/i386/libsaio/disk.c
M/branches/azimutz/Chazileon/i386/boot2/boot.h
M/branches/azimutz/Chazileon/i386/boot2/options.c
M/branches/azimutz/Chazileon/i386/libsaio/stringTable.c

File differences

branches/azimutz/Chazileon/i386/libsaio/acpi_patcher.c
9898
9999
100100
101
102101
103102
104103
static chardirSpecDSDT[128] = "";
const char *override_pathname = NULL; // full path to a file.
intlen = 0, fd = 0;
extern char gMacOSVersion;
// Take in account user overriding if it's DSDT only
if (strstr(filename, "DSDT") &&
branches/azimutz/Chazileon/i386/libsaio/disk.c
14291429
14301430
14311431
1432
1432
14331433
14341434
14351435
//
if (bvr->flags & kBVFlagNativeBoot)
{
sprintf(dirSpec, "hd(%d,%d)/System/Library/CoreServices/", BIOS_DEV_UNIT(bvr), bvr->part_no); //Azi:sysversion
sprintf(dirSpec, "hd(%d,%d)/System/Library/CoreServices/", BIOS_DEV_UNIT(bvr), bvr->part_no);
strcpy(fileSpec, "SystemVersion.plist");
ret = GetFileInfo(dirSpec, fileSpec, &flags, &time);
branches/azimutz/Chazileon/i386/libsaio/stringTable.c
2929
3030
3131
32
32
3333
3434
3535
......
658658
659659
660660
661
662661
663662
664663
#include "bootstruct.h"
#include "libsaio.h"
#include "xml.h"
#include "boot.h" //Azi:canoverride
#include "boot.h" //Azi:canoverride, gMacOSVersion
#include "ramdisk.h" //Azi:searchalgo
extern char *Language;
const char*override_pathname = NULL;
const char*filename = "com.apple.Boot.plist";
int count, ret, fd, len = 0;
extern char gMacOSVersion;
// Take in account user overriding the override :P
if (getValueForKey(kTestConfigKey, &override_pathname, &len, &bootInfo->bootConfig))
branches/azimutz/Chazileon/i386/libsaio/fake_efi.c
630630
631631
632632
633
634633
635634
636635
chardirSpecSMBIOS[128] = "";
const char *override_pathname = NULL;
intlen = 0, fd = 0;
extern char gMacOSVersion;
extern void scan_mem();
// Take in account user overriding
branches/azimutz/Chazileon/i386/boot2/boot.c
7171
7272
7373
74
7574
7675
7776
......
399398
400399
401400
402
403
404
405401
406402
407403
......
499495
500496
501497
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516498
517499
518500
......
609591
610592
611593
612
594
613595
614596
615597
//char *gPlatformName = gCacheNameAdler; disabled
char gRootDevice[512];
char gMKextName[512];
//char gMacOSVersion[8]; //Azi:sysversion - TODO: check why doesn't work here.
bool gEnableCDROMRescan;
bool gScanSingleDrive;
longflags, cachetime, kerneltime, exttime, sleeptime, time;
void*binary = (void *)kLoadAddr;
config_file_t systemVersion;// system.plist of booting partition - Azi:sysversion
char osxVersion[8]; // replaces gMacOSVersion here, for now.
// additional variable for testing alternate kernel image locations on boot helper partitions.
charbootFileSpec[512]; //Azi:HelperConfig - kernel
}
// Other status (e.g. 0) means that we should proceed with boot.
//Azi:autoresolution old - testing
//Azi: still calling this here. The call on processBootOptions() gets hidden from verbose and
// for some reason gMacOSVersion doesn't get initialized on boot.c like on the others. Later...
// Find out which version mac os we're booting.
if (!loadConfigFile("System/Library/CoreServices/SystemVersion.plist", &systemVersion)) {
if (getValueForKey(kProductVersion, &val, &len, &systemVersion)) {
// getValueForKey uses const char for val
// so copy it and trim
strncpy(osxVersion, val, MIN(len, 4));
osxVersion[MIN(len, 4)] = '\0';
}
}
// If cpu doesn't handle 64 bit instructions,...
if (!platformCPUFeature(CPU_FEATURE_EM64T) ||
(gMKextName[0] == '\0') &&
(gBootKernelCacheFile[0] != '\0'));
verbose("Loading Darwin %s\n", osxVersion); //Azi:sysversion
verbose("Loading Darwin %s\n", gMacOSVersion);
if (trycache) do
{
branches/azimutz/Chazileon/i386/boot2/boot.h
201201
202202
203203
204
204205
205206
206207
extern bool gOverrideKernel;
//extern char *gPlatformName; disabled
extern char gMKextName[];
extern char gMacOSVersion[];
extern char gRootDevice[];
extern bool gEnableCDROMRescan;
extern bool gScanSingleDrive;
branches/azimutz/Chazileon/i386/boot2/drivers.c
164164
165165
166166
167
168167
169168
170169
char dirSpecExtra[128];
const char *override_pathfolder = NULL; // full path to a folder.
intfd = 0, len = 0;
extern char gMacOSVersion;
if ( InitDriverSupport() != 0 )
return 0;
branches/azimutz/Chazileon/i386/boot2/options.c
3030
3131
3232
33
33
3434
3535
3636
......
4444
4545
4646
47
47
4848
4949
5050
......
12631263
12641264
12651265
1266
1267
1266
1267
12681268
12691269
12701270
......
12731273
12741274
12751275
1276
1276
12771277
12781278
12791279
#include "gui.h"
#include "pci.h"
#include "ramdisk.h"
#include "sl.h" //Azi:sysversion
#include "sl.h"
#include "autoresolution.h" //Azi:autoresolution - "was" included on boot.h, which is everywere!! -> gui.h -> graphics.h
//extern intmenucount;
extern intgDeviceCount;
chargMacOSVersion[8]; //Azi:sysversion
chargMacOSVersion[8];
intselectIndex = 0;
MenuItem * menuItems = NULL;
const char * cp = gBootArgs;
const char * val = 0;
const char * kernel;
const char*value; //Azi:sysversion
int len; //Azi:sysversion
const char*value;
int len;
int cnt;
int userCnt;
int cntRemaining;
bool uuidSet = false;
char * configKernelFlags;
char * valueBuffer;
config_file_t systemVersion;//Azi:sysversion - system.plist of booting partition
config_file_t systemVersion;
valueBuffer = malloc(VALUE_SIZE);

Archive Download the corresponding diff file

Revision: 399