473,405 Members | 2,160 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

is all the .obj or .o file compatible?

Can anyone tell me if all the .obj or .o files are compatible?
Nov 15 '05 #1
12 7280
"Danny Lu" <mi****@verizon.net> wrote in message
news:nr********************************@4ax.com...
Can anyone tell me if all the .obj or .o files are compatible?

They aren't.
Alex
Nov 15 '05 #2
Danny Lu wrote:
Can anyone tell me if all the .obj or .o files are compatible?


No, they aren't.

Brian
Nov 15 '05 #3

Danny Lu wrote:
Can anyone tell me if all the .obj or .o files are compatible?


No way, they are platform dependant plus have a whole lot of other
dependencies. If they were compatiable you would be looking at a
picture similar to compiling on one platform and executing it on
another which is not true.

Nov 15 '05 #4
Danny Lu wrote:
Can anyone tell me if all the .obj or .o files are compatible?


This is not a C question, and therefore not on topic here.

<OT>
No, they are not all compatible. A .o file for Linux is very unlikely to
work on Windows.
</OT>

If you want anything more specific about object files, please ask on a
group dedicated to your system, NOT here.
--
Flash Gordon
Living in interesting times.
Although my email address says spam, it is real and I read it.
Nov 15 '05 #5
In article <11**********************@o13g2000cwo.googlegroups .com>,
Jaspreet <js***********@gmail.com> wrote:
Danny Lu wrote:
Can anyone tell me if all the .obj or .o files are compatible?
No way, they are platform dependant plus have a whole lot of other
dependencies. If they were compatiable you would be looking at a
picture similar to compiling on one platform and executing it on
another which is not true.


What you write is more or less right, but I think it gives a bit
of the wrong impression.

Different operating systems do generally use different object file
formats, sometimes supporting multiple object file formats on one
OS. But the object file format is a different question, really,
then what instruction set a particular platform supports.

Some object file formats support multiple executable portions (for
different instruction sets, or for 32 bit vs 64) within the same object
file; an example of this is Apple's announcement that object files
would share PowerPC and Intel executables.

Unix-like systems tend to adopt one of a small number of object file
formats, so that they do not need to "reinvent the wheel". Some of the
format names are "COFF" (older, use is declining); "ELF" (not as old,
but not fresh); "dwarf" (newer). gcc supports ELF and dwarf formats; I
do not know at the moment if COFF format is being maintained in gcc.

A consequence of this is that object files have a tendency to be
cross-platform compatible (in the sense that the same tool would be
able to extract debugging and link data) -- even when the
instruction set of the binaries is incompatible. The situation
is sort of like the way that most countries agree on standardized
letter and parcel sizes, so a letter can go from one country to
another, even though the -contents- of the letter might be
unintelligable to most people in the destination country.
--
Any sufficiently old bug becomes a feature.
Nov 15 '05 #6
In article <dd**********@canopus.cc.umanitoba.ca>
Walter Roberson <ro******@ibd.nrc-cnrc.gc.ca> wrote:
Unix-like systems tend to adopt one of a small number of object file
formats, so that they do not need to "reinvent the wheel". Some of the
format names are "COFF" (older, use is declining); "ELF" (not as old,
but not fresh); "dwarf" (newer). ...


Off-topic technical note: "dwarf" is not an object file format,
while "ELF" is. (Dwarf and dwarf-2 are debugging data sub-formats
normally appearing within ELF files. The GNU binutils can use
either "stabs" or dwarf within ELF files.)
--
In-Real-Life: Chris Torek, Wind River Systems
Salt Lake City, UT, USA (40°39.22'N, 111°50.29'W) +1 801 277 2603
email: forget about it http://web.torek.net/torek/index.html
Reading email is like searching for food in the garbage, thanks to spammers.
Nov 15 '05 #7
Flash Gordon wrote:
Danny Lu wrote:
Can anyone tell me if all the .obj or .o files are compatible?

This is not a C question, and therefore not on topic here.

I'd be surprised if many people could use C without dealing with one or
the other.
Perhaps the OP meant "all obj and .o files intended for use with C
compilations."
Aside from the various format possibilities, and possibility of
incompatible instruction sets, these files are likely to contain
references to the run-time libraries of a specific compiler and/or a
specific OS version. At the very least, they depend on specific header
files, at a lower level than the compatibility implied in C standard.
Nov 15 '05 #8
Hi danny,

No, .obj and .o files are not comaptible.
though both are relocatable file but are in different format.
the scope of both is same(i.e. compiled source,relocatables) but are
platform dependent.
usually, .o is format of relocatable files or compiled files in
Unix/Linux variant while .obj is compiled ouput for windows based.

so, i hope this clears your doubt.

rgrds,
Munish Nayyar
emanshu "Innovative MInd"

Nov 15 '05 #9
emanshu, Munish Nayyar wrote:
Hi danny,

No, .obj and .o files are not comaptible.
though both are relocatable file but are in different format.
the scope of both is same(i.e. compiled source,relocatables) but are
platform dependent.
usually, .o is format of relocatable files or compiled files in
Unix/Linux variant while .obj is compiled ouput for windows based.

so, i hope this clears your doubt.

This only confuses the issue. .o and .obj files on Windows are usually
interchangeable, aside from the fact that they are usually built against
different headers and libraries, but your explanation seems to
contradict that. .o and .obj files can be renamed either way, without
making a difference to tools which accept both. As others will no
doubt point out again, the C standard says nothing about which name you
give them.
Nov 15 '05 #10
Danny Lu wrote on 15/08/05 :
Can anyone tell me if all the .obj or .o files are compatible?


Not a C-question.

..o and .obj belong to the system and the linker.

--
Emmanuel
The C-FAQ: http://www.eskimo.com/~scs/C-faq/faq.html
The C-library: http://www.dinkumware.com/refxc.html

"Mal nommer les choses c'est ajouter du malheur au
monde." -- Albert Camus.
Nov 15 '05 #11
On Tue, 16 Aug 2005 03:42:33 GMT, in comp.lang.c , Tim Prince
<tp*****@nospamcomputer.org> wrote:
Flash Gordon wrote:
Danny Lu wrote:
Can anyone tell me if all the .obj or .o files are compatible?
This is not a C question, and therefore not on topic here.

I'd be surprised if many people could use C without dealing with one or
the other.


So would I but that doesn't make it ontopic. Consider that you'd be
equally surprised if many people could use C without the letter i, or
a computer of some sort, or electricity, or access to oxygen.

--
Mark McIntyre
CLC FAQ <http://www.eskimo.com/~scs/C-faq/top.html>
CLC readme: <http://www.ungerhu.com/jxh/clc.welcome.txt>

----== Posted via Newsfeeds.Com - Unlimited-Uncensored-Secure Usenet News==----
http://www.newsfeeds.com The #1 Newsgroup Service in the World! 120,000+ Newsgroups
----= East and West-Coast Server Farms - Total Privacy via Encryption =----
Nov 15 '05 #12

In article <Jg****************@newssvr17.news.prodigy.com>, Tim Prince <tp*****@nospamcomputer.org> writes:
Flash Gordon wrote:
Danny Lu wrote:
Can anyone tell me if all the .obj or .o files are compatible?


This is not a C question, and therefore not on topic here.


I'd be surprised if many people could use C without dealing with one or
the other.


I don't believe there's any limit to the number of people who could
use EPM C on the AS/400, which does not use anything called a ".obj
file" or a ".o file", or even anything roughly equivalent to those
things on the platforms where they do appear. (Some C implementations
for the '400 do have something that is in some ways similar to an
"object file", but it doesn't have a name that contains ".obj" or
".o".)

However, the point is moot; it's still OT for comp.lang.c. Few people
"use C" (in the sense of writing C programs) without a keyboard; that
doesn't make questions about keyboards on-topic here.

--
Michael Wojcik mi************@microfocus.com

Unfortunately, as a software professional, tradition requires me to spend New
Years Eve drinking alone, playing video games and sobbing uncontrollably.
-- Peter Johnson
Nov 15 '05 #13

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: KULJEET | last post by:
control file not created at time of installtion of oracle database now how we can create it see alert file Dump file e:\ORacle\admin\new\bdump\newALRT.LOG Tue Sep 09 10:45:53 2003 ORACLE...
1
by: Viktor Popov | last post by:
Hi, I save data from my ASP.NET Application in XML file.How could I delete elements by <id>THIS_VALUE</id>? Could someone help here? Here it is the file: <?xml version="1.0" standalone="yes"?>...
8
by: Sarah | last post by:
I need to access some data on a server. I can access it directly using UNC (i.e. \\ComputerName\ShareName\Path\FileName) or using a mapped network drive resource (S:\Path\FileName). Here is my...
5
by: max | last post by:
Dear all, I did the following analysis to conclude that the following pointer types are not compatible. Please let me know If my analysis and interpretation of the C standard are correct: ...
22
by: fniles | last post by:
I have a .CSV file (comma delimited) that I want to open using OLEDB, but I get the error "External table is not in the expected format." If I save the .CSV file to an .XLS file, I can open the...
9
by: JimmyKoolPantz | last post by:
IDE: Visual Studio 2005 Language: VB.NET Fox Pro Driver Version: 9.0.0.3504 Problem: I currently have a problem altering a DBF file. I do not get any syntax errors when running the program. ...
8
by: paraidy | last post by:
Hi all, as from object i need to read all byte from a file example c: \myphoto.jpg and recreate the file with another name to another directory c:\photo\recreatedphoto.jpg can someone write a...
0
by: fiona | last post by:
Yucca Valley, CA, - October 2007: Catalyst Development Corporation, publisher of SocketTools, SocketWrench and LogicGem, today announced the release of Catalyst File Transfer .NET V5.0. For...
59
by: riva | last post by:
I am developing a compression program. Is there any way to write a data to file in the form of bits, like write bit 0 then bit 1 and then bit 1 and so on ....
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.