CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

.o Object file creation

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
nolfese



Joined: 11 Apr 2009
Posts: 2

View user's profile Send private message

.o Object file creation
PostPosted: Sun Apr 12, 2009 1:22 pm     Reply with quote

I've never really bothered about what the linker does, I've just written code in CCS or Hi-Tech C and then blown the hex file into the PICs. I now fine myself in the position of wanting to combine pre-compiled library files using the linker. I'm pretty sure that this should be possible using the linker command line facility like this:

mplink 18f452.lkr main.o funct.o math.lib /m main.map /o main.out

The trouble is that when I compile I don't see any .o files being generated. The .hex file is there and works fine. how can there not be a .o file as well?

Thanks for any help you can offer.
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Sun Apr 12, 2009 1:26 pm     Reply with quote

See this post:
http://www.ccsinfo.com/forum/viewtopic.php?t=38254&start=15
nolfese



Joined: 11 Apr 2009
Posts: 2

View user's profile Send private message

PostPosted: Tue Apr 14, 2009 1:59 am     Reply with quote

PCM programmer wrote:
See this post:
http://www.ccsinfo.com/forum/viewtopic.php?t=38254&start=15


Hi PCM Programmer,
You had me going for the moment there, I thought we on track for a winner. I've now tried building all in the PCW IDE V4.084 but still no .o file. The Options/Project Options/Output Files dialog lists 8 bit hex as the object file and yet it refuses to write it. How weird is that?
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Tue Apr 14, 2009 1:21 pm     Reply with quote

I don't have the CCS IDE so I can't duplicate your problem, but there is
a screenshot in the CCS manual that shows a tickbox for "Multiple
compilation units". Make sure that tickbox is selected.
BoydNielsen



Joined: 20 Aug 2006
Posts: 12

View user's profile Send private message

.o Object file creation
PostPosted: Mon Aug 03, 2009 3:08 pm     Reply with quote

I too would like to create some separate .o "object files" (want to put some of those special drivers into a library). I know that in MPLAB it can be done with the C18 and C30 compilers by navigating to Project > Build Option... > Project > MPASM/C17/C18 Suite tab [or ASM30/C30 Suite tab] and selecting "Build library target". However, I can't figure out how to do it with the CCS compiler (either in the CCS IDE or the MPLAB IDE).

Within the CCS IDE, when I navigate to Options > Project Options and then select Multiple Compilation Units and Link Separately, all I get is one .o file (the first compilation unit).

Any ideas as to what I am doing wrong?

Boyd
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group