Issue with FWH64/Harbour64/BCC7164 and Mysql.h file

Issue with FWH64/Harbour64/BCC7164 and Mysql.h file

Postby Compuin » Fri Jun 25, 2021 7:38 pm

Hello,

I'm getting this error while I'm trying to compile ERP.PRG sample. I'm using FWH64, Habour 64 and BCC7164

I don't know if is there issues with Harbour and Borland on 64 bits

Mysql.h file is on FWH64 include folder

Please advise

┌────────────────────────────────────────────────────────────────────────────┐
?FiveWin for Harbour 20.06 bcc7 64bits Jun. 2020 xHarbour development power │▄
?(c) FiveTech 1993-2020 for Microsoft Windows 9X/NT/200X/ME/XP/Vista/7/8/10 │█
└────────────────────────────────────────────────────────────────────────────┘?
  ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀?
Compiling...
Harbour 3.2.0dev (r1603181642)
Copyright (c) 1999-2016, http://harbour-project.org/
Compiling 'erp.prg' and generating preprocessed output to 'erp.ppo'...
Lines 5608, Functions/Procedures 8
Generating C source output to 'erp.c'... Done.
erp.prg(130) Warning W0001 Method <GetDataBases()> not declared or declaration mismatch in class <TMySQL>
erp.prg(144) Warning W0001 Method <GetTables()> not declared or declaration mismatch in class <TMySQL>
Embarcadero C++ 7.20 for Win64 Copyright (c) 2012-2016 Embarcadero Technologies, Inc.
erp.c:
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:199:
In file included from c:\bcc7164\include\windows\sdk\windef.h:25:
In file included from c:\bcc7164\include\windows\sdk\minwindef.h:183:
c:\bcc7164\include\windows\sdk\winnt.h:411:13: warning: redefinition of typedef 'INT' is a C11 feature
[-Wtypedef-redefinition]
typedef int INT;
^
c:\bcc7164\include\windows\sdk\minwindef.h:177:29: note: previous definition is here
typedef int INT;
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:199:
In file included from c:\bcc7164\include\windows\sdk\windef.h:25:
In file included from c:\bcc7164\include\windows\sdk\minwindef.h:183:
c:\bcc7164\include\windows\sdk\winnt.h:1365:20: warning: declaration of 'struct _CONTEXT' will not be visible outside of
this function [-Wvisibility]
_Inout_ struct _CONTEXT *ContextRecord,
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:202:
c:\bcc7164\include\windows\sdk\winuser.h:1154:5: warning: declaration does not declare anything [-Wmissing-declarations]
MOUSEHOOKSTRUCT DUMMYSTRUCTNAME;
^~~~~~~~~~~~~~~
c:\bcc7164\include\windows\sdk\winuser.h:13112:5: warning: declaration does not declare anything
[-Wmissing-declarations]
MONITORINFO DUMMYSTRUCTNAME;
^~~~~~~~~~~
c:\bcc7164\include\windows\sdk\winuser.h:13117:5: warning: declaration does not declare anything
[-Wmissing-declarations]
MONITORINFO DUMMYSTRUCTNAME;
^~~~~~~~~~~
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:251:
In file included from c:\bcc7164\include\windows\sdk\winscard.h:31:
In file included from c:\bcc7164\include\windows\sdk\wtypes.h:23:
c:\bcc7164\include\windows\sdk/rpcndr.h:592:32: warning: redefinition of typedef 'PFORMAT_STRING' is a C11 feature
[-Wtypedef-redefinition]
typedef const unsigned char * PFORMAT_STRING;
^
c:\bcc7164\include\windows\sdk/rpcndr.h:565:32: note: previous definition is here
typedef const unsigned char * PFORMAT_STRING;
^
c:\bcc7164\include\windows\sdk/rpcndr.h:815:36: warning: redefinition of typedef 'MIDL_STUB_MESSAGE' is a C11 feature
[-Wtypedef-redefinition]
typedef struct _MIDL_STUB_MESSAGE MIDL_STUB_MESSAGE, *PMIDL_STUB_MESSAGE;
^
c:\bcc7164\include\windows\sdk/rpcndr.h:812:7: note: previous definition is here
} MIDL_STUB_MESSAGE, *PMIDL_STUB_MESSAGE;
^
c:\bcc7164\include\windows\sdk/rpcndr.h:815:58: warning: redefinition of typedef 'PMIDL_STUB_MESSAGE' is a C11 feature
[-Wtypedef-redefinition]
typedef struct _MIDL_STUB_MESSAGE MIDL_STUB_MESSAGE, *PMIDL_STUB_MESSAGE;
^
c:\bcc7164\include\windows\sdk/rpcndr.h:812:28: note: previous definition is here
} MIDL_STUB_MESSAGE, *PMIDL_STUB_MESSAGE;
^
c:\bcc7164\include\windows\sdk/rpcndr.h:1184:3: warning: redefinition of typedef 'MIDL_SYNTAX_INFO' is a C11 feature
[-Wtypedef-redefinition]
} MIDL_SYNTAX_INFO, *PMIDL_SYNTAX_INFO;
^
c:\bcc7164\include\windows\sdk/rpcndr.h:593:34: note: previous definition is here
typedef struct _MIDL_SYNTAX_INFO MIDL_SYNTAX_INFO, *PMIDL_SYNTAX_INFO;
^
c:\bcc7164\include\windows\sdk/rpcndr.h:1184:22: warning: redefinition of typedef 'PMIDL_SYNTAX_INFO' is a C11 feature
[-Wtypedef-redefinition]
} MIDL_SYNTAX_INFO, *PMIDL_SYNTAX_INFO;
^
c:\bcc7164\include\windows\sdk/rpcndr.h:593:53: note: previous definition is here
typedef struct _MIDL_SYNTAX_INFO MIDL_SYNTAX_INFO, *PMIDL_SYNTAX_INFO;
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:251:
In file included from c:\bcc7164\include\windows\sdk\winscard.h:31:
In file included from c:\bcc7164\include\windows\sdk\wtypes.h:40:
c:\bcc7164\include\windows\sdk/wtypesbase.h:143:23: warning: redefinition of typedef 'UCHAR' is a C11 feature
[-Wtypedef-redefinition]
typedef unsigned char UCHAR;
^
c:\bcc7164\include\windows\sdk\minwindef.h:56:23: note: previous definition is here
typedef unsigned char UCHAR;
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:251:
In file included from c:\bcc7164\include\windows\sdk\winscard.h:31:
In file included from c:\bcc7164\include\windows\sdk\wtypes.h:40:
c:\bcc7164\include\windows\sdk/wtypesbase.h:145:15: warning: redefinition of typedef 'SHORT' is a C11 feature
[-Wtypedef-redefinition]
typedef short SHORT;
^
c:\bcc7164\include\windows\sdk\winnt.h:408:15: note: previous definition is here
typedef short SHORT;
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:251:
In file included from c:\bcc7164\include\windows\sdk\winscard.h:31:
In file included from c:\bcc7164\include\windows\sdk\wtypes.h:40:
c:\bcc7164\include\windows\sdk/wtypesbase.h:147:24: warning: redefinition of typedef 'USHORT' is a C11 feature
[-Wtypedef-redefinition]
typedef unsigned short USHORT;
^
c:\bcc7164\include\windows\sdk\minwindef.h:54:24: note: previous definition is here
typedef unsigned short USHORT;
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:251:
In file included from c:\bcc7164\include\windows\sdk\winscard.h:31:
In file included from c:\bcc7164\include\windows\sdk\wtypes.h:40:
c:\bcc7164\include\windows\sdk/wtypesbase.h:149:15: warning: redefinition of typedef 'ULONG' is a C11 feature
[-Wtypedef-redefinition]
typedef DWORD ULONG;
^
c:\bcc7164\include\windows\sdk\minwindef.h:52:23: note: previous definition is here
typedef unsigned long ULONG;
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:251:
In file included from c:\bcc7164\include\windows\sdk\winscard.h:31:
In file included from c:\bcc7164\include\windows\sdk\wtypes.h:40:
c:\bcc7164\include\windows\sdk/wtypesbase.h:499:17: warning: redefinition of typedef 'BOOLEAN' is a C11 feature
[-Wtypedef-redefinition]
typedef boolean BOOLEAN;
^
c:\bcc7164\include\windows\sdk\winnt.h:1093:15: note: previous definition is here
typedef BYTE BOOLEAN;
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:251:
In file included from c:\bcc7164\include\windows\sdk\winscard.h:31:
c:\bcc7164\include\windows\sdk\wtypes.h:385:15: warning: redefinition of typedef 'LCID' is a C11 feature
[-Wtypedef-redefinition]
typedef DWORD LCID;
^
c:\bcc7164\include\windows\sdk\winnt.h:708:15: note: previous definition is here
typedef DWORD LCID;
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:251:
In file included from c:\bcc7164\include\windows\sdk\winscard.h:31:
c:\bcc7164\include\windows\sdk\wtypes.h:390:16: warning: redefinition of typedef 'LANGID' is a C11 feature
[-Wtypedef-redefinition]
typedef USHORT LANGID;
^
c:\bcc7164\include\windows\sdk\winnt.h:710:16: note: previous definition is here
typedef WORD LANGID;
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:251:
In file included from c:\bcc7164\include\windows\sdk\winscard.h:33:
c:\bcc7164\include\windows\sdk/winsmcrd.h:37:15: warning: redefinition of typedef 'ULONG' is a C11 feature
[-Wtypedef-redefinition]
typedef DWORD ULONG;
^
c:\bcc7164\include\windows\sdk/wtypesbase.h:149:15: note: previous definition is here
typedef DWORD ULONG;
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:251:
In file included from c:\bcc7164\include\windows\sdk\winscard.h:33:
c:\bcc7164\include\windows\sdk/winsmcrd.h:39:14: warning: redefinition of typedef 'UCHAR' is a C11 feature
[-Wtypedef-redefinition]
typedef BYTE UCHAR;
^
c:\bcc7164\include\windows\sdk/wtypesbase.h:143:23: note: previous definition is here
typedef unsigned char UCHAR;
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:251:
c:\bcc7164\include\windows\sdk\winscard.h:57:21: warning: redefinition of typedef 'LPCVOID' is a C11 feature
[-Wtypedef-redefinition]
typedef const VOID *LPCVOID;
^
c:\bcc7164\include\windows\sdk\minwindef.h:175:30: note: previous definition is here
typedef CONST void far *LPCVOID;
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:260:
In file included from c:\bcc7164\include\windows\sdk\ole2.h:38:
In file included from c:\bcc7164\include\windows\sdk\objbase.h:28:
In file included from c:\bcc7164\include\windows\sdk\combaseapi.h:407:
c:\bcc7164\include\windows\sdk\objidlbase.h:150:37: warning: redefinition of typedef 'IRpcChannelBuffer' is a C11
feature [-Wtypedef-redefinition]
typedef interface IRpcChannelBuffer IRpcChannelBuffer;
^
c:\bcc7164\include\windows\sdk\combaseapi.h:393:41: note: previous definition is here
typedef interface IRpcChannelBuffer IRpcChannelBuffer;
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:260:
In file included from c:\bcc7164\include\windows\sdk\ole2.h:38:
In file included from c:\bcc7164\include\windows\sdk\objbase.h:28:
In file included from c:\bcc7164\include\windows\sdk\combaseapi.h:407:
c:\bcc7164\include\windows\sdk\objidlbase.h:192:34: warning: redefinition of typedef 'IRpcStubBuffer' is a C11 feature
[-Wtypedef-redefinition]
typedef interface IRpcStubBuffer IRpcStubBuffer;
^
c:\bcc7164\include\windows\sdk\combaseapi.h:392:41: note: previous definition is here
typedef interface IRpcStubBuffer IRpcStubBuffer;
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:260:
In file included from c:\bcc7164\include\windows\sdk\ole2.h:38:
In file included from c:\bcc7164\include\windows\sdk\objbase.h:29:
In file included from c:\bcc7164\include\windows\sdk\coml2api.h:42:
c:\bcc7164\include\windows\sdk\propidlbase.h:139:31: warning: redefinition of typedef 'PROPVARIANT' is a C11 feature
[-Wtypedef-redefinition]
typedef struct tagPROPVARIANT PROPVARIANT;
^
c:\bcc7164\include\windows\sdk\combaseapi.h:1341:31: note: previous definition is here
typedef struct tagPROPVARIANT PROPVARIANT;
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:260:
In file included from c:\bcc7164\include\windows\sdk\ole2.h:39:
c:\bcc7164\include\windows\sdk\oleauto.h:1057:56: warning: redefinition of typedef 'LPTYPELIB' is a C11 feature
[-Wtypedef-redefinition]
typedef /* [unique] */ __RPC_unique_pointer ITypeLib *LPTYPELIB;
^
c:\bcc7164\include\windows\sdk/oaidl.h:3643:56: note: previous definition is here
typedef /* [unique] */ __RPC_unique_pointer ITypeLib *LPTYPELIB;
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:260:
In file included from c:\bcc7164\include\windows\sdk\ole2.h:39:
c:\bcc7164\include\windows\sdk\oleauto.h:1065:14: warning: redefinition of typedef 'DISPID' is a C11 feature
[-Wtypedef-redefinition]
typedef LONG DISPID;
^
c:\bcc7164\include\windows\sdk/oaidl.h:610:14: note: previous definition is here
typedef LONG DISPID;
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:260:
In file included from c:\bcc7164\include\windows\sdk\ole2.h:39:
c:\bcc7164\include\windows\sdk\oleauto.h:1066:16: warning: redefinition of typedef 'MEMBERID' is a C11 feature
[-Wtypedef-redefinition]
typedef DISPID MEMBERID;
^
c:\bcc7164\include\windows\sdk/oaidl.h:612:16: note: previous definition is here
typedef DISPID MEMBERID;
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:260:
In file included from c:\bcc7164\include\windows\sdk\ole2.h:39:
c:\bcc7164\include\windows\sdk\oleauto.h:1089:57: warning: redefinition of typedef 'LPTYPEINFO' is a C11 feature
[-Wtypedef-redefinition]
typedef /* [unique] */ __RPC_unique_pointer ITypeInfo *LPTYPEINFO;
^
c:\bcc7164\include\windows\sdk/oaidl.h:2659:57: note: previous definition is here
typedef /* [unique] */ __RPC_unique_pointer ITypeInfo *LPTYPEINFO;
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:260:
In file included from c:\bcc7164\include\windows\sdk\ole2.h:39:
c:\bcc7164\include\windows\sdk\oleauto.h:1096:57: warning: redefinition of typedef 'LPTYPECOMP' is a C11 feature
[-Wtypedef-redefinition]
typedef /* [unique] */ __RPC_unique_pointer ITypeComp *LPTYPECOMP;
^
c:\bcc7164\include\windows\sdk/oaidl.h:2481:57: note: previous definition is here
typedef /* [unique] */ __RPC_unique_pointer ITypeComp *LPTYPECOMP;
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:260:
In file included from c:\bcc7164\include\windows\sdk\ole2.h:39:
c:\bcc7164\include\windows\sdk\oleauto.h:1103:26: warning: redefinition of typedef 'LPCREATETYPELIB' is a C11 feature
[-Wtypedef-redefinition]
typedef ICreateTypeLib * LPCREATETYPELIB;
^
c:\bcc7164\include\windows\sdk/oaidl.h:1755:40: note: previous definition is here
typedef /* [unique] */ ICreateTypeLib *LPCREATETYPELIB;
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:260:
In file included from c:\bcc7164\include\windows\sdk\ole2.h:39:
c:\bcc7164\include\windows\sdk\oleauto.h:1105:27: warning: redefinition of typedef 'LPCREATETYPEINFO' is a C11 feature
[-Wtypedef-redefinition]
typedef ICreateTypeInfo * LPCREATETYPEINFO;
^
c:\bcc7164\include\windows\sdk/oaidl.h:974:41: note: previous definition is here
typedef /* [unique] */ ICreateTypeInfo *LPCREATETYPEINFO;
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:260:
In file included from c:\bcc7164\include\windows\sdk\ole2.h:39:
c:\bcc7164\include\windows\sdk\oleauto.h:1207:57: warning: redefinition of typedef 'LPDISPATCH' is a C11 feature
[-Wtypedef-redefinition]
typedef /* [unique] */ __RPC_unique_pointer IDispatch *LPDISPATCH;
^
c:\bcc7164\include\windows\sdk/oaidl.h:2146:57: note: previous definition is here
typedef /* [unique] */ __RPC_unique_pointer IDispatch *LPDISPATCH;
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:263:
c:\bcc7164\include\windows\sdk\commdlg.h:710:21: warning: redefinition of typedef 'CHOOSEFONT' is a C11 feature
[-Wtypedef-redefinition]
typedef CHOOSEFONTA CHOOSEFONT;
^
c:\bcc7164\include\windows\sdk\commdlg.h:695:21: note: previous definition is here
typedef CHOOSEFONTA CHOOSEFONT;
^
In file included from erp.prg:193:
In file included from c:\bcc7164\include\windows\sdk\windows.h:289:
c:\bcc7164\include\windows\sdk\imm.h:46:19: warning: redefinition of typedef 'LPUINT' is a C11 feature
[-Wtypedef-redefinition]
typedef UINT FAR *LPUINT;
^
c:\bcc7164\include\windows\sdk\mmsyscom.h:103:21: note: previous definition is here
typedef UINT FAR *LPUINT;
^
erp.prg:194:10: fatal error: 'mysql.h' file not found
#include <mysql.h>
^
33 warnings and 1 error generated.
* Linking errors *

C:\fwh64\samples>
Last edited by Compuin on Sat Jun 26, 2021 8:35 pm, edited 2 times in total.
FWH 20.12
Hbmk2 32/64 Bits (Build 19.29.30133)
Microsoft Visual C 32 Bits
MySql 8.0.24 32/64 Bits
VS Code
Compuin
 
Posts: 1214
Joined: Tue Dec 28, 2010 1:29 pm
Location: Quebec, Canada

Re: Issue with FWH64/Harbour64/BCC7164 and Mysql.h file

Postby Antonio Linares » Sat Jun 26, 2021 8:41 am

No encuentra el fichero: mysql.h

erp.prg:194:10: fatal error: 'mysql.h' file not found

Los demás warnings deberían poder eliminarse usando el flag de compatibilidad con C11
http://docwiki.embarcadero.com/RADStudio/Sydney/en/C%2B%2B11_Features_in_the_Classic_Compiler
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42203
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Issue with FWH64/Harbour64/BCC7164 and Mysql.h file

Postby Compuin » Sat Jun 26, 2021 2:20 pm

Antonio Linares wrote:No encuentra el fichero: mysql.h

erp.prg:194:10: fatal error: 'mysql.h' file not found

Los demás warnings deberían poder eliminarse usando el flag de compatibilidad con C11
http://docwiki.embarcadero.com/RADStudio/Sydney/en/C%2B%2B11_Features_in_the_Classic_Compiler


El fichero esta en los includes de FWH64

En la version FWH a 32 Bits funciona sin problemas, no logra encontrar mysql.h en lade 64 Bits

Any advice?
FWH 20.12
Hbmk2 32/64 Bits (Build 19.29.30133)
Microsoft Visual C 32 Bits
MySql 8.0.24 32/64 Bits
VS Code
Compuin
 
Posts: 1214
Joined: Tue Dec 28, 2010 1:29 pm
Location: Quebec, Canada

Re: Issue with FWH64/Harbour64/BCC7164 and Mysql.h file

Postby nageswaragunupudi » Sat Jun 26, 2021 3:58 pm

These are the include files required

errmsg.h
mysql.h
mysql_com.h
mysql_time.h
mysql_version.h
my_alloc.h
my_list.h
typelib.h


They are not included in FWH\include, in 32 version also.
By default, we can build this sample with 32 bit release also, without including the folder containing these files.

If you have them in any folder, we need to include in the build64.bat
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10690
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: Issue with FWH64/Harbour64/BCC7164 and Mysql.h file

Postby Compuin » Sat Jun 26, 2021 4:08 pm

nageswaragunupudi wrote:These are the include files required

errmsg.h
mysql.h
mysql_com.h
mysql_time.h
mysql_version.h
my_alloc.h
my_list.h
typelib.h


They are not included in FWH\include, in 32 version also.
By default, we can build this sample with 32 bit release also, without including the folder containing these files.

If you have them in any folder, we need to include in the build64.bat


Hello Mr Rao

I included them on FWH64\Include 64 version

Still is showing me

erp.prg:195:10: fatal error: 'mysql.h' file not found
#include <mysql.h>


I also included them on FWH 32 version and they worked ok there

Any other advice?
FWH 20.12
Hbmk2 32/64 Bits (Build 19.29.30133)
Microsoft Visual C 32 Bits
MySql 8.0.24 32/64 Bits
VS Code
Compuin
 
Posts: 1214
Joined: Tue Dec 28, 2010 1:29 pm
Location: Quebec, Canada

Re: Issue with FWH64/Harbour64/BCC7164 and Mysql.h file

Postby nageswaragunupudi » Sat Jun 26, 2021 4:48 pm

In build64, you need to include the path fwh/include also.

replace the line
Code: Select all  Expand view  RUN
%bcdir%\bin\bcc64 -c -I%hdir%\include -I%bcdir%\include\windows\sdk -I%bcdir%\include\windows\crtl -o%1.obj %1.c


with
Code: Select all  Expand view  RUN
%bcdir%\bin\bcc64 -c -I%hdir%\include -I%bcdir%\include\windows\sdk -I%bcdir%\include\windows\crtl -I%fwh%\include -o%1.obj %1.c


I am not very sure but I think that there are some differences in the include files for 32-bit and 64-bit versions. Please make sure you are using the correct version.
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10690
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: Issue with FWH64/Harbour64/BCC7164 and Mysql.h file

Postby Compuin » Sat Jun 26, 2021 5:01 pm

nageswaragunupudi wrote:In build64, you need to include the path fwh/include also.

replace the line
Code: Select all  Expand view  RUN
%bcdir%\bin\bcc64 -c -I%hdir%\include -I%bcdir%\include\windows\sdk -I%bcdir%\include\windows\crtl -o%1.obj %1.c


with
Code: Select all  Expand view  RUN
%bcdir%\bin\bcc64 -c -I%hdir%\include -I%bcdir%\include\windows\sdk -I%bcdir%\include\windows\crtl -I%fwh%\include -o%1.obj %1.c


I am not very sure but I think that there are some differences in the include files for 32-bit and 64-bit versions. Please make sure you are using the correct version.


Mr. Rao,

This solution worked! Now I can compile ERP.PRG on FWH64/BCC7164.

Many thanks!
FWH 20.12
Hbmk2 32/64 Bits (Build 19.29.30133)
Microsoft Visual C 32 Bits
MySql 8.0.24 32/64 Bits
VS Code
Compuin
 
Posts: 1214
Joined: Tue Dec 28, 2010 1:29 pm
Location: Quebec, Canada

Re: Issue with FWH64/Harbour64/BCC7164 and Mysql.h file(SOLVED)

Postby Antonio Linares » Sat Jun 26, 2021 5:37 pm

regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42203
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Issue with FWH64/Harbour64/BCC7164 and Mysql.h file(SOLVED)

Postby Compuin » Sat Jun 26, 2021 5:46 pm



Master Antonio

I'm getting this now:

c:\harbour\include/clipdefs.h:112:21: error: typedef redefinition with different types ('HB_VMHANDLE' (aka 'unsigned long') vs 'void *')
typedef HB_VMHANDLE HANDLE;

c:\harbour\include/clipdefs.h:100:16: error: typedef redefinition with different types ('USHORT' (aka 'unsigned short') vs 'int')
typedef USHORT BOOL;

c:\harbour\include/clipdefs.h:78:22: error: typedef redefinition with different types ('unsigned int' vs 'unsigned short')
typedef unsigned int WORD;
FWH 20.12
Hbmk2 32/64 Bits (Build 19.29.30133)
Microsoft Visual C 32 Bits
MySql 8.0.24 32/64 Bits
VS Code
Compuin
 
Posts: 1214
Joined: Tue Dec 28, 2010 1:29 pm
Location: Quebec, Canada

Re: Issue with FWH64/Harbour64/BCC7164 and Mysql.h file(SOLVED)

Postby Antonio Linares » Sat Jun 26, 2021 6:06 pm

Please try with these changes in c:\harbour\include/clipdefs.h:

#ifndef HB_APIEXT_H_
typedef HB_VMHANDLE HANDLE;
typedef USHORT BOOL;
typedef unsigned int WORD;
#endif

Are you using #include <clipdefs.h> in your C code ? If so, please remove it and just use #include <hbapi.h>
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42203
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Issue with FWH64/Harbour64/BCC7164 and Mysql.h file(SOLVED)

Postby Compuin » Sat Jun 26, 2021 6:16 pm

Antonio Linares wrote:Please try with these changes in c:\harbour\include/clipdefs.h:

#ifndef HB_APIEXT_H_
typedef HB_VMHANDLE HANDLE;
typedef USHORT BOOL;
typedef unsigned int WORD;
#endif

Are you using #include <clipdefs.h> in your C code ? If so, please remove it and just use #include <hbapi.h>


Hello,

I removed <clipdefs.h> and the error messages gone.

Now I can not link . c file andf getting this

c:\bcc7164\bin\ilink64 -Gn -aa -Tpe -s @b64.bc
Turbo Incremental Link64 6.75 Copyright (c) 1997-2016 Embarcadero Technologies, Inc.
Fatal: Unable to open file 'Libreria.OBJ'

** error 2 ** deleting clinica.exe

C:\clinica>


This is my .mak file

Code: Select all  Expand view  RUN

#Borland make 64 bits (c) FiveTech Software 2016

HBDIR=c:\harbour
BCDIR=c:\bcc7164
FWDIR=c:\fwh64

#change these paths as needed
.path.obj = .\obj
.path.prg = .\prg
.path.ch = .\Include;$(FWDIR)\include;$(HBDIR)\include
.path.c   = .\c
.path.rc  = .\Resource

PRG =          \
.\Clinica.prg  \
.\Another.prg  \

C =            \
.\Libreria.c    \

OBJ=$(PRG:.prg=.obj) $(C:.c=.obj)
OBJS=$(OBJ:.\=.\obj\)

PROJECT    : clinica.exe

clinica.exe  : $(OBJS) clinica.res

   echo off
   echo $(BCDIR)\lib\c0w64.o + > b64.bc
   echo $(OBJS), + >> b64.bc
   echo clinica.exe, + >> b64.bc
   echo clinica.map, + >> b64.bc
   echo $(FWDIR)\lib\Five64.a $(FWDIR)\lib\FiveC64.a + >> b64.bc
   echo $(FWDIR)\lib\libmariadb64.a + >> b64.bc
   echo $(HBDIR)\lib\hbrtl.a + >> b64.bc
   echo $(HBDIR)\lib\hbvm.a + >> b64.bc
   echo $(HBDIR)\lib\gtgui.a + >> b64.bc
   echo $(HBDIR)\lib\hblang.a + >> b64.bc
   echo $(HBDIR)\lib\hbmacro.a + >> b64.bc
   echo $(HBDIR)\lib\hbrdd.a + >> b64.bc
   echo $(HBDIR)\lib\rddntx.a + >> b64.bc
   echo $(HBDIR)\lib\rddcdx.a + >> b64.bc
   echo $(HBDIR)\lib\rddfpt.a + >> b64.bc
   echo $(HBDIR)\lib\hbsix.a + >> b64.bc
   echo $(HBDIR)\lib\hbdebug.a + >> b64.bc
   echo $(HBDIR)\lib\hbcommon.a + >> b64.bc
   echo $(HBDIR)\lib\hbpp.a + >> b64.bc
   echo $(HBDIR)\lib\hbwin.a + >> b64.bc
   echo $(HBDIR)\lib\hbcpage.a + >> b64.bc
   echo $(HBDIR)\lib\hbct.a + >> b64.bc
   echo $(HBDIR)\lib\hbcplr.a + >> b64.bc
   echo $(HBDIR)\lib\hbpcre.a + >> b64.bc
   echo $(HBDIR)\lib\xhb.a + >> b64.bc
   echo $(HBDIR)\lib\hbziparc.a + >> b64.bc
   echo $(HBDIR)\lib\hbmzip.a + >> b64.bc
   echo $(HBDIR)\lib\hbzlib.a + >> b64.bc
   echo $(HBDIR)\lib\minizip.a + >> b64.bc
   echo $(HBDIR)\lib\png.a + >> b64.bc
   echo $(HBDIR)\lib\hbusrrdd.a + >> b64.bc
   echo $(HBDIR)\lib\hbtip.a + >> b64.bc

   echo $(BCDIR)\lib\cw64.a + >> b64.bc
   echo $(BCDIR)\lib\psdk\kernel32.a + >> b64.bc
   echo $(BCDIR)\lib\psdk\user32.a + >> b64.bc
   echo $(BCDIR)\lib\psdk\iphlpapi.a + >> b64bc
   echo $(BCDIR)\lib\import64.a, >> b64.bc

   IF EXIST .\Resource\clinica.res echo .\Resource\clinica.res >> b64.bc
   $(BCDIR)\bin\ilink64 -Gn -aa -Tpe -s @b64.bc
   del b64.bc
   del b64bc
   del tmp
   del *.map
   
   if ERRORLEVEL 0 clinica.exe
   
.PRG.OBJ:
  $(HBDIR)\bin\harbour $< /L /N /W /Oobj\ /I$(FWDIR)\include;$(HBDIR)\include;i../include
  $(BCDIR)\bin\bcc64 -c -tWM -I$(HBDIR)\include -I$(BCDIR)\include\windows\sdk -I$(BCDIR)\include\windows\crtl -oobj\$&.obj obj\$&.c

.C.OBJ:
  echo -c -tWM -D__HARBOUR__ -DHB_API_MACROS > tmp
  echo -I$(HBDIR)\include;$(FWDIR)\include >> tmp
  $(BCDIR)\bin\bcc64 -I$(BCDIR)\include\windows\sdk -I$(BCDIR)\include\windows\crtl -oobj\$& @tmp c\$&.c
  del tmp

clinica.res : clinica.rc
  $(BCDIR)\bin\brc32.exe -r -D__64__ -I%bcdir%\include -I%bcdir%\include\windows\sdk .\Resource\clinica.rc
 
 
FWH 20.12
Hbmk2 32/64 Bits (Build 19.29.30133)
Microsoft Visual C 32 Bits
MySql 8.0.24 32/64 Bits
VS Code
Compuin
 
Posts: 1214
Joined: Tue Dec 28, 2010 1:29 pm
Location: Quebec, Canada

Re: Issue with FWH64/Harbour64/BCC7164 and Mysql.h file(SOLVED)

Postby Antonio Linares » Sat Jun 26, 2021 7:05 pm

Existe el fichero .\c\Libreria.c ?
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42203
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Issue with FWH64/Harbour64/BCC7164 and Mysql.h file(SOLVED)

Postby Compuin » Sat Jun 26, 2021 7:07 pm

Antonio Linares wrote:Existe el fichero Libreria.c ?


Si, esun fichero con codigo C y se encuentra en un folder llamado c
FWH 20.12
Hbmk2 32/64 Bits (Build 19.29.30133)
Microsoft Visual C 32 Bits
MySql 8.0.24 32/64 Bits
VS Code
Compuin
 
Posts: 1214
Joined: Tue Dec 28, 2010 1:29 pm
Location: Quebec, Canada

Re: Issue with FWH64/Harbour64/BCC7164 and Mysql.h file(SOLVED)

Postby Antonio Linares » Sat Jun 26, 2021 7:10 pm

Se llega a compilar ?

Comprueba si existe Libreria.obj
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42203
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Issue with FWH64/Harbour64/BCC7164 and Mysql.h file(SOLVED)

Postby Compuin » Sat Jun 26, 2021 7:15 pm

Antonio Linares wrote:Se llega a compilar ?

Comprueba si existe Libreria.obj


Si maestro
FWH 20.12
Hbmk2 32/64 Bits (Build 19.29.30133)
Microsoft Visual C 32 Bits
MySql 8.0.24 32/64 Bits
VS Code
Compuin
 
Posts: 1214
Joined: Tue Dec 28, 2010 1:29 pm
Location: Quebec, Canada

Next

Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 11 guests

cron