Page 1 of 1
pbcompiler with /commented without executing the program ??
Posted: Fri May 26, 2006 10:23 pm
by josku_x
Hello!
I am sure some of you are using the PBCompiler with the /COMMENTED switch to produce the PureBasic.asm file. However, I am creating a tool which allows viewing the ASM output, but I have a minor problem. Everytime I run the PBCompiler with the /COMMENTED switch, it creates the PureBasic.asm file, but then it executes the executable. How do I run the PBCompiler with the /COMMENTED switch WITHOUT executing the program?
There seems to be no switch for this.
Thanks!
Posted: Sat May 27, 2006 2:46 am
by Deeem2031
One way would be start the compiler in standby-mode and set the NOEXECUTE-flag on compiling. Another way would be using the api-hook lib to hook CreateProcess_() to filter the Purebasic[...].exe.
Posted: Sat May 27, 2006 4:13 am
by josku_x
Deeem2031 wrote:One way would be start the compiler in standby-mode and set the NOEXECUTE-flag on compiling. Another way would be using the api-hook lib to hook CreateProcess_() to filter the Purebasic[...].exe.
Do you have an example to show how would I use CreateProcess_() with this? Thanks!
Posted: Sat May 27, 2006 9:26 am
by Trond
Yes this is very annoying.
Posted: Sat May 27, 2006 9:34 am
by josku_x
Trond wrote:Yes this is very annoying.
I agree. If I remember right, the compiler of PB 3.94 didn't launch the program if you used the /COMMENTED switch. But I am maybe wrong.
However, if there is a solution to use CreateProcess_() to filter the PBCompiler that it won't execute anything it would be very appreciated if someone could give an example.
thanks
Posted: Sat May 27, 2006 10:19 am
by Trond
Call it with the /exe switch.
Posted: Sat May 27, 2006 10:37 am
by josku_x
Trond wrote:Call it with the /exe switch.
The /EXE switch doesn't help at all.
Posted: Sat May 27, 2006 10:44 am
by Trond
josku_x wrote:Trond wrote:Call it with the /exe switch.
The /EXE switch doesn't help at all.
Yes it does, you just need to specify a filename.
Posted: Sat May 27, 2006 10:49 am
by josku_x
Ok, is this command right?
shell> PBCompiler.exe MyFile.pb /COMMENTED /EXE MyExe.exe
Posted: Sat May 27, 2006 11:12 am
by Trond
yes.
Posted: Sat May 27, 2006 11:14 am
by josku_x
Trond wrote:yes.
Thanks. I got my viewer ready, now it comes to the GUI part.

Posted: Sat May 27, 2006 12:44 pm
by flaith
Posted: Sat May 27, 2006 1:00 pm
by josku_x
A nice program, but looks awful. I hate that skin. I am creating a tool BTW, not french software

(EDIT: Now I see PureASM is also a tool)
Sorry for the rough comments, but the "IDE" of PureASM looks pretty awful and the text is a bit hard to read.
Posted: Sat May 27, 2006 1:07 pm
by flaith
no problemo
