Jump to content
Fivewin Brasil

Como Gerar .DLL com fwh


qiinfo

Recommended Posts

Olá,

Este ilink32 é o que está no diretório \bcc55\bin ?

Alguem poderia passar a linha de comando para gerar a dll ?

O que preciso exatamente é que algumas partes do meu sistema esta dentro de uma dll. No caso eu iria executar no inicio do .exe uma chamada a esta dll (loadlib32()).

Obrigado,

Rossine.

Meu email: qiinfo@ig.com.br

Link to comment
Share on other sites

Olá,

Consequi gerar o arquivo dll com a seguinte linha abaixo:

\bcc55\bin\ilink32 -Gn -aa -Tpd -s @dll.bc

o conteudo de dll.bc é:

c0w32.obj +

dll.obj, +

dll.dll, +

dll.map, +

\fwh\lib\FiveHX.lib \fwh\lib\FiveHC.lib +

c:\xharbour\lib\rtl.lib +

c:\xharbour\lib\vm.lib +

c:\xharbour\lib\gtwin.lib +

c:\xharbour\lib\lang.lib +

c:\xharbour\lib\macro.lib +

c:\xharbour\lib\rdd.lib +

c:\xharbour\lib\dbfntx.lib +

c:\xharbour\lib\dbfdbt.lib +

c:\xharbour\lib\dbfcdx.lib +

c:\xharbour\lib\dbffpt.lib +

c:\xharbour\lib\debug.lib +

c:\xharbour\lib\common.lib +

c:\xharbour\lib\pp.lib +

c:\bcc55\lib\cw32.lib +

c:\bcc55\lib\import32.lib +

c:\bcc55\lib\psdk\odbc32.lib,

PERGUNTA (1): COMO DIMINUIR O TAMANHO DO ARQUIVO PARA APROXIMADAMENTE = AO 16 BITS ?

O arquivo gerado .DLL ficou com o tamanho 1.013.248 kb

No meu sistema em 16 bits (fw2.2c) o mesmo .dll deve ficar 2.000 kb

OBS: NA MINHA OPINIAO NENHUMA DESTAS LIBS DEVERIAM SER COMPILADAS DENTRO DA DLL, POIS ELAS ESTARAO NA MEMORIA QUANDO O O ARQUIVO .DLL FOR CHAMADO...

No blinker para 16 bits uso o seguinte .lnk

BLINKER EXECUTABLE EXTENDED

BLINKER EXECUTABLE NODELETE <-- uso isto para forçar a geracao da dll

BLINKER EXECUTABLE COMPRESS 1

BLINKER INCREMENTAL OFF

PACKCODE

PACKDATA

file dll

file bldclp52

lib fivestub

defbegin

library DLL

exetype windows 3.1

exports

TESTE_DLL

nodeflib

OUTPUT DLL

PERGUNTA (2):

OS PARAMETROS ENVIADOS E RECEBIDOS NAO ESTAO FUNCIONANDO TAMBEM. COMO FAZER ISTO FICAR CERTO ?

***************************************

FONTE DO PROGRAMA TDLL.EXE

***************************************

#include "fivewin.ch"

FUNC main()

nDll := "dll.dll"

xDll := LoadLib32( nDll )

? xDll && PORQUE ESTE PRINT NAO ESTA' SENDO EXECUTADO

? TESTE_D( "EU" ) && A FUNCAO TESTE_DLL DENTRO DE DLL.DLL NAO ESTA RECEBENDO

&& ESTE PARAMETRO.

FreeLib32( xDll )

SysRefresh()

RETURN NIL

DLL32 function TESTE_D( NOME as STRING ) AS LONG PASCAL from "TESTE_DLL" lib xDll

*************************************

PROGRAMA FONTE DO DLL.DLL

*************************************

#include "fivewin.ch"

******************

function TESTE_DLL( TIPO )

******************

? TIPO && PORQUE O PARAMETRO NAO E' PASSADO CORRETAMENTE ?

? "ESTOU NA DLL "

return -10 && PORQUE O PARAMETRO NAO E' RETORNADO CORRETAMENTE ?

ALGUM DOS FERAS DESTE FORUM (VAGNER,KARINH,GILMER,EVANDRO, E OUTROS) PODERIAM POR FAVOR TENTAR ME AJUDAR NESTA QUESTAO ?

No mais é isto aí,

Obrigado,

Rossine.

Link to comment
Share on other sites

Olá,

Dêem uma olha no diretorio \fwh\samples\dlls\deplhi32 o exemplo que se encontra lá e é o que preciso. O arquivo .dll é pequeno e executa do jeito que estou precisando, só que feito em fwh+xhabour...

Obrigado,

Rossine.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...