Port UnixPkg to also support X64. Currently only supports Unix x86_64 ABI. In the future we can make Sec support x86_64 ABI and the rest of the code support X64 EFI ABI. This will require assembly gaskets to fix the calling convention differences. I currently have noop gaskets in place for x86_64 ABI. This has only been tested on OS X 10.6.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@10685 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
andrewfish 2010-07-22 21:21:38 +00:00
parent 92a4f6f3c7
commit b9c8e50e20
22 changed files with 1188 additions and 218 deletions

View File

@ -74,7 +74,9 @@ Abstract:
// st_size is 64-bit but starts on a 32-bit offset in the structure. The compiler // st_size is 64-bit but starts on a 32-bit offset in the structure. The compiler
// flags used to produce compatible EFI images, break struct stat // flags used to produce compatible EFI images, break struct stat
// //
#ifdef MDE_CPU_IA32
#pragma pack(4) #pragma pack(4)
#endif
#if __DARWIN_64_BIT_INO_T #if __DARWIN_64_BIT_INO_T
@ -128,7 +130,10 @@ typedef struct stat_fix {
} STAT_FIX; } STAT_FIX;
#endif #endif
#pragma pack()
#ifdef MDE_CPU_IA32
#pragma pack(4)
#endif
#else #else
@ -155,40 +160,75 @@ VOID
typedef typedef
VOID VOID
(*UnixSetTimer) (UINT64 PeriodMs, VOID (*CallBack)(UINT64 DeltaMs)); (*UnixSetTimer) (
UINT64 PeriodMs,
VOID (*CallBack)(UINT64 DeltaMs)
);
typedef typedef
VOID VOID
(*UnixGetLocalTime) (EFI_TIME *Time); (*UnixGetLocalTime) (
EFI_TIME *Time
);
typedef typedef
struct tm * struct tm *
(*UnixGmTime)(const time_t *timep); (*UnixGmTime)(
const time_t *timep
);
typedef typedef
long long
(*UnixGetTimeZone)(void); (*UnixGetTimeZone)(
void
);
typedef typedef
int int
(*UnixGetDayLight)(void); (*UnixGetDayLight)(
void
);
typedef typedef
int int
(*UnixPoll)(struct pollfd *pfd, int nfds, int timeout); (*UnixPoll)(
struct pollfd *pfd,
unsigned int nfds,
int timeout
);
typedef typedef
int long
(*UnixRead) (int fd, void *buf, int count); (*UnixRead) (
int fd,
void *buf,
int count
);
typedef typedef
int long
(*UnixWrite) (int fd, const void *buf, int count); (*UnixWrite) (
int fd,
const void *buf,
int count
);
typedef typedef
char * char *
(*UnixGetenv) (const char *var); (*UnixGetenv) (const char *var);
typedef typedef
int int
(*UnixOpen) (const char *name, int flags, int mode); (*UnixOpen) (const char *name, int flags, int mode);
typedef typedef
off_t off_t
(*UnixSeek) (int fd, off_t off, int whence); (*UnixSeek) (int fd, off_t off, int whence);
typedef typedef
int int
(*UnixFtruncate) (int fd, long int len); (*UnixFtruncate) (int fd, long int len);
typedef typedef
int int
(*UnixClose) (int fd); (*UnixClose) (int fd);
@ -196,45 +236,59 @@ int
typedef typedef
int int
(*UnixMkdir)(const char *pathname, mode_t mode); (*UnixMkdir)(const char *pathname, mode_t mode);
typedef typedef
int int
(*UnixRmDir)(const char *pathname); (*UnixRmDir)(const char *pathname);
typedef typedef
int int
(*UnixUnLink)(const char *pathname); (*UnixUnLink)(const char *pathname);
typedef typedef
int int
(*UnixGetErrno)(VOID); (*UnixGetErrno)(VOID);
typedef typedef
DIR * DIR *
(*UnixOpenDir)(const char *pathname); (*UnixOpenDir)(const char *pathname);
typedef typedef
void void
(*UnixRewindDir)(DIR *dir); (*UnixRewindDir)(DIR *dir);
typedef typedef
struct dirent * struct dirent *
(*UnixReadDir)(DIR *dir); (*UnixReadDir)(DIR *dir);
typedef typedef
int int
(*UnixCloseDir)(DIR *dir); (*UnixCloseDir)(DIR *dir);
typedef typedef
int int
(*UnixStat)(const char *path, STAT_FIX *buf); (*UnixStat)(const char *path, STAT_FIX *buf);
typedef typedef
int int
(*UnixStatFs)(const char *path, struct statfs *buf); (*UnixStatFs)(const char *path, struct statfs *buf);
typedef typedef
int int
(*UnixRename)(const char *oldpath, const char *newpath); (*UnixRename)(const char *oldpath, const char *newpath);
typedef typedef
time_t time_t
(*UnixMkTime)(struct tm *tm); (*UnixMkTime)(struct tm *tm);
typedef typedef
int int
(*UnixFSync)(int fd); (*UnixFSync)(int fd);
typedef typedef
int int
(*UnixChmod)(const char *path, mode_t mode); (*UnixChmod)(const char *path, mode_t mode);
typedef typedef
int int
(*UnixUTime)(const char *filename, const struct utimbuf *buf); (*UnixUTime)(const char *filename, const struct utimbuf *buf);
@ -282,21 +336,9 @@ int
(*UnixTcsetattr) (int __fd, int __optional_actions, (*UnixTcsetattr) (int __fd, int __optional_actions,
__const struct termios *__termios_p); __const struct termios *__termios_p);
typedef
VOID *
(*UnixDlopen) (const char *FileName, int Flag);
typedef
char *
(*UnixDlerror) (VOID);
typedef
VOID *
(*UnixDlsym) (VOID* Handle, const char* Symbol);
// //
// Work functions to enable source level debug in the emulator // Worker functions to enable source level debug in the emulator
// //
typedef typedef
@ -364,9 +406,6 @@ typedef struct _EFI_UNIX_THUNK_PROTOCOL {
UnixCfsetospeed Cfsetospeed; UnixCfsetospeed Cfsetospeed;
UnixTcgetattr Tcgetattr; UnixTcgetattr Tcgetattr;
UnixTcsetattr Tcsetattr; UnixTcsetattr Tcsetattr;
UnixDlopen Dlopen;
UnixDlerror Dlerror;
UnixDlsym Dlsym;
UnixPeCoffGetEntryPoint PeCoffGetEntryPoint; UnixPeCoffGetEntryPoint PeCoffGetEntryPoint;
UnixPeCoffRelocateImageExtraAction PeCoffRelocateImageExtraAction; UnixPeCoffRelocateImageExtraAction PeCoffRelocateImageExtraAction;
UnixPeCoffLoaderUnloadImageExtraAction PeCoffUnloadImageExtraAction; UnixPeCoffLoaderUnloadImageExtraAction PeCoffUnloadImageExtraAction;

View File

@ -20,33 +20,41 @@ Abstract:
#ifndef _UNIX_UGA_IO_H_ #ifndef _UNIX_UGA_IO_H_
#define _UNIX_UGA_IO_H_ #define _UNIX_UGA_IO_H_
#define EFI_UNIX_UGA_IO_PROTOCOL_GUID \ #define EFI_UNIX_UGA_IO_PROTOCOL_GUID {0xf2e5e2c6, 0x8985, 0x11db, {0xa1, 0x91, 0x00, 0x40, 0xd0, 0x2b, 0x18, 0x35 } }
{ \
0xf2e5e2c6, 0x8985, 0x11db, {0xa1, 0x91, 0x00, 0x40, 0xd0, 0x2b, 0x18, 0x35 } \
}
struct _EFI_UNIX_UGA_IO_PROTOCOL;
typedef struct _EFI_UNIX_UGA_IO_PROTOCOL EFI_UNIX_UGA_IO_PROTOCOL; typedef struct _EFI_UNIX_UGA_IO_PROTOCOL EFI_UNIX_UGA_IO_PROTOCOL;
typedef typedef
EFI_STATUS EFI_STATUS
(*UGAClose)(EFI_UNIX_UGA_IO_PROTOCOL *Uga); (*UGAClose)(
EFI_UNIX_UGA_IO_PROTOCOL *Uga
);
typedef typedef
EFI_STATUS EFI_STATUS
(*UGASize)(EFI_UNIX_UGA_IO_PROTOCOL *Uga, UINT32 Width, UINT32 Height); (*UGASize)(
EFI_UNIX_UGA_IO_PROTOCOL *Uga,
UINT32 Width,
UINT32 Height
);
typedef typedef
EFI_STATUS EFI_STATUS
(*UGACheckKey)(EFI_UNIX_UGA_IO_PROTOCOL *Uga); (*UGACheckKey)(
EFI_UNIX_UGA_IO_PROTOCOL *Uga
);
typedef typedef
EFI_STATUS EFI_STATUS
(*UGAGetKey)(EFI_UNIX_UGA_IO_PROTOCOL *Uga, EFI_INPUT_KEY *key); (*UGAGetKey)(
EFI_UNIX_UGA_IO_PROTOCOL *Uga,
EFI_INPUT_KEY *key
);
typedef typedef
EFI_STATUS EFI_STATUS
(*UGABlt)(EFI_UNIX_UGA_IO_PROTOCOL *Uga, (*UGABlt)(
IN EFI_UNIX_UGA_IO_PROTOCOL *Uga,
IN EFI_UGA_PIXEL *BltBuffer OPTIONAL, IN EFI_UGA_PIXEL *BltBuffer OPTIONAL,
IN EFI_UGA_BLT_OPERATION BltOperation, IN EFI_UGA_BLT_OPERATION BltOperation,
IN UINTN SourceX, IN UINTN SourceX,
@ -55,7 +63,8 @@ EFI_STATUS
IN UINTN DestinationY, IN UINTN DestinationY,
IN UINTN Width, IN UINTN Width,
IN UINTN Height, IN UINTN Height,
IN UINTN Delta OPTIONAL); IN UINTN Delta OPTIONAL
);
struct _EFI_UNIX_UGA_IO_PROTOCOL { struct _EFI_UNIX_UGA_IO_PROTOCOL {
VOID *Private; VOID *Private;

View File

@ -74,20 +74,20 @@ GasketGetDayLight (void)
int int
Gasketpoll (struct pollfd *pfd, int nfds, int timeout) Gasketpoll (struct pollfd *pfd, unsigned int nfds, int timeout)
{ {
return GasketUintnUintnUintn (poll, (UINTN)pfd, nfds, timeout); return GasketUintnUintnUintn (poll, (UINTN)pfd, nfds, timeout);
} }
int long
Gasketread (int fd, void *buf, int count) Gasketread (int fd, void *buf, int count)
{ {
return GasketUintnUintnUintn (read, fd, (UINTN)buf, count); return GasketUintnUintnUintn (read, fd, (UINTN)buf, count);
} }
int long
Gasketwrite (int fd, const void *buf, int count) Gasketwrite (int fd, const void *buf, int count)
{ {
return GasketUintnUintnUintn (write, fd, (UINTN)buf, count); return GasketUintnUintnUintn (write, fd, (UINTN)buf, count);
@ -168,10 +168,11 @@ Gasketopendir (const char *pathname)
} }
void * void
Gasketrewinddir (DIR *dir) Gasketrewinddir (DIR *dir)
{ {
return (void *)(UINTN)GasketUintn (rewinddir, (UINTN)dir); GasketUintn (rewinddir, (UINTN)dir);
return;
} }
@ -372,7 +373,7 @@ GasketUnixPeCoffRelocateImageExtraAction (
VOID VOID
GasketPeCoffLoaderUnloadImageExtraAction ( GasketUnixPeCoffUnloadImageExtraAction (
IN OUT PE_COFF_LOADER_IMAGE_CONTEXT *ImageContext IN OUT PE_COFF_LOADER_IMAGE_CONTEXT *ImageContext
) )
{ {

View File

@ -33,9 +33,9 @@ void GasketGetLocalTime (EFI_TIME *Time);
struct tm *Gasketgmtime (const time_t *clock); struct tm *Gasketgmtime (const time_t *clock);
long GasketGetTimeZone (void); long GasketGetTimeZone (void);
int GasketGetDayLight (void); int GasketGetDayLight (void);
int Gasketpoll (struct pollfd *pfd, int nfds, int timeout); int Gasketpoll (struct pollfd *pfd, unsigned int nfds, int timeout);
int Gasketread (int fd, void *buf, int count); long Gasketread (int fd, void *buf, int count);
int Gasketwrite (int fd, const void *buf, int count); long Gasketwrite (int fd, const void *buf, int count);
char *Gasketgetenv (const char *name); char *Gasketgetenv (const char *name);
int Gasketopen (const char *name, int flags, int mode); int Gasketopen (const char *name, int flags, int mode);
off_t Gasketlseek (int fd, off_t off, int whence); off_t Gasketlseek (int fd, off_t off, int whence);
@ -46,7 +46,7 @@ int Gasketrmdir (const char *pathname);
int Gasketunlink (const char *pathname); int Gasketunlink (const char *pathname);
int GasketGetErrno (void); int GasketGetErrno (void);
DIR *Gasketopendir (const char *pathname); DIR *Gasketopendir (const char *pathname);
void *Gasketrewinddir (DIR *dir); void Gasketrewinddir (DIR *dir);
struct dirent *Gasketreaddir (DIR *dir); struct dirent *Gasketreaddir (DIR *dir);
int Gasketclosedir (DIR *dir); int Gasketclosedir (DIR *dir);
int Gasketstat (const char *path, STAT_FIX *buf); int Gasketstat (const char *path, STAT_FIX *buf);
@ -88,21 +88,22 @@ GasketUnixPeCoffRelocateImageExtraAction (
); );
VOID VOID
GasketPeCoffLoaderUnloadImageExtraAction ( GasketUnixPeCoffUnloadImageExtraAction (
IN OUT PE_COFF_LOADER_IMAGE_CONTEXT *ImageContext IN OUT PE_COFF_LOADER_IMAGE_CONTEXT *ImageContext
); );
int GasketVoid (void *api); UINTN GasketVoid (void *api);
int GasketUintn (void *api, UINTN a); UINTN GasketUintn (void *api, UINTN a);
int GasketUintnUintn (void *api, UINTN a, UINTN b); UINTN GasketUintnUintn (void *api, UINTN a, UINTN b);
int GasketUintnUintnUintn (void *api, UINTN a, UINTN b, UINTN c); UINTN GasketUintnUintnUintn (void *api, UINTN a, UINTN b, UINTN c);
int GasketUintnUintnUintnUintn (void *api, UINTN a, UINTN b, UINTN c, UINTN d); UINTN GasketUintnUintnUintnUintn (void *api, UINTN a, UINTN b, UINTN c, UINTN d);
int GasketUintn10Args (void *api, UINTN a, UINTN b, UINTN c, UINTN d, UINTN e, UINTN f, UINTN g, UINTN h, UINTN i, UINTN j); UINTN GasketUintn10Args (void *api, UINTN a, UINTN b, UINTN c, UINTN d, UINTN e, UINTN f, UINTN g, UINTN h, UINTN i, UINTN j);
int GasketUint64Uintn (void *api, UINT64 a, UINTN b); UINTN GasketUint64Uintn (void *api, UINT64 a, UINTN b);
UINT64 GasketUintnUint64Uintn (void *api, UINTN a, UINT64 b, UINTN c); UINT64 GasketUintnUint64Uintn (void *api, UINTN a, UINT64 b, UINTN c);
int GasketUintnUint16 (void *api, UINTN a, UINT16 b); UINTN GasketUintnUint16 (void *api, UINTN a, UINT16 b);
UINTN ReverseGasketUint64 (void *api, UINT64 a);
// //
// Gasket functions for EFI_UNIX_UGA_IO_PROTOCOL // Gasket functions for EFI_UNIX_UGA_IO_PROTOCOL

View File

@ -16,7 +16,7 @@
# on Leopard and _stat$INDOE64 on Snow Leopard. That is why we pass stat() # on Leopard and _stat$INDOE64 on Snow Leopard. That is why we pass stat()
# into one of these gaskets from C code. # into one of these gaskets from C code.
# #
# Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR> # Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
# This program and the accompanying materials # This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License # are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at # which accompanies this distribution. The full text of the license may be found at
@ -235,7 +235,23 @@ _GasketUintnUint16:
call *%eax call *%eax
leave leave
ret ret
.globl _ReverseGasketUint64
_ReverseGasketUint64:
pushl %ebp
movl %esp, %ebp
subl $56, %esp
movl 12(%ebp), %eax
movl %eax, -32(%ebp)
movl 16(%ebp), %eax
movl %eax, -28(%ebp)
movl 8(%ebp), %eax
movl %eax, -12(%ebp)
movl -32(%ebp), %eax
movl %eax, (%esp)
movl -12(%ebp), %eax
call *%eax
leave
ret
.subsections_via_symbols .subsections_via_symbols
#endif #endif

View File

@ -138,5 +138,14 @@ GasketUintnUint16 (void *api, UINTN a, UINT16 b)
return func (a, b); return func (a, b);
} }
void
ReverseGasketUint64 (void *api, UINT64 a)
{
GASKET_UINTN func;
func = (GASKET_UINTN)api;
func (a);
return;
}

View File

@ -827,7 +827,7 @@ Returns:
// If the memory buffer could not be allocated at the FD build address // If the memory buffer could not be allocated at the FD build address
// the Fixup is the difference. // the Fixup is the difference.
// //
*FixUp = *FdBase - PcdGet32 (PcdUnixFdBaseAddress); *FixUp = *FdBase - PcdGet64 (PcdUnixFdBaseAddress);
} }
return EFI_SUCCESS; return EFI_SUCCESS;

View File

@ -373,9 +373,10 @@ UgaCheckKey(EFI_UNIX_UGA_IO_PROTOCOL *UgaIo)
{ {
UGA_IO_PRIVATE *drv = (UGA_IO_PRIVATE *)UgaIo; UGA_IO_PRIVATE *drv = (UGA_IO_PRIVATE *)UgaIo;
HandleEvents(drv); HandleEvents(drv);
if (drv->key_count != 0)
if (drv->key_count != 0) {
return EFI_SUCCESS; return EFI_SUCCESS;
else { } else {
/* EFI is certainly polling. Be CPU-friendly. */ /* EFI is certainly polling. Be CPU-friendly. */
msSleep (20); msSleep (20);
return EFI_NOT_READY; return EFI_NOT_READY;
@ -631,8 +632,8 @@ EFI_STATUS EFIAPI GasketUgaBlt (
XStoreName (drv->display, drv->win, title); XStoreName (drv->display, drv->win, title);
} }
XSelectInput (drv->display, drv->win, XSelectInput (drv->display, drv->win, ExposureMask | KeyPressMask);
ExposureMask | KeyPressMask);
drv->gc = DefaultGC (drv->display, drv->screen); drv->gc = DefaultGC (drv->display, drv->screen);
*Uga = (EFI_UNIX_UGA_IO_PROTOCOL *)drv; *Uga = (EFI_UNIX_UGA_IO_PROTOCOL *)drv;

View File

@ -55,8 +55,14 @@ settimer_handler (int sig)
- ((UINT64)settimer_timeval.tv_sec * 1000) - ((UINT64)settimer_timeval.tv_sec * 1000)
- (settimer_timeval.tv_usec / 1000); - (settimer_timeval.tv_usec / 1000);
settimer_timeval = timeval; settimer_timeval = timeval;
if (settimer_callback)
(*settimer_callback)(delta); if (settimer_callback) {
#ifdef __APPLE__
ReverseGasketUint64 (settimer_callback, delta);
#else
(*settimer_callback)(delta);
#endif
}
} }
VOID VOID
@ -94,13 +100,18 @@ SetTimer (UINT64 PeriodMs, VOID (*CallBack)(UINT64 DeltaMs))
void void
msSleep (unsigned long Milliseconds) msSleep (unsigned long Milliseconds)
{ {
struct timespec ts; struct timespec rq, rm;
ts.tv_sec = Milliseconds / 1000; rq.tv_sec = Milliseconds / 1000;
ts.tv_nsec = (Milliseconds % 1000) * 1000000; rq.tv_nsec = (Milliseconds % 1000) * 1000000;
while (nanosleep (&rq, &rm) != -1) {
if (errno != EINTR) {
break;
}
rq = rm;
}
while (nanosleep (&ts, &ts) != 0 && errno == EINTR)
;
} }
void void
@ -174,20 +185,20 @@ EFI_UNIX_THUNK_PROTOCOL mUnixThunkTable = {
Gasketgmtime, Gasketgmtime,
GasketGetTimeZone, GasketGetTimeZone,
GasketGetDayLight, GasketGetDayLight,
(UnixPoll)Gasketpoll, Gasketpoll,
(UnixRead)Gasketread, Gasketread,
(UnixWrite)Gasketwrite, Gasketwrite,
Gasketgetenv, Gasketgetenv,
(UnixOpen)Gasketopen, Gasketopen,
(UnixSeek)Gasketlseek, Gasketlseek,
(UnixFtruncate)Gasketftruncate, Gasketftruncate,
Gasketclose, Gasketclose,
Gasketmkdir, Gasketmkdir,
Gasketrmdir, Gasketrmdir,
Gasketunlink, Gasketunlink,
GasketGetErrno, GasketGetErrno,
Gasketopendir, Gasketopendir,
(UnixRewindDir)Gasketrewinddir, Gasketrewinddir,
Gasketreaddir, Gasketreaddir,
Gasketclosedir, Gasketclosedir,
Gasketstat, Gasketstat,
@ -206,14 +217,9 @@ EFI_UNIX_THUNK_PROTOCOL mUnixThunkTable = {
Gasketcfsetospeed, Gasketcfsetospeed,
Gaskettcgetattr, Gaskettcgetattr,
Gaskettcsetattr, Gaskettcsetattr,
GasketUnixPeCoffGetEntryPoint,
dlopen, // Update me with a gasket GasketUnixPeCoffRelocateImageExtraAction,
dlerror, // Update me with a gasket GasketUnixPeCoffUnloadImageExtraAction
dlsym, // Update me with a gasket
SecPeCoffGetEntryPoint, // Update me with a gasket
SecPeCoffRelocateImageExtraAction, // Update me with a gasket
SecPeCoffLoaderUnloadImageExtraAction // Update me with a gasket
#else #else
msSleep, /* Sleep */ msSleep, /* Sleep */
@ -255,9 +261,6 @@ EFI_UNIX_THUNK_PROTOCOL mUnixThunkTable = {
cfsetospeed, cfsetospeed,
tcgetattr, tcgetattr,
tcsetattr, tcsetattr,
dlopen,
dlerror,
dlsym,
SecPeCoffGetEntryPoint, SecPeCoffGetEntryPoint,
SecPeCoffRelocateImageExtraAction, SecPeCoffRelocateImageExtraAction,
SecPeCoffLoaderUnloadImageExtraAction SecPeCoffLoaderUnloadImageExtraAction

View File

@ -27,10 +27,10 @@ LCFI4:
subq $32, %rsp subq $32, %rsp
LCFI5: LCFI5:
movq %rdi, -24(%rbp) movq %rdi, -24(%rbp)
movl %esi, -28(%rbp) movq %rsi, -32(%rbp)
movq -24(%rbp), %rax movq -24(%rbp), %rax
movq %rax, -8(%rbp) movq %rax, -8(%rbp)
movl -28(%rbp), %edi movq -32(%rbp), %rdi
movq -8(%rbp), %rax movq -8(%rbp), %rax
call *%rax call *%rax
leave leave
@ -43,15 +43,15 @@ LFB4:
LCFI6: LCFI6:
movq %rsp, %rbp movq %rsp, %rbp
LCFI7: LCFI7:
subq $32, %rsp subq $48, %rsp
LCFI8: LCFI8:
movq %rdi, -24(%rbp) movq %rdi, -24(%rbp)
movl %esi, -28(%rbp) movq %rsi, -32(%rbp)
movl %edx, -32(%rbp) movq %rdx, -40(%rbp)
movq -24(%rbp), %rax movq -24(%rbp), %rax
movq %rax, -8(%rbp) movq %rax, -8(%rbp)
movl -32(%rbp), %esi movq -40(%rbp), %rsi
movl -28(%rbp), %edi movq -32(%rbp), %rdi
movq -8(%rbp), %rax movq -8(%rbp), %rax
call *%rax call *%rax
leave leave
@ -67,14 +67,14 @@ LCFI10:
subq $48, %rsp subq $48, %rsp
LCFI11: LCFI11:
movq %rdi, -24(%rbp) movq %rdi, -24(%rbp)
movl %esi, -28(%rbp) movq %rsi, -32(%rbp)
movl %edx, -32(%rbp) movq %rdx, -40(%rbp)
movl %ecx, -36(%rbp) movq %rcx, -48(%rbp)
movq -24(%rbp), %rax movq -24(%rbp), %rax
movq %rax, -8(%rbp) movq %rax, -8(%rbp)
movl -36(%rbp), %edx movq -48(%rbp), %rdx
movl -32(%rbp), %esi movq -40(%rbp), %rsi
movl -28(%rbp), %edi movq -32(%rbp), %rdi
movq -8(%rbp), %rax movq -8(%rbp), %rax
call *%rax call *%rax
leave leave
@ -87,19 +87,19 @@ LFB6:
LCFI12: LCFI12:
movq %rsp, %rbp movq %rsp, %rbp
LCFI13: LCFI13:
subq $48, %rsp subq $64, %rsp
LCFI14: LCFI14:
movq %rdi, -24(%rbp) movq %rdi, -24(%rbp)
movl %esi, -28(%rbp) movq %rsi, -32(%rbp)
movl %edx, -32(%rbp) movq %rdx, -40(%rbp)
movl %ecx, -36(%rbp) movq %rcx, -48(%rbp)
movl %r8d, -40(%rbp) movq %r8, -56(%rbp)
movq -24(%rbp), %rax movq -24(%rbp), %rax
movq %rax, -8(%rbp) movq %rax, -8(%rbp)
movl -40(%rbp), %ecx movq -56(%rbp), %rcx
movl -36(%rbp), %edx movq -48(%rbp), %rdx
movl -32(%rbp), %esi movq -40(%rbp), %rsi
movl -28(%rbp), %edi movq -32(%rbp), %rdi
movq -8(%rbp), %rax movq -8(%rbp), %rax
call *%rax call *%rax
leave leave
@ -112,35 +112,35 @@ LFB7:
LCFI15: LCFI15:
movq %rsp, %rbp movq %rsp, %rbp
LCFI16: LCFI16:
subq $80, %rsp subq $96, %rsp
LCFI17: LCFI17:
movq %rdi, -24(%rbp) movq %rdi, -24(%rbp)
movl %esi, -28(%rbp) movq %rsi, -32(%rbp)
movl %edx, -32(%rbp) movq %rdx, -40(%rbp)
movl %ecx, -36(%rbp) movq %rcx, -48(%rbp)
movl %r8d, -40(%rbp) movq %r8, -56(%rbp)
movl %r9d, -44(%rbp) movq %r9, -64(%rbp)
movq -24(%rbp), %rax movq -24(%rbp), %rax
movq %rax, -8(%rbp) movq %rax, -8(%rbp)
movl -44(%rbp), %edx movq -64(%rbp), %rdx
movl -40(%rbp), %ecx movq -56(%rbp), %rcx
movl -36(%rbp), %esi movq -48(%rbp), %rsi
movl -32(%rbp), %edi movq -40(%rbp), %rdi
movl -28(%rbp), %r10d movq -32(%rbp), %r10
movl 48(%rbp), %eax movq 48(%rbp), %rax
movl %eax, 24(%rsp) movq %rax, 24(%rsp)
movl 40(%rbp), %eax movq 40(%rbp), %rax
movl %eax, 16(%rsp) movq %rax, 16(%rsp)
movl 32(%rbp), %eax movq 32(%rbp), %rax
movl %eax, 8(%rsp) movq %rax, 8(%rsp)
movl 24(%rbp), %eax movq 24(%rbp), %rax
movl %eax, (%rsp) movq %rax, (%rsp)
movq -8(%rbp), %rax movq -8(%rbp), %rax
movl 16(%rbp), %r9d movq 16(%rbp), %r9
movl %edx, %r8d movq %rdx, %r8
movl %esi, %edx movq %rsi, %rdx
movl %edi, %esi movq %rdi, %rsi
movl %r10d, %edi movq %r10, %rdi
call *%rax call *%rax
leave leave
ret ret
@ -156,10 +156,10 @@ LCFI19:
LCFI20: LCFI20:
movq %rdi, -24(%rbp) movq %rdi, -24(%rbp)
movq %rsi, -32(%rbp) movq %rsi, -32(%rbp)
movl %edx, -36(%rbp) movq %rdx, -40(%rbp)
movq -24(%rbp), %rax movq -24(%rbp), %rax
movq %rax, -8(%rbp) movq %rax, -8(%rbp)
movl -36(%rbp), %esi movq -40(%rbp), %rsi
movq -32(%rbp), %rdi movq -32(%rbp), %rdi
movq -8(%rbp), %rax movq -8(%rbp), %rax
call *%rax call *%rax
@ -176,14 +176,14 @@ LCFI22:
subq $48, %rsp subq $48, %rsp
LCFI23: LCFI23:
movq %rdi, -24(%rbp) movq %rdi, -24(%rbp)
movl %esi, -28(%rbp) movq %rsi, -32(%rbp)
movq %rdx, -40(%rbp) movq %rdx, -40(%rbp)
movl %ecx, -44(%rbp) movq %rcx, -48(%rbp)
movq -24(%rbp), %rax movq -24(%rbp), %rax
movq %rax, -8(%rbp) movq %rax, -8(%rbp)
movl -44(%rbp), %edx movq -48(%rbp), %rdx
movq -40(%rbp), %rsi movq -40(%rbp), %rsi
movl -28(%rbp), %edi movq -32(%rbp), %rdi
movq -8(%rbp), %rax movq -8(%rbp), %rax
call *%rax call *%rax
leave leave
@ -196,20 +196,39 @@ LFB10:
LCFI24: LCFI24:
movq %rsp, %rbp movq %rsp, %rbp
LCFI25: LCFI25:
subq $32, %rsp subq $48, %rsp
LCFI26: LCFI26:
movq %rdi, -24(%rbp) movq %rdi, -24(%rbp)
movl %esi, -28(%rbp) movq %rsi, -32(%rbp)
movw %dx, -32(%rbp) movw %dx, -36(%rbp)
movq -24(%rbp), %rax movq -24(%rbp), %rax
movq %rax, -8(%rbp) movq %rax, -8(%rbp)
movzwl -32(%rbp), %esi movzwl -36(%rbp), %esi
movl -28(%rbp), %edi movq -32(%rbp), %rdi
movq -8(%rbp), %rax movq -8(%rbp), %rax
call *%rax call *%rax
leave leave
ret ret
LFE10: LFE10:
.globl _ReverseGasketUint64
_ReverseGasketUint64:
LFB11:
pushq %rbp
LCFI27:
movq %rsp, %rbp
LCFI28:
subq $32, %rsp
LCFI29:
movq %rdi, -24(%rbp)
movq %rsi, -32(%rbp)
movq -24(%rbp), %rax
movq %rax, -8(%rbp)
movq -32(%rbp), %rdi
movq -8(%rbp), %rax
call *%rax
leave
ret
LFE11:
.section __TEXT,__eh_frame,coalesced,no_toc+strip_static_syms+live_support .section __TEXT,__eh_frame,coalesced,no_toc+strip_static_syms+live_support
EH_frame1: EH_frame1:
.set L$set$0,LECIE1-LSCIE1 .set L$set$0,LECIE1-LSCIE1
@ -455,4 +474,29 @@ LASFDE17:
.byte 0x6 .byte 0x6
.align 3 .align 3
LEFDE17: LEFDE17:
.globl _ReverseGasketUint64.eh
_ReverseGasketUint64.eh:
LSFDE19:
.set L$set$37,LEFDE19-LASFDE19
.long L$set$37
LASFDE19:
.long LASFDE19-EH_frame1
.quad LFB11-.
.set L$set$38,LFE11-LFB11
.quad L$set$38
.byte 0x0
.byte 0x4
.set L$set$39,LCFI27-LFB11
.long L$set$39
.byte 0xe
.byte 0x10
.byte 0x86
.byte 0x2
.byte 0x4
.set L$set$40,LCFI28-LCFI27
.long L$set$40
.byte 0xd
.byte 0x6
.align 3
LEFDE19:
.subsections_via_symbols .subsections_via_symbols

View File

@ -0,0 +1,153 @@
/** @file
Template file used to create Gasket.S
This file is built on the command line via gcc GasketTemplate.c -S
and it will create GasketTemplate.s and this was used to create
Gasket.S. This builds code for Unix ABI on both sides. To convert
to EFI ABI will require changing the code by hand
Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR>
Portions copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
http://opensource.org/licenses/bsd-license.php
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
**/
#include <stdint.h>
#include <sys/stat.h>
typedef int8_t INT8;
typedef uint8_t UINT8;
typedef int16_t INT16;
typedef uint16_t UINT16;
typedef int32_t INT32;
typedef uint32_t UINT32;
typedef int64_t INT64;
typedef uint64_t UINT64;
typedef UINT64 UINTN;
typedef UINTN (*GASKET_VOID) ();
typedef UINTN (*GASKET_UINTN) (UINTN);
typedef UINTN (*GASKET_UINTN_UINTN) (UINTN, UINTN);
typedef UINTN (*GASKET_UINTN_UINTN_UINTN) (UINTN, UINTN, UINTN);
typedef UINTN (*GASKET_UINTN_UINTN_UINTN_UINTN) (UINTN, UINTN, UINTN, UINTN);
typedef UINTN (*GASKET_UINTN_10ARGS) (UINTN, UINTN, UINTN, UINTN, UINTN, UINTN, UINTN, UINTN, UINTN, UINTN);
typedef UINTN (*GASKET_UINT64_UINTN) (UINT64, UINTN);
typedef UINT64 (*GASKET_UINTN_UINT64_UINTN) (UINTN, UINT64, UINTN);
typedef UINTN (*GASKET_UINTN_UINT16) (UINTN, UINT16);
UINTN GasketVoid (void *api);
UINTN GasketUintn (void *api, UINTN a);
UINTN GasketUintnUintn (void *api, UINTN a, UINTN b);
UINTN GasketUintnUintnUintn (void *api, UINTN a, UINTN b, UINTN c);
UINTN GasketUintnUintnUintnUintn (void *api, UINTN a, UINTN b, UINTN c, UINTN d);
UINTN GasketUintn10Args (void *api, UINTN a, UINTN b, UINTN c, UINTN d, UINTN e, UINTN f, UINTN g, UINTN h, UINTN i, UINTN j);
UINTN GasketUint64Uintn (void *api, UINT64 a, UINTN b);
UINT64 GasketUintnUiny64Uintn (void *api, UINTN a, UINT64 b, UINTN c);
UINTN GasketUintnUint16 (void *api, UINTN a, UINT16 b);
UINTN
GasketVoid (void *api)
{
GASKET_VOID func;
func = (GASKET_VOID)api;
return func ();
}
UINTN
GasketUintn (void *api, UINTN a)
{
GASKET_UINTN func;
func = (GASKET_UINTN)api;
return func (a);
}
UINTN
GasketUintnUintn (void *api, UINTN a, UINTN b)
{
GASKET_UINTN_UINTN func;
func = (GASKET_UINTN_UINTN)api;
return func (a, b);
}
UINTN
GasketUintnUintnUintn (void *api, UINTN a, UINTN b, UINTN c)
{
GASKET_UINTN_UINTN_UINTN func;
func = (GASKET_UINTN_UINTN_UINTN)api;
return func (a, b, c);
}
UINTN
GasketUintnUintnUintnUintn (void *api, UINTN a, UINTN b, UINTN c, UINTN d)
{
GASKET_UINTN_UINTN_UINTN_UINTN func;
func = (GASKET_UINTN_UINTN_UINTN_UINTN)api;
return func (a, b, c, d);
}
UINTN
GasketUintn10Args (void *api, UINTN a, UINTN b, UINTN c, UINTN d, UINTN e, UINTN f, UINTN g, UINTN h, UINTN i, UINTN j)
{
GASKET_UINTN_10ARGS func;
func = (GASKET_UINTN_10ARGS)api;
return func (a, b, c, d, e, f, g, h, i, j);
}
UINTN
GasketUint64Uintn (void *api, UINT64 a, UINTN b)
{
GASKET_UINT64_UINTN func;
func = (GASKET_UINT64_UINTN)api;
return func (a, b);
}
UINT64
GasketUintnUint64Uintn (void *api, UINTN a, UINT64 b, UINTN c)
{
GASKET_UINTN_UINT64_UINTN func;
func = (GASKET_UINTN_UINT64_UINTN)api;
return func (a, b, c);
}
UINTN
GasketUintnUint16 (void *api, UINTN a, UINT16 b)
{
GASKET_UINTN_UINT16 func;
func = (GASKET_UINTN_UINT16)api;
return func (a, b);
}
void
ReverseGasketUint64 (void *api, UINT64 a)
{
GASKET_UINTN func;
func = (GASKET_UINTN)api;
func (a);
return;
}

View File

@ -117,7 +117,7 @@ Returns:
PcdGet32 (PcdFlashNvStorageFtwSpareSize) + PcdGet32 (PcdFlashNvStorageFtwSpareSize) +
PcdGet32 (PcdUnixFlashNvStorageEventLogSize); PcdGet32 (PcdUnixFlashNvStorageEventLogSize);
BuildFvHob (FdFixUp + PcdGet32 (PcdUnixFlashNvStorageVariableBase), FdSize); BuildFvHob (FdFixUp + PcdGet64 (PcdUnixFlashNvStorageVariableBase), FdSize);
} else { } else {
// //
// For other FD's just map them in. // For other FD's just map them in.

View File

@ -83,9 +83,9 @@ Returns:
return Status; return Status;
} }
PcdSet32 (PcdFlashNvStorageVariableBase, PcdGet32 (PcdUnixFlashNvStorageVariableBase) + (UINT32)FdFixUp); PcdSet64 (PcdFlashNvStorageVariableBase64, PcdGet64 (PcdUnixFlashNvStorageVariableBase) + FdFixUp);
PcdSet32 (PcdFlashNvStorageFtwWorkingBase, PcdGet32 (PcdUnixFlashNvStorageFtwWorkingBase) + (UINT32)FdFixUp); PcdSet64 (PcdFlashNvStorageFtwWorkingBase64, PcdGet64 (PcdUnixFlashNvStorageFtwWorkingBase) + FdFixUp);
PcdSet32 (PcdFlashNvStorageFtwSpareBase, PcdGet32 (PcdUnixFlashNvStorageFtwSpareBase) + (UINT32)FdFixUp); PcdSet64 (PcdFlashNvStorageFtwSpareBase64, PcdGet64 (PcdUnixFlashNvStorageFtwSpareBase) + FdFixUp);
return EFI_SUCCESS; return EFI_SUCCESS;
} }

View File

@ -55,11 +55,11 @@
[Pcd] [Pcd]
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwWorkingSize gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwWorkingSize
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwWorkingBase gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwWorkingBase64
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareSize gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareSize
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareBase gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareBase64
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableSize gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableSize
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableBase gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableBase64
gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashNvStorageFtwWorkingBase gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashNvStorageFtwWorkingBase
gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashNvStorageFtwSpareBase gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashNvStorageFtwSpareBase

View File

@ -59,14 +59,14 @@
gEfiUnixPkgTokenSpaceGuid.PcdUnixFirmwareVolume|L"..\\Fv\\Fv_Recovery.fd"|VOID*|0x00001009 gEfiUnixPkgTokenSpaceGuid.PcdUnixFirmwareVolume|L"..\\Fv\\Fv_Recovery.fd"|VOID*|0x00001009
gEfiUnixPkgTokenSpaceGuid.PcdUnixMemorySizeForSecMain|L"64!64"|VOID*|0x0000100c gEfiUnixPkgTokenSpaceGuid.PcdUnixMemorySizeForSecMain|L"64!64"|VOID*|0x0000100c
gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashNvStorageVariableBase|0x0|UINT32|0x00001014 gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashNvStorageVariableBase|0x0|UINT64|0x00001014
gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashNvStorageFtwSpareBase|0x0|UINT32|0x00001015 gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashNvStorageFtwSpareBase|0x0|UINT64|0x00001015
gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashNvStorageFtwWorkingBase|0x0|UINT32|0x00001016 gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashNvStorageFtwWorkingBase|0x0|UINT64|0x00001016
gEfiUnixPkgTokenSpaceGuid.PcdUnixFdBaseAddress|0x0|UINT32|0x00001017 gEfiUnixPkgTokenSpaceGuid.PcdUnixFdBaseAddress|0x0|UINT64|0x00001017
gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashNvStorageEventLogBase|0x0|UINT32|0x0000100e gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashNvStorageEventLogBase|0x0|UINT64|0x0000100e
gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashNvStorageEventLogSize|0x0|UINT32|0x0000100f gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashNvStorageEventLogSize|0x0|UINT32|0x0000100f
gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashFvRecoveryBase|0x0|UINT32|0x00001010 gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashFvRecoveryBase|0x0|UINT64|0x00001010
gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashFvRecoverySize|0x0|UINT32|0x00001011 gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashFvRecoverySize|0x0|UINT32|0x00001011
gEfiUnixPkgTokenSpaceGuid.PcdUnixFirmwareFdSize|0x0|UINT32|0x00001012 gEfiUnixPkgTokenSpaceGuid.PcdUnixFirmwareFdSize|0x0|UINT32|0x00001012
gEfiUnixPkgTokenSpaceGuid.PcdUnixFirmwareBlockSize|0|UINT32|0x00001013 gEfiUnixPkgTokenSpaceGuid.PcdUnixFirmwareBlockSize|0|UINT32|0x00001013

View File

@ -27,7 +27,7 @@
PLATFORM_VERSION = 0.3 PLATFORM_VERSION = 0.3
DSC_ SPECIFICATION = 0x00010005 DSC_ SPECIFICATION = 0x00010005
OUTPUT_DIRECTORY = Build/Unix OUTPUT_DIRECTORY = Build/Unix
SUPPORTED_ARCHITECTURES = IA32|X64 SUPPORTED_ARCHITECTURES = IA32
BUILD_TARGETS = DEBUG|RELEASE BUILD_TARGETS = DEBUG|RELEASE
SKUID_IDENTIFIER = DEFAULT SKUID_IDENTIFIER = DEFAULT
FLASH_DEFINITION = UnixPkg/UnixPkg.fdf FLASH_DEFINITION = UnixPkg/UnixPkg.fdf
@ -154,6 +154,9 @@
[LibraryClasses.common.UEFI_APPLICATION] [LibraryClasses.common.UEFI_APPLICATION]
PrintLib|MdeModulePkg/Library/DxePrintLibPrint2Protocol/DxePrintLibPrint2Protocol.inf PrintLib|MdeModulePkg/Library/DxePrintLibPrint2Protocol/DxePrintLibPrint2Protocol.inf
[LibraryClasses.X64]
BaseLib|UnixPkg/Library/UnixBaseLib/UnixBaseLib.inf
################################################################################ ################################################################################
# #
# Pcd Section - list of all EDK II PCD Entries defined by this Platform. # Pcd Section - list of all EDK II PCD Entries defined by this Platform.
@ -182,24 +185,19 @@
################################################################################ ################################################################################
[PcdsDynamicDefault.common.DEFAULT] [PcdsDynamicDefault.common.DEFAULT]
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareBase|0 gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareBase64|0
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwWorkingBase|0 gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwWorkingBase64|0
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableBase|0 gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableBase64|0
gEfiGenericPlatformTokenSpaceGuid.PcdFlashNvStorageVariableBase|0x0|UINT32|4
gEfiGenericPlatformTokenSpaceGuid.PcdFlashNvStorageVariableSize|0x0|UINT32|4 gEfiUnixPkgTokenSpaceGuid.PcdUnixConsole|L"Bus Driver Console Window"
gEfiGenericPlatformTokenSpaceGuid.PcdFlashNvStorageFtwSpareBase|0x0|UINT32|4 gEfiUnixPkgTokenSpaceGuid.PcdUnixUga|L"UGA Window"
gEfiGenericPlatformTokenSpaceGuid.PcdFlashNvStorageFtwSpareSize|0x0|UINT32|4 gEfiUnixPkgTokenSpaceGuid.PcdUnixFileSystem|L".!../../../../EdkShellBinPkg/Bin/Ia32/Apps"
gEfiGenericPlatformTokenSpaceGuid.PcdFlashNvStorageFtwWorkingBase|0x0|UINT32|4 gEfiUnixPkgTokenSpaceGuid.PcdUnixVirtualDisk|L"disk1.img:FW"
gEfiGenericPlatformTokenSpaceGuid.PcdFlashNvStorageFtwWorkingSize|0x0|UINT32|4 gEfiUnixPkgTokenSpaceGuid.PcdUnixPhysicalDisk|L"E:RW;245760;512"
gEfiUnixPkgTokenSpaceGuid.PcdUnixConsole|L"Bus Driver Console Window"|VOID*|50 gEfiUnixPkgTokenSpaceGuid.PcdUnixCpuModel|L"Intel(R) Processor Model"
gEfiUnixPkgTokenSpaceGuid.PcdUnixUga|L"UGA Window"|VOID*|50 gEfiUnixPkgTokenSpaceGuid.PcdUnixCpuSpeed|L"3000"
gEfiUnixPkgTokenSpaceGuid.PcdUnixFileSystem|L".!../../../../EdkShellBinPkg/Bin/Ia32/Apps"|VOID*|106 gEfiUnixPkgTokenSpaceGuid.PcdUnixMemorySize|L"128!128"
gEfiUnixPkgTokenSpaceGuid.PcdUnixVirtualDisk|L"disk1.img:FW"|VOID*|24 gEfiUnixPkgTokenSpaceGuid.PcdUnixSerialPort|L"/dev/ttyS0!/dev/ttyS1"
gEfiUnixPkgTokenSpaceGuid.PcdUnixPhysicalDisk|L"E:RW;245760;512"|VOID*|30
gEfiUnixPkgTokenSpaceGuid.PcdUnixCpuModel|L"Intel(R) Processor Model"|VOID*|48
gEfiUnixPkgTokenSpaceGuid.PcdUnixCpuSpeed|L"3000"|VOID*|8
gEfiUnixPkgTokenSpaceGuid.PcdUnixMemorySize|L"64!64"|VOID*|10
gEfiUnixPkgTokenSpaceGuid.PcdUnixSerialPort|L"/dev/ttyS0!/dev/ttyS1"|VOID*|20
[PcdsDynamicHii.common.DEFAULT] [PcdsDynamicHii.common.DEFAULT]
gEfiMdeModulePkgTokenSpaceGuid.PcdConOutColumn|L"Setup"|gEfiUnixSystemConfigGuid|0x0|80 gEfiMdeModulePkgTokenSpaceGuid.PcdConOutColumn|L"Setup"|gEfiUnixSystemConfigGuid|0x0|80

View File

@ -243,43 +243,22 @@ INF MdeModulePkg/Application/HelloWorld/HelloWorld.inf
#INF MdeModulePkg/Universal/Network/Udp4Dxe/Udp4Dxe.inf #INF MdeModulePkg/Universal/Network/Udp4Dxe/Udp4Dxe.inf
#INF UnixPkg/SnpUnixDxe/SnpUnixDxe.inf #INF UnixPkg/SnpUnixDxe/SnpUnixDxe.inf
#
# Build from source or use checked in binary
#
#INF FatPkg/EnhancedFatDxe/Fat.inf #INF FatPkg/EnhancedFatDxe/Fat.inf
INF RuleOverride = BINARY USE = IA32 FatBinPkg/EnhancedFatDxe/Fat.inf
# If you build GccShellPkg you can source level debug shell
#FILE APPLICATION = PCD(gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdShellFile) {
# SECTION PE32 =Build/GccShellPkg/DEBUG_XCODE32/IA32/ShellFull.efi
#}
INF RuleOverride = BINARY USE = IA32 EdkShellBinPkg/FullShell/FullShell.inf
################################################################################
#
# FILE statements are provided so that a platform integrator can include
# complete EFI FFS files, as well as a method for constructing FFS files
# using curly "{}" brace scoping. The following three FILEs are
# for binary shell, binary fat and logo module.
#
################################################################################
FILE APPLICATION = PCD(gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdShellFile) {
SECTION COMPRESS PI_STD {
SECTION GUIDED {
SECTION PE32 = EdkShellBinPkg/FullShell/Ia32/Shell_Full.efi
# SECTION PE32 =Build/GccShellPkg/DEBUG_XCODE32/IA32/ShellFull.efi
# SECTION PE32 = Build/Unix/DEBUG_XCODE32/IA32/Ebl.efi
}
}
}
FILE DRIVER = 961578FE-B6B7-44c3-AF35-6BC705CD2B1F {
SECTION COMPRESS PI_STD {
SECTION GUIDED {
SECTION PE32 = FatBinPkg/EnhancedFatDxe/Ia32/Fat.efi
}
}
}
FILE FREEFORM = PCD(gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdLogoFile) { FILE FREEFORM = PCD(gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdLogoFile) {
SECTION COMPRESS PI_STD { SECTION RAW = MdeModulePkg/Logo/Logo.bmp
SECTION GUIDED { }
SECTION RAW = MdeModulePkg/Logo/Logo.bmp
}
}
}
################################################################################ ################################################################################
@ -380,3 +359,20 @@ FILE FREEFORM = PCD(gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdLogoFile) {
} }
} }
} }
[Rule.Common.UEFI_DRIVER.BINARY]
FILE DRIVER = $(NAMED_GUID) {
DXE_DEPEX DXE_DEPEX Optional |.depex
PE32 PE32 |.efi
UI STRING="$(MODULE_NAME)" Optional
VERSION STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
}
[Rule.Common.UEFI_APPLICATION.BINARY]
FILE APPLICATION = $(NAMED_GUID) {
PE32 PE32 |.efi
UI STRING="$(MODULE_NAME)" Optional
VERSION STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
}

324
UnixPkg/UnixPkgX64.dsc Normal file
View File

@ -0,0 +1,324 @@
## @file
#
# EFI/Framework Emulation Platform with UEFI HII interface supported.
#
# The Emulation Platform can be used to debug individual modules, prior to creating
# a real platform. This also provides an example for how an DSC is created.
# Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
##
################################################################################
#
# Defines Section - statements that will be processed to create a Makefile.
#
################################################################################
[Defines]
PLATFORM_NAME = Unix
PLATFORM_GUID = 7b3c1fb4-8986-11db-b5b2-0040d02b1835
PLATFORM_VERSION = 0.3
DSC_ SPECIFICATION = 0x00010005
OUTPUT_DIRECTORY = Build/UnixX64
SUPPORTED_ARCHITECTURES = X64
BUILD_TARGETS = DEBUG|RELEASE
SKUID_IDENTIFIER = DEFAULT
FLASH_DEFINITION = UnixPkg/UnixPkgX64.fdf
################################################################################
#
# SKU Identification section - list of all SKU IDs supported by this Platform.
#
################################################################################
[SkuIds]
0|DEFAULT
################################################################################
#
# Library Class section - list of all Library Classes needed by this Platform.
#
################################################################################
[LibraryClasses]
#
# Entry point
#
PeiCoreEntryPoint|MdePkg/Library/PeiCoreEntryPoint/PeiCoreEntryPoint.inf
PeimEntryPoint|MdePkg/Library/PeimEntryPoint/PeimEntryPoint.inf
DxeCoreEntryPoint|MdePkg/Library/DxeCoreEntryPoint/DxeCoreEntryPoint.inf
UefiDriverEntryPoint|MdePkg/Library/UefiDriverEntryPoint/UefiDriverEntryPoint.inf
UefiApplicationEntryPoint|MdePkg/Library/UefiApplicationEntryPoint/UefiApplicationEntryPoint.inf
#
# Basic
#
BaseLib|MdePkg/Library/BaseLib/BaseLib.inf
SynchronizationLib|MdePkg/Library/BaseSynchronizationLib/BaseSynchronizationLib.inf
PrintLib|MdePkg/Library/BasePrintLib/BasePrintLib.inf
CacheMaintenanceLib|MdePkg/Library/BaseCacheMaintenanceLib/BaseCacheMaintenanceLib.inf
PeCoffLib|MdePkg/Library/BasePeCoffLib/BasePeCoffLib.inf
PeCoffGetEntryPointLib|MdePkg/Library/BasePeCoffGetEntryPointLib/BasePeCoffGetEntryPointLib.inf
PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf
BaseMemoryLib|MdePkg/Library/BaseMemoryLib/BaseMemoryLib.inf
#
# UEFI & PI
#
UefiBootServicesTableLib|MdePkg/Library/UefiBootServicesTableLib/UefiBootServicesTableLib.inf
UefiRuntimeServicesTableLib|MdePkg/Library/UefiRuntimeServicesTableLib/UefiRuntimeServicesTableLib.inf
UefiRuntimeLib|MdePkg/Library/UefiRuntimeLib/UefiRuntimeLib.inf
UefiLib|MdePkg/Library/UefiLib/UefiLib.inf
UefiHiiServicesLib|MdeModulePkg/Library/UefiHiiServicesLib/UefiHiiServicesLib.inf
HiiLib|MdeModulePkg/Library/UefiHiiLib/UefiHiiLib.inf
DevicePathLib|MdePkg/Library/UefiDevicePathLib/UefiDevicePathLib.inf
UefiDecompressLib|IntelFrameworkModulePkg/Library/BaseUefiTianoCustomDecompressLib/BaseUefiTianoCustomDecompressLib.inf
PeiServicesTablePointerLib|MdePkg/Library/PeiServicesTablePointerLib/PeiServicesTablePointerLib.inf
PeiServicesLib|MdePkg/Library/PeiServicesLib/PeiServicesLib.inf
DxeServicesLib|MdePkg/Library/DxeServicesLib/DxeServicesLib.inf
DxeServicesTableLib|MdePkg/Library/DxeServicesTableLib/DxeServicesTableLib.inf
#
# Generic Modules
#
UefiScsiLib|MdePkg/Library/UefiScsiLib/UefiScsiLib.inf
NetLib|MdeModulePkg/Library/DxeNetLib/DxeNetLib.inf
IpIoLib|MdeModulePkg/Library/DxeIpIoLib/DxeIpIoLib.inf
UdpIoLib|MdeModulePkg/Library/DxeUdpIoLib/DxeUdpIoLib.inf
DpcLib|MdeModulePkg/Library/DxeDpcLib/DxeDpcLib.inf
OemHookStatusCodeLib|MdeModulePkg/Library/OemHookStatusCodeLibNull/OemHookStatusCodeLibNull.inf
GenericBdsLib|IntelFrameworkModulePkg/Library/GenericBdsLib/GenericBdsLib.inf
SecurityManagementLib|MdeModulePkg/Library/DxeSecurityManagementLib/DxeSecurityManagementLib.inf
TimerLib|MdePkg/Library/BaseTimerLibNullTemplate/BaseTimerLibNullTemplate.inf
SerialPortLib|MdePkg/Library/BaseSerialPortLibNull/BaseSerialPortLibNull.inf
CapsuleLib|MdeModulePkg/Library/DxeCapsuleLibNull/DxeCapsuleLibNull.inf
#
# Platform
#
PlatformBdsLib|UnixPkg/Library/UnixBdsLib/PlatformBds.inf
#
# Misc
#
DebugLib|IntelFrameworkModulePkg/Library/PeiDxeDebugLibReportStatusCode/PeiDxeDebugLibReportStatusCode.inf
PerformanceLib|MdePkg/Library/BasePerformanceLibNull/BasePerformanceLibNull.inf
DebugAgentLib|MdeModulePkg/Library/DebugAgentLibNull/DebugAgentLibNull.inf
[LibraryClasses.common.USER_DEFINED]
DebugLib|MdePkg/Library/BaseDebugLibNull/BaseDebugLibNull.inf
PeCoffExtraActionLib|MdePkg/Library/BasePeCoffExtraActionLibNull/BasePeCoffExtraActionLibNull.inf
ReportStatusCodeLib|MdeModulePkg/Library/PeiReportStatusCodeLib/PeiReportStatusCodeLib.inf
OemHookStatusCodeLib|UnixPkg/Library/PeiUnixOemHookStatusCodeLib/PeiUnixOemHookStatusCodeLib.inf
MemoryAllocationLib|MdePkg/Library/PeiMemoryAllocationLib/PeiMemoryAllocationLib.inf
[LibraryClasses.common.PEIM, LibraryClasses.common.PEI_CORE]
HobLib|MdePkg/Library/PeiHobLib/PeiHobLib.inf
MemoryAllocationLib|MdePkg/Library/PeiMemoryAllocationLib/PeiMemoryAllocationLib.inf
ReportStatusCodeLib|MdeModulePkg/Library/PeiReportStatusCodeLib/PeiReportStatusCodeLib.inf
PeCoffGetEntryPointLib|UnixPkg/Library/EdkUnixPeiPeCoffGetEntryPointLib/EdkUnixPeiPeCoffGetEntryPointLib.inf
PeCoffExtraActionLib|UnixPkg/Library/PeiUnixPeCoffExtraActionLib/PeiUnixPeCoffExtraActionLib.inf
ExtractGuidedSectionLib|MdePkg/Library/PeiExtractGuidedSectionLib/PeiExtractGuidedSectionLib.inf
[LibraryClasses.common.PEIM]
PcdLib|MdePkg/Library/PeiPcdLib/PeiPcdLib.inf
OemHookStatusCodeLib|UnixPkg/Library/PeiUnixOemHookStatusCodeLib/PeiUnixOemHookStatusCodeLib.inf
[LibraryClasses.common.PEI_CORE]
PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf
[LibraryClasses.common.DXE_CORE]
HobLib|MdePkg/Library/DxeCoreHobLib/DxeCoreHobLib.inf
MemoryAllocationLib|MdeModulePkg/Library/DxeCoreMemoryAllocationLib/DxeCoreMemoryAllocationLib.inf
ReportStatusCodeLib|MdeModulePkg/Library/DxeReportStatusCodeLib/DxeReportStatusCodeLib.inf
PeCoffExtraActionLib|UnixPkg/Library/DxeUnixPeCoffExtraActionLib/DxeUnixPeCoffExtraActionLib.inf
ExtractGuidedSectionLib|MdePkg/Library/DxeExtractGuidedSectionLib/DxeExtractGuidedSectionLib.inf
[LibraryClasses.common.DXE_SMM_DRIVER]
HobLib|MdePkg/Library/DxeHobLib/DxeHobLib.inf
PcdLib|MdePkg/Library/DxePcdLib/DxePcdLib.inf
MemoryAllocationLib|MdePkg/Library/SmmMemoryAllocationLib/SmmMemoryAllocationLib.inf
ReportStatusCodeLib|MdeModulePkg/Library/DxeReportStatusCodeLib/DxeReportStatusCodeLib.inf
OemHookStatusCodeLib|UnixPkg/Library/DxeUnixOemHookStatusCodeLib/DxeUnixOemHookStatusCodeLib.inf
DebugLib|MdePkg/Library/BaseDebugLibNull/BaseDebugLibNull.inf
[LibraryClasses.common.DXE_RUNTIME_DRIVER, LibraryClasses.common.UEFI_DRIVER, LibraryClasses.common.DXE_DRIVER, LibraryClasses.common.UEFI_APPLICATION]
HobLib|MdePkg/Library/DxeHobLib/DxeHobLib.inf
PcdLib|MdePkg/Library/DxePcdLib/DxePcdLib.inf
MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf
ReportStatusCodeLib|MdeModulePkg/Library/DxeReportStatusCodeLib/DxeReportStatusCodeLib.inf
UnixLib|UnixPkg/Library/DxeUnixLib/DxeUnixLib.inf
OemHookStatusCodeLib|UnixPkg/Library/DxeUnixOemHookStatusCodeLib/DxeUnixOemHookStatusCodeLib.inf
PeCoffExtraActionLib|UnixPkg/Library/DxeUnixPeCoffExtraActionLib/DxeUnixPeCoffExtraActionLib.inf
[LibraryClasses.common.UEFI_APPLICATION]
PrintLib|MdeModulePkg/Library/DxePrintLibPrint2Protocol/DxePrintLibPrint2Protocol.inf
[LibraryClasses.X64]
BaseLib|UnixPkg/Library/UnixBaseLib/UnixBaseLib.inf
################################################################################
#
# Pcd Section - list of all EDK II PCD Entries defined by this Platform.
#
################################################################################
[PcdsFeatureFlag]
gEfiMdeModulePkgTokenSpaceGuid.PcdDxeIplSwitchToLongMode|FALSE
gEfiMdeModulePkgTokenSpaceGuid.PcdStatusCodeUseSerial|FALSE
gEfiMdeModulePkgTokenSpaceGuid.PcdPeiCoreImageLoaderSearchTeSectionFirst|FALSE
gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdStatusCodeUseOEM|TRUE
[PcdsFixedAtBuild]
gEfiMdePkgTokenSpaceGuid.PcdDebugPrintErrorLevel|0x80000040
gEfiMdePkgTokenSpaceGuid.PcdReportStatusCodePropertyMask|0x0f
gEfiMdePkgTokenSpaceGuid.PcdDebugPropertyMask|0x1f
gEfiMdeModulePkgTokenSpaceGuid.PcdMaxSizeNonPopulateCapsule|0x0
gEfiMdeModulePkgTokenSpaceGuid.PcdMaxSizePopulateCapsule|0x0
gEfiUnixPkgTokenSpaceGuid.PcdUnixFirmwareFdSize|0x002a0000
gEfiUnixPkgTokenSpaceGuid.PcdUnixFirmwareBlockSize|0x10000
gEfiUnixPkgTokenSpaceGuid.PcdUnixFirmwareVolume|L"../FV/FV_RECOVERY.fd"
################################################################################
#
# Pcd Dynamic Section - list of all EDK II PCD Entries defined by this Platform
#
################################################################################
[PcdsDynamicDefault.common.DEFAULT]
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareBase64|0
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwWorkingBase64|0
gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableBase64|0
gEfiUnixPkgTokenSpaceGuid.PcdUnixConsole|L"Bus Driver Console Window"
gEfiUnixPkgTokenSpaceGuid.PcdUnixUga|L"UGA Window"
gEfiUnixPkgTokenSpaceGuid.PcdUnixFileSystem|L".!../../../../EdkShellBinPkg/Bin/Ia32/Apps"
gEfiUnixPkgTokenSpaceGuid.PcdUnixVirtualDisk|L"disk1.img:FW"
gEfiUnixPkgTokenSpaceGuid.PcdUnixPhysicalDisk|L"E:RW;245760;512"
gEfiUnixPkgTokenSpaceGuid.PcdUnixCpuModel|L"Intel(R) Processor Model"
gEfiUnixPkgTokenSpaceGuid.PcdUnixCpuSpeed|L"3000"
gEfiUnixPkgTokenSpaceGuid.PcdUnixMemorySize|L"128!128"
gEfiUnixPkgTokenSpaceGuid.PcdUnixSerialPort|L"/dev/ttyS0!/dev/ttyS1"
[PcdsDynamicHii.common.DEFAULT]
gEfiMdeModulePkgTokenSpaceGuid.PcdConOutColumn|L"Setup"|gEfiUnixSystemConfigGuid|0x0|80
gEfiMdeModulePkgTokenSpaceGuid.PcdConOutRow|L"Setup"|gEfiUnixSystemConfigGuid|0x4|25
gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdPlatformBootTimeOut|L"Timeout"|gEfiGlobalVariableGuid|0x0|10
###################################################################################################
#
# Components Section - list of the modules and components that will be processed by compilation
# tools and the EDK II tools to generate PE32/PE32+/Coff image files.
#
# Note: The EDK II DSC file is not used to specify how compiled binary images get placed
# into firmware volume images. This section is just a list of modules to compile from
# source into UEFI-compliant binaries.
# It is the FDF file that contains information on combining binary files into firmware
# volume images, whose concept is beyond UEFI and is described in PI specification.
# Binary modules do not need to be listed in this section, as they should be
# specified in the FDF file. For example: Shell binary (Shell_Full.efi), FAT binary (Fat.efi),
# Logo (Logo.bmp), and etc.
# There may also be modules listed in this section that are not required in the FDF file,
# When a module listed here is excluded from FDF file, then UEFI-compliant binary will be
# generated for it, but the binary will not be put into any firmware volume.
#
###################################################################################################
[Components.common]
##
# SEC Phase modules
##
UnixPkg/Sec/SecMain.inf
##
# PEI Phase modules
##
MdeModulePkg/Core/Pei/PeiMain.inf
MdeModulePkg/Universal/PCD/Pei/Pcd.inf {
<LibraryClasses>
PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf
}
IntelFrameworkModulePkg/Universal/StatusCode/Pei/StatusCodePei.inf
UnixPkg/BootModePei/BootModePei.inf
UnixPkg/UnixFlashMapPei/FlashMap.inf
MdeModulePkg/Universal/Variable/Pei/VariablePei.inf
UnixPkg/UnixAutoScanPei/UnixAutoScan.inf
UnixPkg/UnixFirmwareVolumePei/UnixFwh.inf
UnixPkg/UnixThunkPpiToProtocolPei/UnixThunkPpiToProtocol.inf
MdeModulePkg/Core/DxeIplPeim/DxeIpl.inf
##
# DXE Phase modules
##
MdeModulePkg/Core/Dxe/DxeMain.inf {
<LibraryClasses>
NULL|MdeModulePkg/Library/DxeCrc32GuidedSectionExtractLib/DxeCrc32GuidedSectionExtractLib.inf
}
MdeModulePkg/Universal/PCD/Dxe/Pcd.inf {
<LibraryClasses>
PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf
}
UnixPkg/MetronomeDxe/Metronome.inf
UnixPkg/RealTimeClockRuntimeDxe/RealTimeClock.inf
UnixPkg/ResetRuntimeDxe/Reset.inf
MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
UnixPkg/FvbServicesRuntimeDxe/UnixFwh.inf
MdeModulePkg/Universal/SecurityStubDxe/SecurityStubDxe.inf
MdeModulePkg/Universal/EbcDxe/EbcDxe.inf
MdeModulePkg/Universal/MemoryTest/NullMemoryTestDxe/NullMemoryTestDxe.inf
UnixPkg/UnixThunkDxe/UnixThunk.inf
UnixPkg/CpuRuntimeDxe/Cpu.inf
MdeModulePkg/Universal/FaultTolerantWriteDxe/FaultTolerantWriteDxe.inf
UnixPkg/MiscSubClassPlatformDxe/MiscSubClassDriver.inf
UnixPkg/TimerDxe/Timer.inf
IntelFrameworkModulePkg/Universal/StatusCode/RuntimeDxe/StatusCodeRuntimeDxe.inf
MdeModulePkg/Universal/Variable/RuntimeDxe/VariableRuntimeDxe.inf
MdeModulePkg/Universal/WatchdogTimerDxe/WatchdogTimer.inf
MdeModulePkg/Universal/MonotonicCounterRuntimeDxe/MonotonicCounterRuntimeDxe.inf
MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf
MdeModulePkg/Universal/Console/ConPlatformDxe/ConPlatformDxe.inf
MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterDxe.inf
MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsoleDxe.inf
MdeModulePkg/Universal/Console/TerminalDxe/TerminalDxe.inf
IntelFrameworkModulePkg/Universal/BdsDxe/BdsDxe.inf
MdeModulePkg/Universal/DevicePathDxe/DevicePathDxe.inf
MdeModulePkg/Universal/Disk/DiskIoDxe/DiskIoDxe.inf
MdeModulePkg/Universal/Disk/PartitionDxe/PartitionDxe.inf
MdeModulePkg/Universal/Disk/UnicodeCollation/EnglishDxe/EnglishDxe.inf
MdeModulePkg/Bus/Pci/PciBusDxe/PciBusDxe.inf
MdeModulePkg/Bus/Scsi/ScsiBusDxe/ScsiBusDxe.inf
MdeModulePkg/Bus/Scsi/ScsiDiskDxe/ScsiDiskDxe.inf
IntelFrameworkModulePkg/Bus/Pci/IdeBusDxe/IdeBusDxe.inf
UnixPkg/UnixBusDriverDxe/UnixBusDriver.inf
UnixPkg/UnixBlockIoDxe/UnixBlockIo.inf
UnixPkg/UnixSerialIoDxe/UnixSerialIo.inf
UnixPkg/UnixUgaDxe/UnixUga.inf
UnixPkg/UnixConsoleDxe/UnixConsole.inf
UnixPkg/UnixSimpleFileSystemDxe/UnixSimpleFileSystem.inf
MdeModulePkg/Application/HelloWorld/HelloWorld.inf
#
# Network stack drivers
# To test network drivers, need network Io driver(SnpNt32Io.dll), please refer to NETWORK-IO Subproject.
#
MdeModulePkg/Universal/Network/DpcDxe/DpcDxe.inf
MdeModulePkg/Universal/Network/ArpDxe/ArpDxe.inf
MdeModulePkg/Universal/Network/Dhcp4Dxe/Dhcp4Dxe.inf
MdeModulePkg/Universal/Network/Ip4ConfigDxe/Ip4ConfigDxe.inf
MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Dxe.inf
MdeModulePkg/Universal/Network/MnpDxe/MnpDxe.inf
MdeModulePkg/Universal/Network/VlanConfigDxe/VlanConfigDxe.inf
MdeModulePkg/Universal/Network/Mtftp4Dxe/Mtftp4Dxe.inf
MdeModulePkg/Universal/Network/Tcp4Dxe/Tcp4Dxe.inf
MdeModulePkg/Universal/Network/Udp4Dxe/Udp4Dxe.inf
MdeModulePkg/Universal/SmbiosDxe/SmbiosDxe.inf
MdeModulePkg/Universal/HiiDatabaseDxe/HiiDatabaseDxe.inf
MdeModulePkg/Universal/SetupBrowserDxe/SetupBrowserDxe.inf
MdeModulePkg/Universal/PrintDxe/PrintDxe.inf
MdeModulePkg/Universal/DriverSampleDxe/DriverSampleDxe.inf {
<LibraryClasses>
PcdLib|MdePkg/Library/BasePcdLibNull/BasePcdLibNull.inf
}
FatPkg/EnhancedFatDxe/Fat.inf

376
UnixPkg/UnixPkgX64.fdf Normal file
View File

@ -0,0 +1,376 @@
## @file
# This is Unix FDF file with UEFI HII features enabled
#
# Copyright (c) 2008 - 2010, Intel Corporation. All rights reserved.<BR>
#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
# which accompanies this distribution. The full text of the license may be found at
# http://opensource.org/licenses/bsd-license.php
#
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#
################################################################################
#
# FD Section
# The [FD] Section is made up of the definition statements and a
# description of what goes into the Flash Device Image. Each FD section
# defines one flash "device" image. A flash device image may be one of
# the following: Removable media bootable image (like a boot floppy
# image,) an Option ROM image (that would be "flashed" into an add-in
# card,) a System "Flash" image (that would be burned into a system's
# flash) or an Update ("Capsule") image that will be used to update and
# existing system flash.
#
################################################################################
[FD.Fv_Recovery]
#
# In OS X PEIMs are really XIP, so we need to make this address match the malloced
# buffer for the FD (0x41000000). If this address does not match the FV will get
# relocated in place (works, but not a great idea).
#
BaseAddress = 0x41000000|gEfiUnixPkgTokenSpaceGuid.PcdUnixFdBaseAddress #The base address of the FLASH Device.
Size = 0x004a0000|gEfiUnixPkgTokenSpaceGuid.PcdUnixFirmwareFdSize #The size in bytes of the FLASH Device
ErasePolarity = 1
BlockSize = 0x10000
NumBlocks = 0x4a
################################################################################
#
# Following are lists of FD Region layout which correspond to the locations of different
# images within the flash device.
#
# Regions must be defined in ascending order and may not overlap.
#
# A Layout Region start with a eight digit hex offset (leading "0x" required) followed by
# the pipe "|" character, followed by the size of the region, also in hex with the leading
# "0x" characters. Like:
# Offset|Size
# PcdOffsetCName|PcdSizeCName
# RegionType <FV, DATA, or FILE>
#
################################################################################
0x00000000|0x00480000
gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashFvRecoveryBase|gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashFvRecoverySize
FV = FvRecovery
0x00480000|0x0000c000
gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashNvStorageVariableBase|gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableSize
#NV_VARIABLE_STORE
DATA = {
## This is the EFI_FIRMWARE_VOLUME_HEADER
# ZeroVector []
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
# FileSystemGuid: gEfiSystemNvDataFvGuid =
# { 0xFFF12B8D, 0x7696, 0x4C8B, { 0xA9, 0x85, 0x27, 0x47, 0x07, 0x5B, 0x4F, 0x50 }}
0x8D, 0x2B, 0xF1, 0xFF, 0x96, 0x76, 0x8B, 0x4C,
0xA9, 0x85, 0x27, 0x47, 0x07, 0x5B, 0x4F, 0x50,
# FvLength: 0x20000
0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00,
# Signature "_FVH" #Attributes
0x5f, 0x46, 0x56, 0x48, 0xff, 0xfe, 0x04, 0x00,
# HeaderLength #CheckSum #ExtHeaderOffset #Reserved #Revision
0x48, 0x00, 0x36, 0x09, 0x00, 0x00, 0x00, 0x02,
# Blockmap[0]: 2 Blocks * 0x10000 Bytes / Block
0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00,
# Blockmap[1]: End
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
## This is the VARIABLE_STORE_HEADER
#Signature: gEfiVariableGuid =
# { 0xddcf3616, 0x3275, 0x4164, { 0x98, 0xb6, 0xfe, 0x85, 0x70, 0x7f, 0xfe, 0x7d }}
0x16, 0x36, 0xcf, 0xdd, 0x75, 0x32, 0x64, 0x41,
0x98, 0xb6, 0xfe, 0x85, 0x70, 0x7f, 0xfe, 0x7d,
#Size: 0xc000 (gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableSize) - 0x48 (size of EFI_FIRMWARE_VOLUME_HEADER) = 0xBFB8
# This can speed up the Variable Dispatch a bit.
0xB8, 0xBF, 0x00, 0x00,
#FORMATTED: 0x5A #HEALTHY: 0xFE #Reserved: UINT16 #Reserved1: UINT32
0x5A, 0xFE, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
}
0x0048c000|0x00002000
#NV_EVENT_LOG
gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashNvStorageEventLogBase|gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashNvStorageEventLogSize
0x0048e000|0x00002000
gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashNvStorageFtwWorkingBase|gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwWorkingSize
#NV_FTW_WORKING
DATA = {
# EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER->Signature = gEfiSystemNvDataFvGuid =
# { 0xFFF12B8D, 0x7696, 0x4C8B, { 0xA9, 0x85, 0x27, 0x47, 0x07, 0x5B, 0x4F, 0x50 }}
0x8D, 0x2B, 0xF1, 0xFF, 0x96, 0x76, 0x8B, 0x4C,
0xA9, 0x85, 0x27, 0x47, 0x07, 0x5B, 0x4F, 0x50,
# Crc:UINT32 #WorkingBlockValid:1, WorkingBlockInvalid:1, Reserved
0x77, 0x13, 0x9B, 0xD7, 0xFE, 0xFF, 0xFF, 0xFF,
# WriteQueueSize: UINT64
0xE0, 0x1F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
}
0x00490000|0x00010000
#NV_FTW_SPARE
gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashNvStorageFtwSpareBase|gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareSize
################################################################################
#
# FV Section
#
# [FV] section is used to define what components or modules are placed within a flash
# device file. This section also defines order the components and modules are positioned
# within the image. The [FV] section consists of define statements, set statements and
# module statements.
#
################################################################################
[FV.FvRecovery]
FvAlignment = 16 #FV alignment and FV attributes setting.
ERASE_POLARITY = 1
MEMORY_MAPPED = TRUE
STICKY_WRITE = TRUE
LOCK_CAP = TRUE
LOCK_STATUS = TRUE
WRITE_DISABLED_CAP = TRUE
WRITE_ENABLED_CAP = TRUE
WRITE_STATUS = TRUE
WRITE_LOCK_CAP = TRUE
WRITE_LOCK_STATUS = TRUE
READ_DISABLED_CAP = TRUE
READ_ENABLED_CAP = TRUE
READ_STATUS = TRUE
READ_LOCK_CAP = TRUE
READ_LOCK_STATUS = TRUE
################################################################################
#
# The INF statements point to EDK component and EDK II module INF files, which will be placed into this FV image.
# Parsing tools will scan the INF file to determine the type of component or module.
# The component or module type is used to reference the standard rules
# defined elsewhere in the FDF file.
#
# The format for INF statements is:
# INF $(PathAndInfFileName)
#
################################################################################
##
# PEI Phase modules
##
##
# PEI Apriori file example, more PEIM module added later.
##
APRIORI PEI {
INF MdeModulePkg/Universal/PCD/Pei/Pcd.inf
INF IntelFrameworkModulePkg/Universal/StatusCode/Pei/StatusCodePei.inf
}
APRIORI DXE {
INF MdeModulePkg/Universal/PCD/Dxe/Pcd.inf
INF IntelFrameworkModulePkg/Universal/StatusCode/RuntimeDxe/StatusCodeRuntimeDxe.inf
INF UnixPkg/MetronomeDxe/Metronome.inf
}
INF MdeModulePkg/Core/Pei/PeiMain.inf
INF MdeModulePkg/Universal/PCD/Pei/Pcd.inf
INF IntelFrameworkModulePkg/Universal/StatusCode/Pei/StatusCodePei.inf
INF UnixPkg/BootModePei/BootModePei.inf
INF UnixPkg/UnixFlashMapPei/FlashMap.inf
INF UnixPkg/UnixAutoScanPei/UnixAutoScan.inf
INF UnixPkg/UnixFirmwareVolumePei/UnixFwh.inf
INF MdeModulePkg/Universal/Variable/Pei/VariablePei.inf
INF UnixPkg/UnixThunkPpiToProtocolPei/UnixThunkPpiToProtocol.inf
INF MdeModulePkg/Core/DxeIplPeim/DxeIpl.inf
##
# DXE Phase modules
##
INF MdeModulePkg/Core/Dxe/DxeMain.inf
INF IntelFrameworkModulePkg/Universal/StatusCode/RuntimeDxe/StatusCodeRuntimeDxe.inf
INF MdeModulePkg/Universal/PCD/Dxe/Pcd.inf
INF UnixPkg/MetronomeDxe/Metronome.inf
INF UnixPkg/RealTimeClockRuntimeDxe/RealTimeClock.inf
INF UnixPkg/ResetRuntimeDxe/Reset.inf
INF MdeModulePkg/Core/RuntimeDxe/RuntimeDxe.inf
INF UnixPkg/FvbServicesRuntimeDxe/UnixFwh.inf
INF MdeModulePkg/Universal/SecurityStubDxe/SecurityStubDxe.inf
INF MdeModulePkg/Universal/EbcDxe/EbcDxe.inf
INF MdeModulePkg/Universal/MemoryTest/NullMemoryTestDxe/NullMemoryTestDxe.inf
INF UnixPkg/UnixThunkDxe/UnixThunk.inf
INF UnixPkg/CpuRuntimeDxe/Cpu.inf
INF MdeModulePkg/Universal/FaultTolerantWriteDxe/FaultTolerantWriteDxe.inf
INF UnixPkg/MiscSubClassPlatformDxe/MiscSubClassDriver.inf
INF UnixPkg/TimerDxe/Timer.inf
INF MdeModulePkg/Universal/Variable/RuntimeDxe/VariableRuntimeDxe.inf
INF MdeModulePkg/Universal/WatchdogTimerDxe/WatchdogTimer.inf
INF MdeModulePkg/Universal/MonotonicCounterRuntimeDxe/MonotonicCounterRuntimeDxe.inf
INF MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleRuntimeDxe.inf
INF MdeModulePkg/Universal/Console/ConPlatformDxe/ConPlatformDxe.inf
INF MdeModulePkg/Universal/Console/ConSplitterDxe/ConSplitterDxe.inf
INF MdeModulePkg/Universal/Console/GraphicsConsoleDxe/GraphicsConsoleDxe.inf
INF MdeModulePkg/Universal/Console/TerminalDxe/TerminalDxe.inf
INF MdeModulePkg/Universal/DevicePathDxe/DevicePathDxe.inf
INF MdeModulePkg/Universal/Disk/DiskIoDxe/DiskIoDxe.inf
INF MdeModulePkg/Universal/Disk/PartitionDxe/PartitionDxe.inf
INF MdeModulePkg/Universal/Disk/UnicodeCollation/EnglishDxe/EnglishDxe.inf
INF MdeModulePkg/Bus/Pci/PciBusDxe/PciBusDxe.inf
INF MdeModulePkg/Bus/Scsi/ScsiBusDxe/ScsiBusDxe.inf
INF MdeModulePkg/Bus/Scsi/ScsiDiskDxe/ScsiDiskDxe.inf
INF IntelFrameworkModulePkg/Bus/Pci/IdeBusDxe/IdeBusDxe.inf
INF UnixPkg/UnixBusDriverDxe/UnixBusDriver.inf
INF MdeModulePkg/Universal/SmbiosDxe/SmbiosDxe.inf
INF UnixPkg/UnixBlockIoDxe/UnixBlockIo.inf
INF UnixPkg/UnixSerialIoDxe/UnixSerialIo.inf
INF UnixPkg/UnixUgaDxe/UnixUga.inf
#INF UnixPkg/UnixConsoleDxe/UnixConsole.inf
INF MdeModulePkg/Universal/HiiDatabaseDxe/HiiDatabaseDxe.inf
INF MdeModulePkg/Universal/SetupBrowserDxe/SetupBrowserDxe.inf
INF MdeModulePkg/Universal/PrintDxe/PrintDxe.inf
INF IntelFrameworkModulePkg/Universal/BdsDxe/BdsDxe.inf
INF UnixPkg/UnixSimpleFileSystemDxe/UnixSimpleFileSystem.inf
INF MdeModulePkg/Universal/DriverSampleDxe/DriverSampleDxe.inf
INF MdeModulePkg/Application/HelloWorld/HelloWorld.inf
#
# Need to port this to UnixPkg
# Network stack drivers
# To test network drivers, need network Io driver(SnpNt32Io.dll), please refer to NETWORK-IO Subproject.
#
#INF MdeModulePkg/Universal/Network/DpcDxe/DpcDxe.inf
#INF MdeModulePkg/Universal/Network/ArpDxe/ArpDxe.inf
#INF MdeModulePkg/Universal/Network/Dhcp4Dxe/Dhcp4Dxe.inf
#INF MdeModulePkg/Universal/Network/Ip4ConfigDxe/Ip4ConfigDxe.inf
#INF MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Dxe.inf
#INF MdeModulePkg/Universal/Network/MnpDxe/MnpDxe.inf
#INF MdeModulePkg/Universal/Network/VlanConfigDxe/VlanConfigDxe.inf
#INF MdeModulePkg/Universal/Network/Mtftp4Dxe/Mtftp4Dxe.inf
#INF MdeModulePkg/Universal/Network/Tcp4Dxe/Tcp4Dxe.inf
#INF MdeModulePkg/Universal/Network/Udp4Dxe/Udp4Dxe.inf
#INF UnixPkg/SnpUnixDxe/SnpUnixDxe.inf
INF FatPkg/EnhancedFatDxe/Fat.inf
FILE APPLICATION = PCD(gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdShellFile) {
SECTION PE32 =Build/GccShellPkg/DEBUG_XCODE32/X64/ShellFull.efi
}
# Note: Warning current X64 port does not use EFI ABI so thease bins will crash
#INF RuleOverride = BINARY USE = X64 FatBinPkg/EnhancedFatDxe/Fat.inf
#INF RuleOverride = BINARY USE = X64 EdkShellBinPkg/FullShell/FullShell.inf
FILE FREEFORM = PCD(gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdLogoFile) {
SECTION RAW = MdeModulePkg/Logo/Logo.bmp
}
################################################################################
#
# Rules are use with the [FV] section's module INF type to define
# how an FFS file is created for a given INF file. The following Rule are the default
# rules for the different module type. User can add the customized rules to define the
# content of the FFS file.
#
################################################################################
############################################################################
# Example of a DXE_DRIVER FFS file with a Checksum encapsulation section #
############################################################################
#
#[Rule.Common.DXE_DRIVER]
# FILE DRIVER = $(NAMED_GUID) {
# DXE_DEPEX DXE_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex
# COMPRESS PI_STD {
# GUIDED {
# PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
# UI STRING="$(MODULE_NAME)" Optional
# VERSION STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
# }
# }
# }
#
############################################################################
[Rule.Common.PEI_CORE]
FILE PEI_CORE = $(NAMED_GUID) {
PE32 PE32 Align=32 $(INF_OUTPUT)/$(MODULE_NAME).efi
UI STRING ="$(MODULE_NAME)" Optional
VERSION STRING ="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
}
[Rule.Common.PEIM]
FILE PEIM = $(NAMED_GUID) {
PEI_DEPEX PEI_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex
PE32 PE32 Align=32 $(INF_OUTPUT)/$(MODULE_NAME).efi
UI STRING="$(MODULE_NAME)" Optional
VERSION STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
}
[Rule.Common.DXE_CORE]
FILE DXE_CORE = $(NAMED_GUID) {
COMPRESS PI_STD {
PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
UI STRING="$(MODULE_NAME)" Optional
VERSION STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
}
}
[Rule.Common.UEFI_DRIVER]
FILE DRIVER = $(NAMED_GUID) {
DXE_DEPEX DXE_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex
COMPRESS PI_STD {
GUIDED {
PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
UI STRING="$(MODULE_NAME)" Optional
VERSION STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
}
}
}
[Rule.Common.DXE_DRIVER]
FILE DRIVER = $(NAMED_GUID) {
DXE_DEPEX DXE_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex
COMPRESS PI_STD {
GUIDED {
PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
UI STRING="$(MODULE_NAME)" Optional
VERSION STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
}
}
}
[Rule.Common.DXE_RUNTIME_DRIVER]
FILE DRIVER = $(NAMED_GUID) {
DXE_DEPEX DXE_DEPEX Optional $(INF_OUTPUT)/$(MODULE_NAME).depex
COMPRESS PI_STD {
GUIDED {
PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
UI STRING="$(MODULE_NAME)" Optional
VERSION STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
}
}
}
[Rule.Common.UEFI_APPLICATION]
FILE APPLICATION = $(NAMED_GUID) {
COMPRESS PI_STD {
GUIDED {
PE32 PE32 $(INF_OUTPUT)/$(MODULE_NAME).efi
UI STRING="$(MODULE_NAME)" Optional
VERSION STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
}
}
}
[Rule.Common.UEFI_DRIVER.BINARY]
FILE DRIVER = $(NAMED_GUID) {
DXE_DEPEX DXE_DEPEX Optional |.depex
PE32 PE32 |.efi
UI STRING="$(MODULE_NAME)" Optional
VERSION STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
}
[Rule.Common.UEFI_APPLICATION.BINARY]
FILE APPLICATION = $(NAMED_GUID) {
PE32 PE32 |.efi
UI STRING="$(MODULE_NAME)" Optional
VERSION STRING="$(INF_VERSION)" Optional BUILD_NUM=$(BUILD_NUMBER)
}

View File

@ -152,13 +152,13 @@
showTypeColumn = 0; showTypeColumn = 0;
sourceDirectories = ( sourceDirectories = (
); );
startupPath = ../../../Build/Unix/DEBUG_XCODE32/X64; startupPath = ../../../Build/UnixX64/DEBUG_XCODE32/X64;
}; };
BA11A1020FB10BCE00D06FEC /* SecMain.dll */ = { BA11A1020FB10BCE00D06FEC /* SecMain.dll */ = {
isa = PBXFileReference; isa = PBXFileReference;
lastKnownFileType = "compiled.mach-o.executable"; lastKnownFileType = "compiled.mach-o.executable";
name = SecMain.dll; name = SecMain.dll;
path = ../../../Build/Unix/DEBUG_XCODE32/X64/SecMain; path = ../../../Build/UnixX64/DEBUG_XCODE32/X64/SecMain;
sourceTree = SOURCE_ROOT; sourceTree = SOURCE_ROOT;
}; };
BA11A11A0FB10E0700D06FEC /* SecGdbScriptBreak */ = { BA11A11A0FB10E0700D06FEC /* SecGdbScriptBreak */ = {

View File

@ -100,7 +100,7 @@ done
echo $PATH echo $PATH
echo `which build` echo `which build`
# Uncomment this if you want to build the shell. # Uncomment this if you want to build the shell.
#build -p $WORKSPACE/EdkShellPkg/EdkShellPkg.dsc -a IA32 -t $TARGET_TOOLS $1 $2 $3 $4 $5 $6 $7 $8 #build -p $WORKSPACE/GccShellPkg/GccShellPkg.dsc -a IA32 -t $TARGET_TOOLS -n 3 $1 $2 $3 $4 $5 $6 $7 $8
build -p $WORKSPACE/UnixPkg/UnixPkg.dsc -a IA32 -t $TARGET_TOOLS $1 $2 $3 $4 $5 $6 $7 $8 build -p $WORKSPACE/UnixPkg/UnixPkg.dsc -a IA32 -t $TARGET_TOOLS -n 3 $1 $2 $3 $4 $5 $6 $7 $8
exit $? exit $?

View File

@ -53,7 +53,7 @@ case `uname` in
esac esac
BUILD_ROOT_ARCH=$WORKSPACE/Build/Unix/DEBUG_"$TARGET_TOOLS"/X64 BUILD_ROOT_ARCH=$WORKSPACE/Build/UnixX64/DEBUG_"$TARGET_TOOLS"/X64
if [[ ! -f `which build` || ! -f `which GenFv` ]]; if [[ ! -f `which build` || ! -f `which GenFv` ]];
then then
@ -80,7 +80,7 @@ do
# This .gdbinit script sets a breakpoint that loads symbols for the PE/COFFEE # This .gdbinit script sets a breakpoint that loads symbols for the PE/COFFEE
# images that get loaded in SecMain # images that get loaded in SecMain
# #
cp $WORKSPACE/UnixPkg/.gdbinit $WORKSPACE/Build/Unix/DEBUG_"$TARGET_TOOLS"/X64 cp $WORKSPACE/UnixPkg/.gdbinit $WORKSPACE/Build/UnixX64/DEBUG_"$TARGET_TOOLS"/X64
;; ;;
esac esac
@ -100,7 +100,7 @@ done
echo $PATH echo $PATH
echo `which build` echo `which build`
# Uncomment this if you want to build the shell. # Uncomment this if you want to build the shell.
#build -p $WORKSPACE/EdkShellPkg/EdkShellPkg.dsc -a X64 -t $TARGET_TOOLS $1 $2 $3 $4 $5 $6 $7 $8 build -p $WORKSPACE/GccShellPkg/GccShellPkg.dsc -a X64 -t $TARGET_TOOLS -n 3 $1 $2 $3 $4 $5 $6 $7 $8
build -p $WORKSPACE/UnixPkg/UnixPkg.dsc -a X64 -t $TARGET_TOOLS $1 $2 $3 $4 $5 $6 $7 $8 build -p $WORKSPACE/UnixPkg/UnixPkgX64.dsc -a X64 -t $TARGET_TOOLS -n 3 $1 $2 $3 $4 $5 $6 $7 $8
exit $? exit $?