WinAsm Studio, The Assembly IDE - Free Downloads, Source Code
Sponsors
Articles
Programming Quick Start
32-bit Assembler is Easy
Porting Iczelion tutorials
What is FASM
What is FASM G
Hard Drive Recovery
Wiring your own LAN
Personal menu
Welcome Guest
User:
Pass:
Register!
Resend Validation Email
 
Forum
Pages (2) [1] 2   ( Go to first unread post )

MS COFF import library to MASM include file, MASM tool

Vortex
Quote Post


Extremely Active Member
******

Group: Moderators
Posts: 140
Member No.: 8
Joined: 13-May 04


Sponsored Links
Hi friends,

Here is my tool converting MS COFF import libraries to MASM include files , lib2inc V1.11

http://vortex.masmcode.com/files/lib2inc111.zip
PMEmail PosterUsers Website
Top
shoorick
Quote Post


Extremely Active Member
******

Group: Admins
Posts: 2342
Member No.: 160
Joined: 22-June 04


Nice tool! Thanks!
PMEmail PosterUsers Website
Top
Vortex
Quote Post


Extremely Active Member
******

Group: Moderators
Posts: 140
Member No.: 8
Joined: 13-May 04


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>
PMEmail PosterUsers Website
Top
samael
Quote Post


Typo-lord
******

Group: Moderators
Posts: 404
Member No.: 5187
Joined: 10-June 07


Vortex, your utilities are very useful indeed!
Thanks for the time you put in developing them!

Now, since you seem to be one of the gods of the COFF/PE format, i might as well drop the bomb and ask you some questions (by all means, do not consider them as requests, i just want to know the answers from someone who knows his stuff ):

1) I'm sure you know/heard of dll2lib from binary-soft. Just for the record, that product converts a dll library to a static library, which one can then statically link to a project. My question: Is there a freeware analogous to that tool? Or any kind of alternative? I haven't found anything similar on the net...

2) Are you aware of a utility that combines multiple COFF files to a single one (COFF binder/combiner)? If not, is the COFF format subjectible to such kind of manipulation? (I mean, would it be possible for someone to actually code something such as a COFF binder?)

3) Finally, does the COFF format allow the conversion: COFF to Static Library? Would such thing be possible/feasible to be done with a tool? What are the limitations (if any) to an attempt to coding such tool?

Sorry if i ask something profound, i'm nowhere near you as it comes to the COFF format / programming in general...
In other words, be gentle in your reply... ;)

Again, thanks for reading this, and for sharing you tools / knowledge!
PM
Top
Vortex
Quote Post


Extremely Active Member
******

Group: Moderators
Posts: 140
Member No.: 8
Joined: 13-May 04


Hi Samael,

Please accept my apologies for replying late.

Thanks for your kind words.

1) I have a small project to run embedded EXEs and DLLs from memory. This method allows you to use DLLs like static libraries :

Loading and running EXEs and DLLs from memory :

http://www.masm32.com/board/index.php?topic=3150.0

2) I don't know if there is a tool to combine multiple MS COFF object modules. Studying the MS COFF object file format specification, you can modify the object modules but coding a tool to merge object files is not an easy task.

3) Using Masm's lib.exe or Pelle's Polib.exe, you can create static libraries from MS COFF object modules. It's easy :

CODE
lib /OUT:library.lib objectfile1.obj objectfile2.obj etc.


Please let me know if you have other questions.
PMEmail PosterUsers Website
Top
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

Topic Options Pages (2) [1] 2  Reply to this topicStart new topicStart Poll

 

Sponsors
Computer Science

Internet
C/C++
Hardware & PC maintenance

HiEditor

General Discussions
Suggestions/Bug Reports
WinAsm Studio

General Discussions
Suggestions/Bug Reports
WinAsm Studio FAQ
Multilingual User Interface
Add-Ins
Assembly Programming

Main
Newbies
Projects
Custom Controls
Snippets
Announcements & Rules

Announcements

General

Online Degrees - Distance Learning
The Heap
Russian
Google