Questions tagged [dlltool]

Dlltool is a GNU binary utility that create the files needed to create dynamic link libraries (DLLs) on systems which understand PE format image files such as Windows.

Dlltool is, according to its website, a GNU binary utility that create the files needed to create dynamic link libraries (DLLs) on systems which understand PE format image files such as Windows. A DLL contains an export table which contains information that the runtime loader needs to resolve references from a referencing program.

The export table is generated by this program by reading in a .def file or scanning the .a and .o files which will be in the DLL. A .o file can contain information in special .drectve sections with export information.

10 questions
6
votes
0 answers

How to catch delay-import dll errors (missing dll or symbol) in MinGW(-w64)?

Using dlltool -y it is possible to create delay-import libraries for existing .dll or .def files. This seems to work just fine up to the point where the dll is needed on systems that do not have the corresponding dll (as expected for a…
Joe
  • 6,497
  • 4
  • 29
  • 55
4
votes
1 answer

MinGW dlltool creates empty file

I'm trying to build static library using MinGW dlltool in order too link it in GCC. What I have is only a DLL file. I created a *.def file and now I'm trying to make *.a file. However I can't force MinGW dlltool to create antyhing, it only makes an…
Rames
  • 918
  • 11
  • 27
4
votes
1 answer

How to resolve the GHC error "Unknown PEi386 section name `.idata$4' " on Windows?

I recently found out that instructions I had written to compile HDBC-postgresql on Windows were no longer working with Haskell Platform 2012.2.0.0. The library builds alright, but when attempting to link the built library, cabal fails with: Loading…
Daniel Trebbien
  • 38,421
  • 18
  • 121
  • 193
3
votes
1 answer

dlltool: Can't create .lib file: libpython27.a: Invalid bfd target

I'm trying to build a 64-bit version of libpython27.a from python27.dll on Windows 7 x64. Following these instructions, I tried: E:\temp>gendef python27.dll * [python27.dll] Found PE+ image E:\temp>dlltool --as-flags=--64 -m i386:x86-64 -k…
Franck Dernoncourt
  • 77,520
  • 72
  • 342
  • 501
2
votes
1 answer

Looking for Information on dlltool --add-indirect (-a)

I am looking for more information on the --add-indirect option for dlltool. When do you use this option? What does it do? Information from binutils help on this option: -a --add-indirect Specifies that when dlltool is creating the exports file…
Jason Nicholson
  • 178
  • 2
  • 13
1
vote
0 answers

dlltool: Fatal error: no compiled in support for x86_64

I'm trying to build a 64-bit version of libpython27.a from python27.dll on Windows 7 x64. Following these instructions, I tried: E:\temp>gendef python27.dll * [python27.dll] Found PE+ image E:\temp>dlltool --as-flags=--64 -m i386:x86-64 -k…
Franck Dernoncourt
  • 77,520
  • 72
  • 342
  • 501
1
vote
1 answer

pexports dlltool Syntax error in def file python27.def:0

I don't manage to build libpythonX.a. dlltool --dllname "python27.dll" --def "python27.def" --output-lib libpython27.a I get the following error dlltool.exe: Syntax error in def file python27.def:0 I have been following the steps on…
1
vote
0 answers

How to get DLL file's function argument and return type?

How can we get DLL file's export function list with argument and return type? I don't know in which language DLL is build. I tried all tools regarding DLL, but no tool is giving specifc list with argument and return type.
Lumia
  • 121
  • 5
  • 13
0
votes
1 answer

Get the delayed-load function binding correctly written into the image executable (dlltool)

I've been studying the delayed-load (delayimp) pipeline as a possible backend for the missing RPATH functionality on Windows, by the following example: #include int __declspec(dllimport) foo(int arg); int main(int argc, char* argv[]) { …
Dmitry Mikushin
  • 1,478
  • 15
  • 16
0
votes
1 answer

Building a dll with a gcc using a library file (.a) converted from import library (.lib)

Step 1. I have an import lib file (main.lib) for my executable (main.exe) which exports some symbols. Those symbols exported using extern "C". Step 2. I also have a source file (extra.cpp) which exports some extra functions. I generate a static…
sny
  • 415
  • 8
  • 21