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

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

Postby Compuin » Wed Jun 30, 2021 9:38 pm

Estoy usando el fwh 32 bits

El Harbour que uso es 32

El Visual Studio es 2019

Aca mi archivo .mak

Code: Select all  Expand view

#Microsoft VS2019 make sample, (c) FiveTech Software 2014

HBDIR=c:\harbour_msvc32
FWDIR=c:\fwh
VCDIR="C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC"
SDKDIR="C:\Program Files (x86)\Windows Kits\10"

.SUFFIXES: .prg .c .obj .rc .res

one.exe : one.obj two.obj three.obj one.res
   echo one.obj two.obj three.obj > msvc.tmp

   echo $(FWDIR)\lib\FiveH32.lib $(FWDIR)\lib\FiveHC32.lib >> msvc.tmp

   echo $(HBDIR)\lib\hbrtl.lib    >> msvc.tmp
   echo $(HBDIR)\lib\hbvm.lib     >> msvc.tmp
   echo $(HBDIR)\lib\gtgui.lib    >> msvc.tmp
   echo $(HBDIR)\lib\hblang.lib   >> msvc.tmp
   echo $(HBDIR)\lib\hbmacro.lib  >> msvc.tmp
   echo $(HBDIR)\lib\hbrdd.lib    >> msvc.tmp
   echo $(HBDIR)\lib\rddntx.lib   >> msvc.tmp
   echo $(HBDIR)\lib\rddcdx.lib   >> msvc.tmp
   echo $(HBDIR)\lib\rddfpt.lib   >> msvc.tmp
   echo $(HBDIR)\lib\hbsix.lib    >> msvc.tmp
   echo $(HBDIR)\lib\hbdebug.lib  >> msvc.tmp
   echo $(HBDIR)\lib\hbcommon.lib >> msvc.tmp
   echo $(HBDIR)\lib\hbpp.lib     >> msvc.tmp
   echo $(HBDIR)\lib\hbwin.lib    >> msvc.tmp
   echo $(HBDIR)\lib\hbcplr.lib   >> msvc.tmp
   echo $(HBDIR)\lib\xhb.lib      >> msvc.tmp
   echo $(HBDIR)\lib\hbpcre.lib   >> msvc.tmp
   echo $(HBDIR)\lib\hbct.lib     >> msvc.tmp
   echo $(HBDIR)\lib\hbcpage.lib  >> msvc.tmp
   echo $(HBDIR)\lib\hbzlib.lib   >> msvc.tmp
   echo $(HBDIR)\lib\png.lib      >> msvc.tmp

   echo kernel32.lib  >> msvc.tmp
   echo user32.lib    >> msvc.tmp
   echo gdi32.lib     >> msvc.tmp
   echo winspool.lib  >> msvc.tmp
   echo comctl32.lib  >> msvc.tmp
   echo comdlg32.lib  >> msvc.tmp
   echo advapi32.lib  >> msvc.tmp
   echo shell32.lib   >> msvc.tmp
   echo ole32.lib     >> msvc.tmp
   echo oleaut32.lib  >> msvc.tmp
   echo uuid.lib      >> msvc.tmp
   echo odbc32.lib    >> msvc.tmp
   echo odbccp32.lib  >> msvc.tmp
   echo iphlpapi.lib  >> msvc.tmp
   echo mpr.lib       >> msvc.tmp
   echo version.lib   >> msvc.tmp
   echo wsock32.lib   >> msvc.tmp
   echo msimg32.lib   >> msvc.tmp
   echo oledlg.lib    >> msvc.tmp
   echo psapi.lib     >> msvc.tmp
   echo gdiplus.lib   >> msvc.tmp
   echo winmm.lib     >> msvc.tmp

   IF EXIST one.res echo one.res >> msvc.tmp

   link @msvc.tmp /nologo /subsystem:windows /force:multiple /NODEFAULTLIB:libc > link.log
   @type link.log
   @del one.c
   @del two.c
   @del three.c
   @del msvc.tmp

one.obj   : one.c
two.obj   : two.c
three.obj : three.c

one.c   : one.prg
two.c   : two.prg
three.c : three.prg

one.res : one.rc
   rc.exe -r -d__FLAT__ one.rc

.prg.c:
   $(HBDIR)\bin\harbour $< /n /i$(FWDIR)\include;$(HBDIR)\include

.c.obj:
   cl.exe -c -TC -W3 -I$(HBDIR)\include -I$(SDKDIR)\include -I$(VCDIR)\include $<
 


Y aqui el .bat

Code: Select all  Expand view

@set oldpath=%path%
@set oldinclude=%include%
@set oldlib=%lib%
@set oldlibpath=%libpath%
rem if exist "%ProgramFiles%\Microsoft Visual Studio 12.0\VC\vcvarsall.bat" call "%ProgramFiles%\Microsoft Visual Studio 12.0\VC\vcvarsall.bat" x86_amd64
if exist "%ProgramFiles(x86)%\Microsoft Visual Studio\2019\Community\VC\Auxiliary\Build\vcvarsall.bat" call "%ProgramFiles(x86)%\Microsoft Visual Studio\2019\Community\VC\Auxiliary\Build\vcvarsall.bat" x86_amd64
c:\"Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.29.30037\bin\Hostx64\x86\nmake -ftest.mak
rem c:\"Program Files (x86)\Microsoft Visual Studio 12.0"
\VC\bin\nmake -ftest.mak
nmake -ftest.mak
@set path=%oldpath%
@set include=%oldinclude%
@set lib=%oldlib%
@set libpath=%oldlibpath%
@set oldpath=""
@set oldinclude=""
@set oldlib=
@set oldlibpath=
if errorlevel==0 one.exe
 
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: 1213
Joined: Tue Dec 28, 2010 1:29 pm
Location: Quebec, Canada

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

Postby Antonio Linares » Thu Jul 01, 2021 7:03 am

Esto le indica al enlazador que vamos a construir una app de 64 bits:

... vcvarsall.bat" x86_amd64

y asi le indicamos que es de 32 bits:

... vcvarsall.bat" x86
regards, saludos

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

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

Postby Compuin » Thu Jul 01, 2021 11:37 am

Antonio Linares wrote:Esto le indica al enlazador que vamos a construir una app de 64 bits:

... vcvarsall.bat" x86_amd64

y asi le indicamos que es de 32 bits:

... vcvarsall.bat" x86


Maestro,

Lo pude compilar

Image

Ahora voy a tratar de incluir archivos escritos en C y enlazar todo junto
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: 1213
Joined: Tue Dec 28, 2010 1:29 pm
Location: Quebec, Canada

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

Postby Compuin » Thu Jul 01, 2021 12:02 pm

Maestro,

Compilando el ERP.PRG que viene en fwh\sample, tengop estas incidencias con MSVC

FiveWin for Harbour 20.12 (MSVC++) Dic. 2019 Harbour development power
Aplicacion Desarrollo.

Microsoft (R) Program Maintenance Utility Version 14.29.30038.1
Copyright (C) Microsoft Corporation. All rights reserved.

cl.exe -TP -W3 -c /GS- -I..\Harbour_msvc64\include -I..\mysql\Include /GA erp.c
Microsoft (R) C/C++ Optimizing Compiler Version 19.29.30038.1 for x64
Copyright (C) Microsoft Corporation. All rights reserved.

erp.c
erp.prg(201): warning C4311: 'type cast': pointer truncation from 'MYSQL *' to 'long'
erp.prg(201): warning C4302: 'type cast': truncation from 'MYSQL *' to 'long'
erp.prg(208): warning C4312: 'type cast': conversion from 'long' to 'MYSQL *' of greater size
erp.prg(215): warning C4311: 'type cast': pointer truncation from 'MYSQL *' to 'HB_BOOL'
erp.prg(215): warning C4302: 'type cast': truncation from 'MYSQL *' to 'HB_BOOL'
erp.prg(222): warning C4312: 'type cast': conversion from 'long' to 'MYSQL *' of greater size
erp.prg(246): warning C4312: 'type cast': conversion from 'long' to 'MYSQL *' of greater size
erp.prg(271): warning C4312: 'type cast': conversion from 'long' to 'void *' of greater size
erp.prg(271): error C2664: 'int mysql_real_query(MYSQL *,const char *,unsigned long)': cannot convert argument 1 from 'void *' to 'MYSQL *'
erp.prg(271): note: Conversion from 'void*' to pointer to non-'void' requires an explicit cast
..\mysql\Include\mysql.h(405): note: see declaration of 'mysql_real_query'
erp.prg(278): warning C4312: 'type cast': conversion from 'long' to 'MYSQL *' of greater size
erp.prg(278): warning C4311: 'type cast': pointer truncation from 'MYSQL_RES *' to 'long'
erp.prg(278): warning C4302: 'type cast': truncation from 'MYSQL_RES *' to 'long'
erp.prg(285): warning C4312: 'type cast': conversion from 'long' to 'MYSQL_RES *' of greater size
erp.prg(292): warning C4312: 'type cast': conversion from 'long' to 'MYSQL_RES *' of greater size
erp.prg(317): warning C4312: 'type cast': conversion from 'long' to 'MYSQL_RES *' of greater size
erp.prg(324): warning C4312: 'type cast': conversion from 'long' to 'MYSQL *' of greater size
erp.prg(331): warning C4312: 'type cast': conversion from 'long' to 'MYSQL *' of greater size
erp.prg(338): warning C4312: 'type cast': conversion from 'long' to 'MYSQL *' of greater size
erp.prg(338): warning C4311: 'type cast': pointer truncation from 'MYSQL_RES *' to 'long'
erp.prg(338): warning C4302: 'type cast': truncation from 'MYSQL_RES *' to 'long'
erp.prg(345): warning C4312: 'type cast': conversion from 'long' to 'MYSQL_RES *' of greater size
erp.prg(352): warning C4312: 'type cast': conversion from 'long' to 'MYSQL *' of greater size
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.29.30037\bin\HostX86\x64\cl.exe"' : return code '0x2'
Stop.
'one.exe' is not recognized as an internal or external command,
operable program or batch file.

C:\sistema64>


Es necesario hacer algun otro ajuste?
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: 1213
Joined: Tue Dec 28, 2010 1:29 pm
Location: Quebec, Canada

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

Postby Antonio Linares » Thu Jul 01, 2021 2:41 pm

Modifica la línea 271 de erp.prg así:

hb_retl( mysql_real_query( ( MYSQL * ) hb_parnl( 1 ), hb_parc( 2 ), hb_parnl( 3 ) ) );
regards, saludos

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

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

Postby Compuin » Thu Jul 01, 2021 2:55 pm

Antonio Linares wrote:Modifica la línea 271 de erp.prg así:

hb_retl( mysql_real_query( ( MYSQL * ) hb_parnl( 1 ), hb_parc( 2 ), hb_parnl( 3 ) ) );


Logro crear el ejecutable, pero al correrlo arroja este archivo hb_out.log

Application Internal Error - C:\sistema64\erp.exe
Terminated at: 2021-07-01 10:53:06
Unrecoverable error 6005: Exception error:

Exception Code:C0000005 ACCESS_VIOLATION
Exception Address:00007FFF712195D0
RAX:FFFFFFFFEFE6DDB0 RBX:0000000000000000 RCX:FFFFFFFFEFE6DDB0 RDX:00007FF7C35305DC
RSI:0000000000000001 RDI:0000000000000000 RBP:00007FF7C36AF000
R8 :00007FF7C35305E8 R9 :00007FF7C364A710 R10:00000139F187C1B0 R11:000000000000FFFF
R12:0000000000000002 R13:0000000000000000 R14:00007FF7C3530EED R15:0000000000000400
CS:RIP:0033:00007FFF712195D0 SS:RSP:002B:000000041C3FF508
DS:002B ES:002B FS:0053 GS:002B
Flags:00010202
Exception Parameters: 0000000000000000 FFFFFFFFEFE6E240

Modules:
00007FF7C3350000 00000000004F1000 C:\sistema64\erp.exe
00007FFF9E230000 00000000001F5000 C:\WINDOWS\SYSTEM32\ntdll.dll
00007FFF9D850000 00000000000BD000 C:\WINDOWS\System32\KERNEL32.DLL
00007FFF9BFD0000 00000000002C9000 C:\WINDOWS\System32\KERNELBASE.dll
00007FFF9E050000 00000000001A0000 C:\WINDOWS\System32\USER32.dll
00007FFF9BB10000 0000000000022000 C:\WINDOWS\System32\win32u.dll
00007FFF9D9E0000 000000000002A000 C:\WINDOWS\System32\GDI32.dll
00007FFF9BE90000 000000000010B000 C:\WINDOWS\System32\gdi32full.dll
00007FFF9BCF0000 000000000009D000 C:\WINDOWS\System32\msvcp_win.dll
00007FFF9BD90000 0000000000100000 C:\WINDOWS\System32\ucrtbase.dll
00007FFF71200000 0000000000112000 C:\sistema64\libmariadb.dll
00007FFF9C560000 00000000000DA000 C:\WINDOWS\System32\COMDLG32.dll
00007FFF9D5B0000 000000000009E000 C:\WINDOWS\System32\msvcrt.dll
00007FFF9DAB0000 00000000000AC000 C:\WINDOWS\System32\ADVAPI32.dll
00007FFF9DA10000 000000000009B000 C:\WINDOWS\System32\sechost.dll
00007FFF9C660000 0000000000355000 C:\WINDOWS\System32\combase.dll
00007FFF9C430000 000000000012A000 C:\WINDOWS\System32\RPCRT4.dll
00007FFF7F8D0000 00000000000B0000 C:\WINDOWS\WinSxS\amd64_microsoft.windows.common-controls_6595b64144ccf1df_5.82.19041.844_none_423537bff6b9828c\COMCTL32.dll
00007FFF94CB0000 000000000008E000 C:\WINDOWS\SYSTEM32\WINSPOOL.DRV
00007FFF9CA70000 00000000000AE000 C:\WINDOWS\System32\shcore.dll
00007FFF9D7E0000 000000000006B000 C:\WINDOWS\System32\WS2_32.dll
00007FFF9D270000 0000000000055000 C:\WINDOWS\System32\SHLWAPI.dll
00007FFF9CB20000 000000000073F000 C:\WINDOWS\System32\SHELL32.dll
00007FFF9D2D0000 000000000012A000 C:\WINDOWS\System32\ole32.dll
00007FFF9D910000 00000000000CD000 C:\WINDOWS\System32\OLEAUT32.dll
00007FFF84C50000 000000000001D000 C:\WINDOWS\SYSTEM32\MPR.dll
00007FFF92790000 000000000000A000 C:\WINDOWS\SYSTEM32\VERSION.dll
00007FFF93780000 00000000001AB000 C:\WINDOWS\WinSxS\amd64_microsoft.windows.gdiplus_6595b64144ccf1df_1.1.19041.1081_none_91a70388cc8594fd\gdiplus.dll
00007FFF94D40000 0000000000007000 C:\WINDOWS\SYSTEM32\MSIMG32.dll
00007FFF949D0000 0000000000038000 C:\WINDOWS\SYSTEM32\oledlg.dll
00007FFF95270000 0000000000027000 C:\WINDOWS\SYSTEM32\WINMM.dll
00007FFF9B2D0000 000000000000C000 C:\WINDOWS\SYSTEM32\CRYPTBASE.DLL
00007FFF9C400000 0000000000030000 C:\WINDOWS\System32\IMM32.DLL
00007FFF99400000 000000000009E000 C:\WINDOWS\system32\uxtheme.dll
00007FFF9D6C0000 0000000000115000 C:\WINDOWS\System32\MSCTF.dll
00007FFF90210000 0000000000017000 C:\WINDOWS\system32\napinsp.dll
00007FFF901F0000 000000000001B000 C:\WINDOWS\system32\pnrpnsp.dll
00007FFF95EE0000 000000000001D000 C:\WINDOWS\system32\NLAapi.dll
00007FFF9AD60000 000000000003B000 C:\WINDOWS\SYSTEM32\IPHLPAPI.DLL
00007FFF901B0000 0000000000015000 C:\WINDOWS\system32\wshbth.dll
00007FFF9B070000 000000000006A000 C:\WINDOWS\System32\mswsock.dll
00007FFF9ADA0000 00000000000CC000 C:\WINDOWS\SYSTEM32\DNSAPI.dll
00007FFF9C2A0000 0000000000008000 C:\WINDOWS\System32\NSI.dll
00007FFF90190000 0000000000012000 C:\WINDOWS\System32\winrnr.dll
00007FFF933B0000 000000000000A000 C:\Windows\System32\rasadhlp.dll

Called from MYSQL_REAL_CONNECT(0)
Called from TMYSQL:CONNECT(127) in erp.prg
Called from MAIN(11) in erp.prg
------------------------------------------------------------------------

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: 1213
Joined: Tue Dec 28, 2010 1:29 pm
Location: Quebec, Canada

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

Postby Antonio Linares » Thu Jul 01, 2021 3:40 pm

Tienes instalado un servidor MySQL en el ordenador en donde estas probándolo ?
regards, saludos

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

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

Postby Compuin » Thu Jul 01, 2021 3:42 pm

Antonio Linares wrote:Tienes instalado un servidor MySQL en el ordenador en donde estas probándolo ?


Asi es,

Con las versiones compiladas a 32/64 bits en Borland funcionan ok
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: 1213
Joined: Tue Dec 28, 2010 1:29 pm
Location: Quebec, Canada

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

Postby Compuin » Thu Jul 01, 2021 3:46 pm

Antonio Linares wrote:Tienes instalado un servidor MySQL en el ordenador en donde estas probándolo ?


Le envio los archivos por wetransfer ?
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: 1213
Joined: Tue Dec 28, 2010 1:29 pm
Location: Quebec, Canada

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

Postby Antonio Linares » Thu Jul 01, 2021 4:32 pm

Prueba asi:

hb_retl( mysql_real_query( ( void * ) hb_parnll( 1 ), hb_parc( 2 ), hb_parnl( 3 ) ) );

Si el error se soluciona, entonces cambia todos los hb_parnl() a hb_parnll() y los hb_retnl() a hb_retnll()

Al tratarse de una aplicación de 64 bits hay que usar hb_parnll() y hb_retnll(). Lo correcto sería usar hb_parptr() y hb_retptr() que usan punteros con su tamaño correcto.
regards, saludos

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

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

Postby Compuin » Thu Jul 01, 2021 4:49 pm

Antonio Linares wrote:Prueba asi:

hb_retl( mysql_real_query( ( void * ) hb_parnll( 1 ), hb_parc( 2 ), hb_parnl( 3 ) ) );

Si el error se soluciona, entonces cambia todos los hb_parnl() a hb_parnll() y los hb_retnl() a hb_retnll()

Al tratarse de una aplicación de 64 bits hay que usar hb_parnll() y hb_retnll(). Lo correcto sería usar hb_parptr() y hb_retptr() que usan punteros con su tamaño correcto.



Ahora ni siquiera lo compila
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: 1213
Joined: Tue Dec 28, 2010 1:29 pm
Location: Quebec, Canada

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

Postby Antonio Linares » Thu Jul 01, 2021 5:12 pm

Que error da ?
regards, saludos

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

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

Postby Compuin » Thu Jul 01, 2021 5:48 pm

Antonio Linares wrote:Que error da ?


FiveWin for Harbour 20.12 (MSVC++) Dic. 2019 Harbour development power
Aplicacion Desarrollo.

Microsoft (R) Program Maintenance Utility Version 14.29.30038.1
Copyright (C) Microsoft Corporation. All rights reserved.

cl.exe -TP -W3 -c /GS- -I..\Harbour_msvc64\include -I..\mysql\Include /GA erp.c
Microsoft (R) C/C++ Optimizing Compiler Version 19.29.30038.1 for x64
Copyright (C) Microsoft Corporation. All rights reserved.

erp.c
erp.prg(201): warning C4311: 'type cast': pointer truncation from 'MYSQL *' to 'long'
erp.prg(201): warning C4302: 'type cast': truncation from 'MYSQL *' to 'long'
erp.prg(208): warning C4312: 'type cast': conversion from 'long' to 'MYSQL *' of greater size
erp.prg(215): warning C4311: 'type cast': pointer truncation from 'MYSQL *' to 'HB_BOOL'
erp.prg(215): warning C4302: 'type cast': truncation from 'MYSQL *' to 'HB_BOOL'
erp.prg(222): warning C4312: 'type cast': conversion from 'long' to 'MYSQL *' of greater size
erp.prg(246): warning C4312: 'type cast': conversion from 'long' to 'MYSQL *' of greater size
erp.prg(272): error C3861: 'hb_parnlll': identifier not found
erp.prg(280): warning C4311: 'type cast': pointer truncation from 'MYSQL_RES *' to 'long'
erp.prg(280): warning C4302: 'type cast': truncation from 'MYSQL_RES *' to 'long'
erp.prg(287): error C3861: 'hb_retnlll': identifier not found
erp.prg(340): warning C4311: 'type cast': pointer truncation from 'MYSQL_RES *' to 'long'
erp.prg(340): warning C4302: 'type cast': truncation from 'MYSQL_RES *' to 'long'
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.29.30037\bin\HostX86\x64\cl.exe"' : return code '0x2'
Stop.
'erp.exe' is not recognized as an internal or external command,
operable program or batch file.

C:\sistema64>

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: 1213
Joined: Tue Dec 28, 2010 1:29 pm
Location: Quebec, Canada

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

Postby Antonio Linares » Thu Jul 01, 2021 6:36 pm

Has puesto una l de más

hb_parnlll
regards, saludos

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

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

Postby Compuin » Thu Jul 01, 2021 6:41 pm

Antonio Linares wrote:Has puesto una l de más

hb_parnlll



Tampoco

Code: Select all  Expand view

     hb_retl( mysql_real_query( ( void * ) hb_parnll( 1 ), hb_parc( 2 ), hb_parnl( 3 ) ) );
 


FiveWin for Harbour 20.12 (MSVC++) Dic. 2019 Harbour development power
Aplicacion Desarrollo.

Microsoft (R) Program Maintenance Utility Version 14.29.30038.1
Copyright (C) Microsoft Corporation. All rights reserved.

..\Harbour_msvc64\bin\harbour erp.prg /q0 /n /W -I..\Fwh64\include -I..\Harbour_msvc64\include -I..\mysql\Include
erp.prg(131) Warning W0001 Method <GetDataBases()> not declared or declaration mismatch in class <TMySQL>
erp.prg(145) Warning W0001 Method <GetTables()> not declared or declaration mismatch in class <TMySQL>
cl.exe -TP -W3 -c /GS- -I..\Harbour_msvc64\include -I..\mysql\Include /GA erp.c
Microsoft (R) C/C++ Optimizing Compiler Version 19.29.30038.1 for x64
Copyright (C) Microsoft Corporation. All rights reserved.

erp.c
erp.prg(201): warning C4311: 'type cast': pointer truncation from 'MYSQL *' to 'long'
erp.prg(201): warning C4302: 'type cast': truncation from 'MYSQL *' to 'long'
erp.prg(208): warning C4312: 'type cast': conversion from 'long' to 'MYSQL *' of greater size
erp.prg(215): warning C4311: 'type cast': pointer truncation from 'MYSQL *' to 'HB_BOOL'
erp.prg(215): warning C4302: 'type cast': truncation from 'MYSQL *' to 'HB_BOOL'
erp.prg(222): warning C4312: 'type cast': conversion from 'long' to 'MYSQL *' of greater size
erp.prg(246): warning C4312: 'type cast': conversion from 'long' to 'MYSQL *' of greater size
erp.prg(272): error C2664: 'int mysql_real_query(MYSQL *,const char *,unsigned long)': cannot convert argument 1 from 'void *' to 'MYSQL *'
erp.prg(272): note: Conversion from 'void*' to pointer to non-'void' requires an explicit cast
..\mysql\Include\mysql.h(405): note: see declaration of 'mysql_real_query'
erp.prg(279): warning C4312: 'type cast': conversion from 'long' to 'MYSQL *' of greater size
erp.prg(279): warning C4311: 'type cast': pointer truncation from 'MYSQL_RES *' to 'long'
erp.prg(279): warning C4302: 'type cast': truncation from 'MYSQL_RES *' to 'long'
erp.prg(286): warning C4312: 'type cast': conversion from 'long' to 'MYSQL_RES *' of greater size
erp.prg(293): warning C4312: 'type cast': conversion from 'long' to 'MYSQL_RES *' of greater size
erp.prg(318): warning C4312: 'type cast': conversion from 'long' to 'MYSQL_RES *' of greater size
erp.prg(325): warning C4312: 'type cast': conversion from 'long' to 'MYSQL *' of greater size
erp.prg(332): warning C4312: 'type cast': conversion from 'long' to 'MYSQL *' of greater size
erp.prg(339): warning C4312: 'type cast': conversion from 'long' to 'MYSQL *' of greater size
erp.prg(339): warning C4311: 'type cast': pointer truncation from 'MYSQL_RES *' to 'long'
erp.prg(339): warning C4302: 'type cast': truncation from 'MYSQL_RES *' to 'long'
erp.prg(346): warning C4312: 'type cast': conversion from 'long' to 'MYSQL_RES *' of greater size
erp.prg(353): warning C4312: 'type cast': conversion from 'long' to 'MYSQL *' of greater size
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.29.30037\bin\HostX86\x64\cl.exe"' : return code '0x2'
Stop.
'erp.exe' is not recognized as an internal or external command,
operable program or batch file.

C:\sistema64>
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: 1213
Joined: Tue Dec 28, 2010 1:29 pm
Location: Quebec, Canada

PreviousNext

Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot] and 103 guests