Page 1 of 1

Antonio: Please explain

Posted: Tue May 12, 2020 5:19 pm
by TimStone
* New: FUll support to easily build your PRGs from Microsoft free vscode. Just open
a PRG from FWH\samples and build it using Ctrl + Shift + B"

I tried this ... but clearly I need to understand the setup.

I downloaded the code program ... but how does it need to be configured ? What are the steps ? I thought there was a section on this forum but I can't find it.

Thanks.

Re: Antonio: Please explain

Posted: Tue May 12, 2020 10:31 pm
by Antonio Linares
Dear Tim,

Please review this thread:

http://forums.fivetechsupport.com/viewt ... 62#p231362

Re: Antonio: Please explain

Posted: Tue May 12, 2020 11:24 pm
by TimStone
OK ... I looked at that thread. I reinstalled FWH 20.04. I was able to get the settings to now use Harbour to generate the .c code.

I was working with fivedit.prg in sources. I get the .c code compiled ... but now what do I need to do to get it to link the program and run it ?

Thanks.

Re: Antonio: Please explain

Posted: Wed May 13, 2020 5:59 am
by Antonio Linares
Tim,

1. Open Microsoft vscode and select the folder c:\FWH\samples folder

2. Open a PRG from samples from vscode

3. Press Ctrl + Shift + B

Re: Antonio: Please explain

Posted: Wed May 13, 2020 6:18 pm
by TimStone
Antonio,

That is exactly what I am doing.

VSCode builds the .c but stops there and does not build the actual executable or run it.

What am I missing ? It must be a setup issue ... so what do I need to change and where ?

Tim

Re: Antonio: Please explain

Posted: Thu May 14, 2020 9:04 pm
by TimStone
I really would like to use this feature from 20.04, but I need to understand why it does not complete the build. It creates the .c file and stops.

Certainly it does more than this.

Re: Antonio: Please explain

Posted: Fri May 15, 2020 5:23 am
by Antonio Linares
Dear Tim,

Do you get an error msg ? Are you placed at c:\fwh\samples ?

Have you installed FWH 20.04 ?

You can edit the tasks.json file yourself and check it is looks like the one I pointed you to

Re: Antonio: Please explain

Posted: Mon May 18, 2020 6:00 pm
by TimStone
Antonio,

Yes, I am running by default in the samples directory.

I am using the simpler version you pointed to, which is using buildh32.bat ( since I'm using Microsoft )

The json is in the .vscode subfolder in the samples directory.

When I press t he keys, it tells me it cannot find buildh32.bat. It is there, in the samples directory.

So, I have a clear path problem here. Though I've opened the correct folder in VS Code, I have a hunch the json is somehow directing it to look for the .bat file elsewhere.

If I execute the commoand. buildh32 fivedemo. the program is built and run. So clearly the .bat file is good.

Your input would be appreciated.

Tim

Re: Antonio: Please explain

Posted: Tue May 19, 2020 3:47 am
by Antonio Linares
Tim,

Please open vscode and select "c:\fwh\samples" as the folder to work on from vscode

Being there, open a new terminal from vscode and select "cmd" instead of "powershell".

Then press Ctrl + Shift + B and it should work fine. I just tested it here with success.

Re: Antonio: Please explain

Posted: Tue May 19, 2020 6:56 pm
by TimStone
Thank you. Using the New Terminal with CMD was the missing step. It now works.

The other thing people need to know is to use the proper build script. In my case, Buildh32.bat is used to build with Harbour/Microsoft VC++