Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Building a DLL with ASM

Building a DLL with ASM

Building a DLL with ASM


I want to compile and link a DLL with clean ASM.
How can i put some function to DLL export section?
PUBLIC publics it for local external function only.


Happy programming!))

Replies continue below

Recommended for you

RE: Building a DLL with ASM

You need to have a definition file like this:

LIBRARY mhook2

MouseProc, InstallHook, UninstallHook and TrackMouseLeave are the functions you want to make available to other programs.

Then you link this (assuming you use Hutch's MASM32):

\masm32\bin\Link /SECTION:.bss,S  /DLL /DEF:mhook2.def /SUBSYSTEM:WINDOWS /LIBPATH:\masm32\lib dllfile.obj

where dllfile is the filename of the dll.  It will also create an import library with a lib extension which allows your source files to treat the dll as a lib.

You can get more info at win32asmboard.cjb.net but make sure you try to use the 'search' button at the upper left of each page, if you don't the people there might ask you to do that anyway.  Or try win32asm.cjb.net specifically Iczelion's Tutorial 24 for more info on DLL's.

"Information has a tendency to be free.  Which means someone will always tell you something you don't want to know."

RE: Building a DLL with ASM

Greatfully Thanx!

And one question yet.
Where can i find in internet assemby tuturial i.e full description of directive set?

Happy programming!))

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close