Jump to content
Sign in to follow this  
Ian Harris

Enhancement - Recompile .obj Files

Recommended Posts

.obj file recompile


When there's a .obj that exists for a given .c file, if the .obj is for the wrong target, just recomile the .c instead of aborting.


Global variables


It would be great for the Code panel to show where exactly the global variables are coming from - even just narrowing it down to a .c file would be a great help.




Compiler generates a goto _startup, which then does a goto main. All fine except when you compile with -Su so you don't initialise global variables, or there are no global variables, in which case the first goto should just be goto main. Hey, every byte counts :-)


Routine locations


It's really handy in other compilers to be able to do something like


#pragma org 0x6500


void my_routine() {



To be able to place subroutines at particular locations in memory. Interrupt already does this implicitly. It would greatly simplify some problems and aleviate having to hand-code using #pragma data, which is the only other way to get code to sit at particular locations.


asm goto


doesn't seem to work. Had to use asm data.




Sometimes the compiler exits with error code 1 when you build, says its successful, but then doesn't link. You have to do a proper "compile" then "link" and it works fine, no code changes. Must be some problem examining .obj files perhaps? Doesn't happen all the time, just some times. Compile then link always fixes it.


Target directories


You can use -d dir_name on the linker command line - previously this would actually create the directory if it's not there, and even dump everything in it. In 6.87, this crashes the linker. In either case, the problem is really that the ide says the build has failed because it can't find the .hex file in the project directory when it should really be looking in the -d directory.


Access params from code


It would be really, really handy if the command line parameters such as -rb were available in code, eg,


#pragma PARAM_RB 32230


kind regards


Edited by Ian Harris

Share this post

Link to post
Share on other sites

Join the conversation

You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

  • Create New...