Changes

Jump to navigation Jump to search
1,648 bytes added ,  18:21, 27 March 2013
no edit summary
[[User:Oibaf|Oibaf]] 10 March 2013 (UTC)
:Unless I'm missing something, that's how it should be - wiiload's first argument is the name of the program that will be executed. Unless you want your wii programs to receive "wiiload.exe" as argv[0]? [[User:Tueidj|Tueidj]] ([[User talk:Tueidj|talk]]) 15:49, 10 March 2013 (CET)
 
Exactly. Argv[0] should be wiiload.exe. Also the first argument passed through meta.xml of homebrew applications is passed as Argv[1].
During the test of some wiibrew emulators I got crazy before finding out that wiiload passed the first argument as Argv[0].
[[User:Oibaf|Oibaf]] 19 March 2013 (UTC)
:You said "According to the standard C, argv[0] should be the name of the file" so how does it make sense for a wii program to receive "wiiload.exe" as argv[0] regardless of what the program's real name is? If you start a program in windows do you expect it to receive "explorer.exe" as argv[0]? [[User:Tueidj|Tueidj]] ([[User talk:Tueidj|talk]]) 13:07, 19 March 2013 (CET)
 
Sorry, I was wrong. Argv[0] should contain the dol file and argv[1] should contain the first argument passed to the dol file whilst currently the argument is passed as argv[0].
[[User:Oibaf|Oibaf]] 19 March 2013 (UTC)
:That's exactly how it currently works (argv[0] = name of dol/elf), not sure how you're seeing anything different. [[User:Tueidj|Tueidj]] ([[User talk:Tueidj|talk]]) 22:13, 19 March 2013 (CET)
 
I verified that argv[0] = name of dol/elf if wiiload is launched from a command window but argv[0] = "first argument" if wiiload is launched from programmer's notepad (windows environment) setting the parameters in Notepad as "$(ProjectName).dol argument". Is it a notpad issue?
295

edits

Navigation menu