>> If it doesn't work, it means you DO CHANGE the 
>> current directory, even if you don't know about it, 
>> so in this case you must explore the QT launching 
>> stuff to see how to disable it.
>> 
> 
> Let me explain a bit how hbIDE forks process to Qt 
> and why I cannot take this approach. 
> 
> Calling hbMK2: is done in a attached Qt process. The called process 
> is started in project location. hbIDE process does not change 
> its directory. Called process creates the executable and returns.

And here is the problem. Called process (hbmk2) is started 
in "project location", so you DO alter current dir for the 
subprocess, but you didn't correct detected output name 
accordingly.

curdir for hbmk2 != curdir for HBIDE

That's why I told a few e-mails back to either not alter 
current dir for subprocess, or correct the output name.
You need to do the latter anyway, the only question is what 
is the base directory; if you alter it, it's the dir which 
you set as current dir, if you don't it's "CURDIR()".

> Executing target: executable is detected by whatever means 
> I was/am adopting. A new detached Qt process is initiated 
> which fires the executable and stays in the "Start in" folder,
> if provided.

This should be irrelevant once you have an absolute path 
pointing to the target executable. The point is to have 
an absolute path formed based on a base dir and the output 
name detected (which can be relative or absolute).

Though based on your description, it's unnecessary to 
change directory when launching hbmk2. I left it, but 
I still don't understand why you do it. It just adds 
complexity without any benefit. hbmk2 doesn't require 
any such tricks to make it work.

>> I'm very sad you only hear the wrong solutions from 
>> my mails and I'm a little bit afraid to tell anything, 
>> since I'm not happy to help creating bad solutions.
>> 
> 
> Me too, but believe me I could never find a satisfactory
> way to detect. Every method went weired at one stage 
> or the other. So do not be so rude, please.

Sorry if I was. Pls verify my recent commit, wether 
it seems to solve the problem in your view and tests.

Viktor

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

Reply via email to