mirror of
https://gitlab.com/sortix/sortix.git
synced 2023-02-13 20:55:38 -05:00
The kernel provides the $cputype environmental variable.
This commit is contained in:
parent
e230854ee9
commit
8f3fd73bd6
1 changed files with 10 additions and 2 deletions
|
@ -370,8 +370,16 @@ static void InitThread(void* /*user*/)
|
|||
|
||||
int argc = 1;
|
||||
const char* argv[] = { "init", NULL };
|
||||
int envc = 0;
|
||||
const char* envp[] = { NULL };
|
||||
#if defined(PLATFORM_X86)
|
||||
const char* cputype = "cputype=i486-pc-sortix";
|
||||
#elif defined(PLATFORM_X64)
|
||||
const char* cputype = "cputype=x86_64-pc-sortix";
|
||||
#else
|
||||
#warning No cputype environmental variable provided here.
|
||||
const char* cputype = "cputype=unknown-pc-sortix";
|
||||
#endif
|
||||
int envc = 1;
|
||||
const char* envp[] = { cputype, NULL };
|
||||
CPU::InterruptRegisters regs;
|
||||
|
||||
if ( process->Execute("init", program, programsize, argc, argv, envc, envp,
|
||||
|
|
Loading…
Add table
Reference in a new issue