This is the mail archive of the cygwin mailing list for the Cygwin project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: x86_64-w64-ming32-g++ file not recognized by objdump

----- Original Message ----- From: "Thomas D. Dean"

#include <vector>
#include <string>
using namespace std;
int main() {
 vector<string> vs;

If I compile with g++, I get an executable that works, i.e. runs without
error.  This file is recognized by objdump and cygcheck.

If I compile with x86_64-w64-ming32-g++ -m64 -o t

I presume the 'ming32' is a typo. Is the '-m64' necessary ? What happens if you remove it from the command ?

I can't reproduce the error you get (either with or without '-m64'), though I'm just running mingw in the cmd.exe shell - not under Cygwin.

the resulting executable produces an error message
t.exe: error while loading shared libraries: ?: cannot open shared
object file: no such file or directory.
objdump -p ./t.exe
objdump: ./t.exe: File format not recognized

I think that's to be expected - objdump expects to look at a 32-bit executable.
I get the same error when I run objdump on a 64-bit executable.
x86_64-w64-mingw32-objdump -p ./t.exe


-- Problem reports: FAQ: Documentation: Unsubscribe info:

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]