News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

Import library to MASM include file converter

Started by Vortex, August 07, 2005, 12:15:30 PM

Previous topic - Next topic

Vortex

Hi friends,

Here is my tool converting MS COFF import libraries to MASM include files.

Tested with import libraries coming with Hutch's masm32 package and PellesC V3.00

The tool accepts wildcards like *.lib

http://vortex.masmcode.com/files/lib2inc10.zip

PBrennick

Hi Erol,
You have certainly been a busy lad creating all these nice tools and we are all better off for it.

You have 'my' thanks,
Paul
The GeneSys Project is available from:
The Repository or My crappy website

GregL


Vortex

Hi friends,

Here is lib2inc V1.1 :

- Fixed bug with duplicate names from user32.libĀ  ( Many thanks Paul informing me about the bug )

The tool is able to extract fuction prototypes from static libraries. If you have the time, could you test the tool with static libs?

http://vortex.masmcode.com/files/lib2inc11.zip

Here is the include file set extracted from Pelles import libraries V 4.00 beta1 :

http://vortex.masmcode.com/files/PellesC_incV11.zip

PBrennick

Hi Erol,
That was quick, I will check it out later today.  Thank you.

Paul
The GeneSys Project is available from:
The Repository or My crappy website

Ghirai

MASM32 Project/RadASM mirror - http://ghirai.com/hutch/mmi.html

Vortex

Here is version V1.11 :

- Fixed bug : lib2inc is now able to extract function names with leading @ :


@DnsGetDomainName PROTO :DWORD
@DnsIsAMailboxType PROTO :DWORD
etc...


http://vortex.masmcode.com/files/lib2inc111.zip

http://vortex.masmcode.com/files/PellesC_inc111.zip

Vortex


Vortex

Here is lib2inc V1.2 translated to Poasm. Now, the tool supports both MASM and POASM

http://vortex.masmcode.com/files/lib2inc12.zip

Include file set extracted from Pelles import libraries 4.00.50

http://vortex.masmcode.com/files/PellesC_inc12.zip

Vortex

Here is lib2inc V1.3 supporting static libraries. To create an include file from a static library :

lib2inc statlib.lib -s

As usually, creating include files from import libraries :

lib2inc importlib.lib

http://vortex.masmcode.com/files/lib2inc13.zip

Vortex

Here is lib2inc V2.0 now supporting Fasm.

Usage    : lib2inc libfile.lib [options]

Switches :

-s : set global calling convention to STDCALL for MASM \ POASM

   MessageBoxA PROTO STDCALL :DWORD,:DWORD,:DWORD,:DWORD

-fd : output EXTERNDEFs for Fasm - direct calls
   lib2inc outputs include files enabling direct function calls

   EXTERNDEF '_MessageBoxA@16',MessageBox

-fi : output EXTERNDEFs for Fasm - indirect calls
     lib2inc outputs include files enabling indirect function calls

   EXTRNDEF '__imp__MessageBoxA@16',MessageBox


If the user doesn't specify any optinonal parameter then the tool emits standard include files for Masm.

http://vortex.masmcode.com/files/lib2inc20.zip

PBrennick

Hi Vortex,
Your tools keep getting better.  Take a rest every now and then.

Paul
The GeneSys Project is available from:
The Repository or My crappy website

Vortex


Vortex

Version 2.1 supporting LzAsm :

Switches :
Quote-s    : set global calling convention to STDCALL for MASM \ POASM

      MessageBoxA PROTO STDCALL :DWORD,:DWORD,:DWORD,:DWORD
      MessageBox equ <MessageBoxA>

-fd    : output EXTERNDEFs for Fasm - direct calls

      lib2inc outputs include files for direct function calls

      EXTERNDEF '_MessageBoxA@16',MessageBox

-fi    : output EXTERNDEFs for Fasm - indirect calls

        lib2inc outputs include files for indirect function calls

      EXTRNDEF '__imp__MessageBoxA@16',MessageBox

-lz      : output LzAsm include files

        lib2inc outputs include files for LzAsm

      PROCDESC MessageBoxA :DWORD,:DWORD,:DWORD,:DWORD
      MessageBox equ <MessageBoxA>

http://vortex.masmcode.com/files/lib2inc21.zip

Mark Jones

"To deny our impulses... foolish; to revel in them, chaos." MCJ 2003.08