Migrar Clipper para Harbour (Como usar DLLs do Clipper)
Enviado: 04 Jul 2021 15:29
Olá amigos!!
Tenho a missão de migrar um sistema feito em Clipper para Harbour.
O sistema não é meu e no momento tenho os PRGs do sistema e também uma DLL específica do sistema.
O sistema em Clipper funciona hoje em dia no Windows10.
No momento o problema é a DLL. Como posso usa-la para gerar o sistema em Harbour?
Primeiro estou tentando gerar aqui no meu ambiente Linux. Depois, vou para o Windows.
01) Meu arquivo hbp está assim
2) Meu ambiente está assim:
$ harbour --version
Harbour 3.2.0dev (r1712151853)
Copyright (c) 1999-2016, http://harbour-project.org/
$ gcc --version
gcc (Ubuntu 9.3.0-17ubuntu1~20.04) 9.3.0
Copyright (C) 2019 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.[/code]
3) Ao compilar, a saída está abaixo (mantive os trechos mais importantes):
Já busquei informações aqui no Forum mas por enquanto sem sucesso.
Qualquer ajuda será bem-vinda
Obrigado!!
Sergio Lima
Tenho a missão de migrar um sistema feito em Clipper para Harbour.
O sistema não é meu e no momento tenho os PRGs do sistema e também uma DLL específica do sistema.
O sistema em Clipper funciona hoje em dia no Windows10.
No momento o problema é a DLL. Como posso usa-la para gerar o sistema em Harbour?
Primeiro estou tentando gerar aqui no meu ambiente Linux. Depois, vou para o Windows.
01) Meu arquivo hbp está assim
Código: Selecionar todos
#
# $Id: compila.hbp $
#
-w0
-gc3
-osgcexe
-lhbct
hbct.hbc
-l/home/sergio/workspace/github/sergiosouzalima@gmail.com/sgc/prg/SGCG0.DLL
SGC.prg
PNEWACCE.prg
PVENDEDO.prg
...
..
$ harbour --version
Harbour 3.2.0dev (r1712151853)
Copyright (c) 1999-2016, http://harbour-project.org/
$ gcc --version
gcc (Ubuntu 9.3.0-17ubuntu1~20.04) 9.3.0
Copyright (C) 2019 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.[/code]
3) Ao compilar, a saída está abaixo (mantive os trechos mais importantes):
Código: Selecionar todos
$ hbmk2 compila.hbp
...
..
PACCXUSR.c:(.text+0x1360): multiple definition of `HB_FUN_PROCES_B6'; /tmp/hbmk_BBR3e1.dir/SGC.o:SGC.c:(.text+0x296110): first defined here
/usr/bin/ld: /tmp/hbmk_BBR3e1.dir/PACCXUSR.o: in function `HB_FUN_LOSCHEQU6B':
PACCXUSR.c:(.text+0x2ac0): multiple definition of `HB_FUN_LOSCHEQU6B'; /tmp/hbmk_BBR3e1.dir/SGC.o:SGC.c:(.text+0x136fb0): first defined here
/home/sergio/workspace/github/sergiosouzalima@gmail.com/sgc/prg/SGCG0.DLL: file not recognized: file format not recognized
collect2: error: ld returned 1 exit status
hbmk2[compila]: Error: Running linker. 1
gcc '/tmp/hbmk_BBR3e1.dir/SGC.o' '/tmp/hbmk_BBR3e1.dir/PNEWACCE.o' '/tmp/hbmk_BBR3e1.dir/PVENDEDO.o' '/tmp/hbmk_BBR3e1.dir/PESTADOS.o' '/tmp/hbmk_BBR3e1.dir/PTIPCLIE.o' '/tmp/hbmk_BBR3e1.dir/PRECAUDA.o' '/tmp/hbmk_BBR3e1.dir/PCONVENI.o' '/tmp/hbmk_BBR3e1.dir/PMOVILES.o' '/tmp/hbmk_BBR3e1.dir/PNODOS.o' '/tmp/hbmk_BBR3e1.dir/PSERVICI.o' '/tmp/hbmk_BBR3e1.dir/PMENSAJE.o' '/tmp/hbmk_BBR3e1.dir/PPARAMET.o' '/tmp/hbmk_BBR3e1.dir/PCLIENTE.o' '/tmp/hbmk_BBR3e1.dir/PCTOSUSC.o' '/tmp/hbmk_BBR3e1.dir/PSOLSERV.o' '/tmp/hbmk_BBR3e1.dir/PMATER.o' '/tmp/hbmk_BBR3e1.dir/PSITCOBR.o' '/tmp/hbmk_BBR3e1.dir/PCARTCOB.o' '/tmp/hbmk_BBR3e1.dir/PRECLAMO.o' '/tmp/hbmk_BBR3e1.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k_BBR3e1.dir/PPVIEW.o' '/tmp/hbmk_BBR3e1.dir/PGENFAC2.o' '/tmp/hbmk_BBR3e1.dir/PRESULF2.o' '/tmp/hbmk_BBR3e1.dir/PCIERRES.o' '/tmp/hbmk_BBR3e1.dir/PCORTLOT.o' '/tmp/hbmk_BBR3e1.dir/PCONTRAT.o' '/tmp/hbmk_BBR3e1.dir/LPUBCONT.o' '/tmp/hbmk_BBR3e1.dir/PMONITO2.o' '/tmp/hbmk_BBR3e1.dir/PCORPLOT.o' '/tmp/hbmk_BBR3e1.dir/LCLIPRE2.o' '/tmp/hbmk_BBR3e1.dir/LNOTIFI3.o' '/tmp/hbmk_BBR3e1.dir/PCASTIG2.o' '/tmp/hbmk_BBR3e1.dir/PTRACONT.o' '/tmp/hbmk_BBR3e1.dir/PGENPUB.o' '/tmp/hbmk_BBR3e1.dir/LENTFACT.o' '/tmp/hbmk_BBR3e1.dir/PCORRELA.o' '/tmp/hbmk_BBR3e1.dir/LSRVOBVE.o' '/tmp/hbmk_BBR3e1.dir/POBRNCVE.o' '/tmp/hbmk_BBR3e1.dir/LSRVREVE.o' '/tmp/hbmk_BBR3e1.dir/LFAPRCOB.o' '/tmp/hbmk_BBR3e1.dir/LPAGOCOB.o' '/tmp/hbmk_BBR3e1.dir/PVERCOSO.o' '/tmp/hbmk_BBR3e1.dir/LENTBOLE.o' '/tmp/hbmk_BBR3e1.dir/PTRANSBA.o' '/tmp/hbmk_BBR3e1.dir/PPREPDAT.o' '/tmp/hbmk_BBR3e1.dir/PPAGSITC.o' '/tmp/hbmk_BBR3e1.dir/LVCTOREN.o' '/tmp/hbmk_BBR3e1.dir/PUSRLOGS.o' '/tmp/hbmk_BBR3e1.dir/PACCXUSR.o' -Wl,--start-group -lhbct -lhbcplr -lhbdebug -lharbour '/home/sergio/workspace/github/sergiosouzalima@gmail.com/sgc/prg/SGCG0.DLL' -Wl,--end-group -osgcexe -L/usr/lib/harbour
hbmk2: Error: Referenced, missing, but unknown function(s): ELORDEN_01(),
PNEWACCE(), RET_DAT_01(), MUESTRA_01(), REGRABA_01(), PANTALL_01(),
DATOGEN_01(), XLIX(), MODPSWD_01(), XLINEA(), XITE(), INGPSWD_01(),
XITMENU(), PWDIN(), PWDOUT(), NOES(), XXITE(), LOSACCESO(),
ELORDEN_39(), PVENDEDO(), PANTALL_39(), LOSVENDE(), DATOGEN_39(),
INGVEN_39(), MODVEN_39(), ELORDEN_40(), PESTADOS(), PANTALL_40(),
LOSESTADOS(), DATOGEN_40(), INGEST_40(), MODEST_40(), ELORDEN_38(),
...
..
Já busquei informações aqui no Forum mas por enquanto sem sucesso.
Qualquer ajuda será bem-vinda
Obrigado!!
Sergio Lima