The MASM Forum Archive 2004 to 2012

General Forums => The Campus => Topic started by: remus2k on October 31, 2006, 02:52:24 PM

Title: help with dll to lib in masm
Post by: remus2k on October 31, 2006, 02:52:24 PM
hi leutz

i search help with convert BladeEnc.dll and bladedll.h from BEnc-0942-Win-i586-dll
packed in masm32

can your help me

thx in forward
Title: Re: help with dll to lib in masm
Post by: Vortex on October 31, 2006, 06:10:00 PM
If it's possible, can you post the dll and the header (.h) file? Maybe, we can help you.
Title: Re: help with dll to lib in masm
Post by: remus2k on October 31, 2006, 06:39:45 PM
hi vortex



[attachment deleted by admin]
Title: Re: help with dll to lib in masm
Post by: MichaelW on October 31, 2006, 06:44:54 PM
The archive includes what appears to be an import library, and if it is then all you need to do is convert the header file.

http://www2.arnes.si/~mmilut/BladeEnc.html

Title: Re: help with dll to lib in masm
Post by: remus2k on October 31, 2006, 06:50:12 PM
hi MichaelW

have your a tool to convert the header file??
Title: Re: help with dll to lib in masm
Post by: TNick on October 31, 2006, 07:05:37 PM
http://www.masm32.com/board/index.php?topic=5428.0
Title: Re: help with dll to lib in masm
Post by: remus2k on October 31, 2006, 07:14:14 PM
thx for your help :bg :cheekygreen:
Title: Re: help with dll to lib in masm
Post by: TNick on October 31, 2006, 07:32:49 PM
 :U
Wellcome aboard!!
You should thanks to ToutEnMasm for that tool. :bg
Nick
Title: Re: help with dll to lib in masm
Post by: remus2k on October 31, 2006, 07:42:20 PM
i have a problem with compiling there appears a errorreport

blank_dlg.obj : error LNK2001: unresolved external symbol _beInitStream@16
blank_dlg.exe : fatal error LNK1120: 1 unresolved externals
Title: Re: help with dll to lib in masm
Post by: TNick on October 31, 2006, 08:15:33 PM
Do you have a
INCLUDELIB BEnc-0942-Win-i586-dl.lib
(or whatevername have your lib) statement  in your code?
Title: Re: help with dll to lib in masm
Post by: remus2k on October 31, 2006, 08:20:07 PM
.586
.model flat, stdcall  ;32 bit memory model
option casemap :none  ;case sensitive

Title: Re: help with dll to lib in masm
Post by: TNick on October 31, 2006, 08:25:12 PM
yes, but did you link the lib, too?
.586
.model flat, stdcall  ;32 bit memory model
option casemap :none  ;case sensitive
INCLUDELIB BEnc-0942-Win-i586-dl.lib ; see what name has your lib and change it inhere
Title: Re: help with dll to lib in masm
Post by: remus2k on October 31, 2006, 08:29:42 PM
my lib name is BladeEnc.lib from BEnc-0942-Win-i586-dll.zip packed
Title: Re: help with dll to lib in masm
Post by: TNick on October 31, 2006, 08:35:46 PM
:) :) :)
Well, then, try to add after

.586
.model flat, stdcall  ;32 bit memory model
option casemap :none  ;case sensitive

this line:
INCLUDELIB [Path\]BladeEnc.lib

where Path is the path to your BladeEnc.lib
Title: Re: help with dll to lib in masm
Post by: remus2k on October 31, 2006, 08:36:40 PM
here is my source

[attachment deleted by admin]
Title: Re: help with dll to lib in masm
Post by: TNick on October 31, 2006, 08:52:20 PM
Yes, I see. Well, I can't say what's the problem Sorry!
Title: Re: help with dll to lib in masm
Post by: remus2k on October 31, 2006, 08:58:13 PM
must the dll convert in the masm32 libary???
Title: Re: help with dll to lib in masm
Post by: MichaelW on November 01, 2006, 12:29:36 AM
This is a quick test of the interface and the import libarary.

; «««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««
    include \masm32\include\masm32rt.inc

    includelib BladeEnc.lib

    BE_MAX_HOMEPAGE equ 256

    BE_VERSION STRUCT
      byDLLMajorVersion   BYTE ?
      byDLLMinorVersion   BYTE ?
      byMajorVersion      BYTE ?
      byMinorVersion      BYTE ?
      byDay               BYTE ?
      byMonth             BYTE ?
      wYear               WORD ?
      zHomepage           BYTE BE_MAX_HOMEPAGE + 1 dup (?)
    BE_VERSION ENDS

    beVersion PROTO C :DWORD
   
; «««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««
    .data
      bev BE_VERSION <>
    .code
; «««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««
start:
; «««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««
    invoke beVersion, ADDR bev
   
    print uhex$(eax),13,10
    print uhex$(ADDR bev),13,10
    print uhex$(ADDR bev.zHomepage),13,10

    print ADDR bev.zHomepage,13,10

    inkey "Press any key to exit..."
    exit
; «««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««
end start


00403008
00403000
00403008
http://bladeenc.mp3.no
Press any key to exit...
Title: Re: help with dll to lib in masm
Post by: remus2k on November 01, 2006, 04:10:54 PM
thx  :bg