Solved

COFF to ELF?

Posted on 2001-06-21
6
1,489 Views
Last Modified: 2012-05-04
Hi

Does anyone know of a small utility that I can downlaod that will convert between COFF and ELF object file formats? If so could you please point me there?

Basically I want to convert COFF files output by Microsoft's embedded visual studio to work with GCC's ARM linker

Thanks

Mat
0
Comment
Question by:matth012098
6 Comments
 
LVL 19

Expert Comment

by:DreamMaster
ID: 6213460
You could try using the objcopy program....

But as far as I know it only changes the headers to ELF format....I haven't been able to find any other programs that can convert that way...while there are several that will go the other way...

For more information on objcopy check here:

http://www.delorie.com/gnu/docs/binutils/objcopy.1.html

http://nodevice.com/sections/ManIndex/man1001.html

objcopy is part of the BinUtils package...

Cheers,
Max.
0
 
LVL 22

Expert Comment

by:CJ_S
ID: 6213548
No such product exists, as the task cannot generally be done.

The kernel uses the COFF vs ELF distinction to decide what the
size of certain fundimental types are, and what some structures are.
The code has been compiled assuming the old sizes. Any convertor would,
at a minimum, have to intercept every library call and convert sizes
and re-order structure elements. Doing that for possibly dynamically
generated code is difficult.

Even common objects such as UIDs are different sizes between COFF and ELF.

Regards,
CJ
0
 
LVL 4

Expert Comment

by:prashant_n_mhatre
ID: 6214296
Although "Objcopy" utility claims to be able to convert  ELF and COFF to any other format it knows about, It may not always work perfectly.

But I remember I read about "D-DUMP File Dumper" on Mathworks site (in MatriXx documentation)- they have 'ddump' command which does something similar.

Download this file for more info:
 
http://www.mathworks.com/support/matrixx/knowbase/OnLineDocs/SUPPORT/PDF/DIAB/PPC/UTIL.pdf


0
Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

 
LVL 22

Expert Comment

by:CJ_S
ID: 6230476
Any update?
0
 
LVL 54

Expert Comment

by:nico5038
ID: 7466833

No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:
 - PAQ'd and pts removed
Please leave any comments here within the
next seven days.

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER !

Nic;o)
0
 

Accepted Solution

by:
modulo earned 0 total points
ID: 7506185
Finalized as proposed

modulo

Community Support Moderator
Experts Exchange
0

Featured Post

ScreenConnect 6.0 Free Trial

Explore all the enhancements in one game-changing release, ScreenConnect 6.0, based on partner feedback. New features include a redesigned UI, app configurations and chat acknowledgement to improve customer engagement!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Here we come across an interesting topic of coding guidelines while designing automation test scripts. The scope of this article will not be limited to QTP but to an overall extent of using VB Scripting for automation projects. Introduction Now…
This article will show, step by step, how to integrate R code into a R Sweave document
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …
In this fifth video of the Xpdf series, we discuss and demonstrate the PDFdetach utility, which is able to list and, more importantly, extract attachments that are embedded in PDF files. It does this via a command line interface, making it suitable …

810 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question