Hello

Viktor Szakáts wrote:
> 
> I'm sorry, but I can't see why this would be necessary, moreover, 
> I doubt it would work this way. If hbmk2 invokes a subprocess, 
> such as vcvarsall.bat, I see no way that the environment it leaves 
> behind could be kept for compiler tools invoked afterwards.
> 

Oh, I forgot this fact. It is the same for hbMK2 as is hbMK2
is for hbIDE. Damm...



> If you need such functionality I think you should pack all 
> your commands (call vcvarsall && hbmk2 ...) in one .bat / .sh 
> file (depending on host platform) or one commandline with multiple 
> commands, and invoke that. Also notice that in order to make 
> "%ProgramFiles%" expression work, you definitely need to 
> invoke the OS shell.
> 

This can be the option but not very elegant. hbIDE does not 
need anything special. All what is required is how to make hbMk2
happy to execute a project. The only point is user cannot set the
environment beforehad. hbIDE can be invoked from anywhere.



> The other option is to stick to envvars, and in this case 
> you can set these using hb_setenv() before invoking hbmk2 
> subprocess. (I do this in hbmk2 to setup some tools automatically)
> I don't know if this works with QProcess.
> 

Setting env variable works with QProcess.
So, if my batch to invoke console for MSVS looks like this :

//----------------------//

call "%ProgramFiles%\Microsoft Visual Studio 8\VC\vcvarsall.bat" x86

SET PATH=e:\harbour;e:\harbour\bin;c:\mingw\bin;c:\qt\4.5.3\bin;%PATH%

set HB_ARCHITECTURE=win
set HB_COMPILER=msvc

set HB_WITH_QT=c:\qt\4.5.3\lib

set HB_USER_PRGFLAGS=-gc3

//----------------------//

Then what I am supposed to pass hbMK2 from hbIDE that 
above setting is known to hbMK2.
All set commands I can set but what about "call" command?
Is it necessary ? Or we have another option ?

Regards
Pritpal Bedi


-- 
View this message in context: 
http://old.nabble.com/hbIDE--%3E-QProcess%28%29--%3E---shell-command----%3E-hbMK2-tp27068461p27069741.html
Sent from the Harbour - Dev mailing list archive at Nabble.com.

_______________________________________________
Harbour mailing list (attachment size limit: 40KB)
[email protected]
http://lists.harbour-project.org/mailman/listinfo/harbour

Reply via email to