FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour OT: recompile xharbour c-file
Posts: 1195
Joined: Mon Oct 17, 2005 05:41 AM
OT: recompile xharbour c-file
Posted: Fri Mar 27, 2020 12:46 PM

Hi,

I have an old application, using 'xHarbour Compiler build 0.99.71 (SimpLex)'

In that version, there was a problem with the function directoryrecurse.

In the newer version it was fixed. How can I compile the newer c-file (direct.c), and link to my program, using my old library?

Regards,

Marc



FWH32+xHarbour | FWH64+Harbour | BCC | DBF | ADO+MySQL | ADO+MariaDB | ADO+SQLite
Posts: 1195
Joined: Mon Oct 17, 2005 05:41 AM
Re: OT: recompile xharbour c-file
Posted: Sat Mar 28, 2020 09:46 AM
The problem is that I get this error if I compile the source
Code (fw): Select all Collapse
Error E2303 direct.c 108: Type name expected


Are there some specials flags I have to use?
Regards,

Marc



FWH32+xHarbour | FWH64+Harbour | BCC | DBF | ADO+MySQL | ADO+MariaDB | ADO+SQLite
Posts: 44162
Joined: Thu Oct 06, 2005 05:47 PM
Re: OT: recompile xharbour c-file
Posted: Sat Mar 28, 2020 06:00 PM

Marc,

Please post the source code for direct.c 108

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 1195
Joined: Mon Oct 17, 2005 05:41 AM
Re: OT: recompile xharbour c-file
Posted: Sat Mar 28, 2020 09:27 PM
Antonio,

This is line 108 in new latest release (the one with the error)
Code (fw): Select all Collapse
static void hb_fsGrabDirectory( PHB_ITEM pDir, const char * szDirSpec, HB_FATTR uiMask, PHB_FNAME fDirSpec, BOOL bFullPath, BOOL bDirOnly )


And this one with the old source than can be compiled
Code (fw): Select all Collapse
static void hb_fsGrabDirectory( PHB_ITEM pDir, const char * szDirSpec, USHORT uiMask, PHB_FNAME fDirSpec, BOOL bFullPath, BOOL bDirOnly )


I think the problem is that I can't mix those 2 releases, because the new one is using the variable 'HB_FATTR' that is defined in the new 'Hbdefs.h', and not in the old one.
Regards,

Marc



FWH32+xHarbour | FWH64+Harbour | BCC | DBF | ADO+MySQL | ADO+MariaDB | ADO+SQLite
Posts: 44162
Joined: Thu Oct 06, 2005 05:47 PM
Re: OT: recompile xharbour c-file
Posted: Sun Mar 29, 2020 06:45 AM

Marc,

Lets compare the source code for function directoryrecurse in both versions and then we fix the old one.

Please post the source code for function directoryrecurse in both versions here

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 1195
Joined: Mon Oct 17, 2005 05:41 AM
Re: OT: recompile xharbour c-file
Posted: Sun Mar 29, 2020 09:34 AM
Regards,

Marc



FWH32+xHarbour | FWH64+Harbour | BCC | DBF | ADO+MySQL | ADO+MariaDB | ADO+SQLite
Posts: 44162
Joined: Thu Oct 06, 2005 05:47 PM
Re: OT: recompile xharbour c-file
Posted: Sun Mar 29, 2020 11:03 AM

Marc,

You can not use this new C file with your xHarbour version, sorry.

What is the bug that you have using DirectoryRecurse() ?

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 1195
Joined: Mon Oct 17, 2005 05:41 AM
Re: OT: recompile xharbour c-file
Posted: Sun Mar 29, 2020 11:09 AM

Antonio,

The bug is that I always get an empty array.

Regards,

Marc



FWH32+xHarbour | FWH64+Harbour | BCC | DBF | ADO+MySQL | ADO+MariaDB | ADO+SQLite
Posts: 44162
Joined: Thu Oct 06, 2005 05:47 PM
Re: OT: recompile xharbour c-file
Posted: Sun Mar 29, 2020 02:25 PM

Marc,

Please build FWH/samples/elixir.prg to review if it may help you

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 1195
Joined: Mon Oct 17, 2005 05:41 AM
Re: OT: recompile xharbour c-file
Posted: Sun Mar 29, 2020 02:46 PM

Antonio,

Thank you, with the function into this example-file, I get all file files :D

Regards,

Marc



FWH32+xHarbour | FWH64+Harbour | BCC | DBF | ADO+MySQL | ADO+MariaDB | ADO+SQLite

Continue the discussion