Jump to content

Generating DEF file for API wrapper


Recommended Posts

Posted (edited)

Anyone know any script/ batch file /program that can convert list of API into forwarded API def file for link.exe?

For example if I feed kernel32.dll it will create a def file for kernel32 wrapper like this 

Firstfunction = Kernel32.Firstfunction#1

We can do it easily for C++ but I need for MASM

 

Edited by Dibya

Posted

DykZtKx.png

 

You need first to add the path of MinGW's bin directory to your PATH env variable.
 

D2ob28r.png


Then it's trivial :

gcc -o tiny_impdef.exe tiny_impdef.c

Then to generate a def file :

tiny_impdef.exe regex2.dll

Then you get the generated file :

l3Oyq2L.png

 

 

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...