Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[cdt-dev] Suggestions for supporting debug of 64-bit PowerPC C/C++ programs under Eclipse

Recently, I posted bugzilla #148415 about the issue of 64-bit C/C++ programs under Eclipse.

I would like to try to provide a patch for this problem, but could use some suggestions as to where to make the changes and maybe any "gotchas" to be careful of.

I've debugged the CDT and have found that it thinks it's running on a "ppc" arch, but that the executable I'm trying to debug is a "ppc64" binary. One of the tests performed to check for compatibility is to see if the binary's architecture is a prefix of the architecture that Eclipse is running on. In this case, "ppc64" is not a prefix "ppc", so the test fails, and Eclipse finally complains that the CPU is not supported.

I traced through to figure out why the arch was being set to ppc instead of ppc64. This appears to be coming from the command line "-arch" switch. I tried setting the -arch switch to ppc64 as an experiment, but that caused Eclipse to crash during startup because the architecture disagreed with what the JVM was telling it. So then I tried getting Eclipse to use a 64-bit JVM, but then Eclipse crashed during start-up because it needs a 64-bit version of libswt-pi-gtk-3232.so.

Sorry for the verbosity here, but here are a couple of questions:

1) Are there other architectures where a 32-bit Eclipse is used to debug a 64-bit executable. AMD64 comes to mind... does that work? Are there known problem with dealing with 64-bit variables, addresses, etc. within the 32-bit Eclipse?

2) If the answer to the question above is, "Yes, it works on other platforms with no (or few) problems.", do you have a suggested change to the CDT to support this debug configuration?


Back to the top