Error linking MinGW32

Error linking MinGW32

Postby ADutheil » Tue Mar 13, 2012 2:12 am

I am having trouble linking CT lib with FWH under MinGW32:

E:/hb31/lib/win/mingw/libhbct.a(disk.o):disk.c:(.text+0xd0): multiple definition of `HB_FUN_DRIVETYPE'
C:/FWH/lib/fivehgc.lib(C5CNEW.o):C5CNEW.C:(.text+0x4e89): first defined here
E:/hb31/lib/win/mingw/libhbct.a(files.o):files.c:(.text+0x630): multiple definition of `HB_FUN_DELETEFILE'
C:/FWH/lib/fivehgc.lib(C5CNEW.o):C5CNEW.C:(.text+0x169f): first defined here

Is this a known problem?
Regards,

André Dutheil
FWH 13.04 + HB 3.2 + MSVS 10
ADutheil
 
Posts: 368
Joined: Sun May 31, 2009 6:25 pm
Location: Salvador - Bahia - Brazil

Re: Error linking MinGW32

Postby nnicanor » Tue Mar 13, 2012 4:43 am

Add --allow-multiple-definition after -Wall

Regards
Nicanor Martinez M.
Auditoria y Sistemas Ltda.
MicroExpress Ltda.
FW + FWH + XHARBOUR + HARBOUR + PELLES C + XDEVSTUDIO + XEDIT + BCC + VC_X86 + VCC_X64 + MINGW + R&R Reports + FastReport + Tdolphin + ADO + MYSQL + MARIADB + ORACLE
nnicanor@yahoo.com
nnicanor
 
Posts: 302
Joined: Fri Apr 23, 2010 4:30 am
Location: Colombia

Re: Error linking MinGW32

Postby ADutheil » Tue Mar 13, 2012 11:11 am

nnicanor thanks for the reply but I tryed without succes. I use a bat file with hbmk2:
Code: Select all  Expand view
SET PATH=e:\hb31\comp\mingw;E:\hb31\bin\;C:\WINDOWS;C:\WINDOWS\SYSTEM32
HBMK2 -inc -run -ic:\fwh\include -iINCLUDES wegb32.hbm C:\FWH\fwhgSQL.hbc contrib.hbc

I included ldflags=--allow-multiple-definition in contrib.hbc but it did not work: gcc.exe: error: unrecognized option '--allow-multiple-definition'
When I use cflags=--allow-multiple-definition it doesnt not work either.
Regards,

André Dutheil
FWH 13.04 + HB 3.2 + MSVS 10
ADutheil
 
Posts: 368
Joined: Sun May 31, 2009 6:25 pm
Location: Salvador - Bahia - Brazil

Re: Error linking MinGW32 (SOLVED)

Postby ADutheil » Tue Mar 13, 2012 12:31 pm

Changed my batch file to
Code: Select all  Expand view
SET PATH=e:\hb31\comp\mingw;E:\hb31\bin\;C:\WINDOWS;C:\WINDOWS\SYSTEM32
HBMK2 -ldflag={allgcc}-Wl,--allow-multiple-definition -inc -run -ic:\fwh\include -iINCLUDES wegb32.hbm C:\FWH\fwhgSQL.hbc contrib.hbc
 
Regards,

André Dutheil
FWH 13.04 + HB 3.2 + MSVS 10
ADutheil
 
Posts: 368
Joined: Sun May 31, 2009 6:25 pm
Location: Salvador - Bahia - Brazil

Re: Error linking MinGW32

Postby nnicanor » Fri Mar 23, 2012 7:33 pm

After upgrade, new MINGW release does not need a multiple definition flag.

Regards,
Nicanor Martinez M.
Auditoria y Sistemas Ltda.
MicroExpress Ltda.
FW + FWH + XHARBOUR + HARBOUR + PELLES C + XDEVSTUDIO + XEDIT + BCC + VC_X86 + VCC_X64 + MINGW + R&R Reports + FastReport + Tdolphin + ADO + MYSQL + MARIADB + ORACLE
nnicanor@yahoo.com
nnicanor
 
Posts: 302
Joined: Fri Apr 23, 2010 4:30 am
Location: Colombia


Return to FiveWin for Harbour/xHarbour

Who is online

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