How to setup free C compiler and assembler SH2 - EvolutionM - Mitsubishi Lancer and Lancer Evolution Community



How to setup free C compiler and assembler SH2

Reply
 
 
 
Thread Tools Search this Thread
Old Apr 4, 2017, 06:13 AM   #1
Evolved Member
Thread Starter
 
Join Date: May 2006
Location: UK
Posts: 2,399
Thanks: 0
Thanked 0 Times in 0 Posts

Drives: R35 GTR

How to setup free C compiler and assembler SH2

Been a while since I've been here, Evo long sold but never forgotten. Hope you're all well and happy.

Thought I would post a few comments and screenshots linking to a few hours playing with setting up HEW for SH2 as another group I am in had written some assembly and didn't seem to know how to build it, yet had an interesting sounding project for the Evo 9.

Back in the day I used KPIT Cummins GNU tools, and tend to prefer command line, but now it seems to be HEW with an IDE that is the free tool.

Don't PM me as I don't visit the forum often.

Download: https://www.renesas.com/en-eu/produc...html#downloads

Follow the pictures in order to see the setup steps I used to get C to compile and then load up in IDA.

Feel free to mangle, use, criticise and enjoy as you wish. No warranty deserved, use at your own risk, blah blah.

Second post to follow to show how to get asm to assemble.
Attached Thumbnails
How to setup free C compiler and assembler SH2-1.jpg   How to setup free C compiler and assembler SH2-2.jpg   How to setup free C compiler and assembler SH2-3.jpg   How to setup free C compiler and assembler SH2-4.jpg   How to setup free C compiler and assembler SH2-5.jpg  

How to setup free C compiler and assembler SH2-6.jpg   How to setup free C compiler and assembler SH2-7.jpg   How to setup free C compiler and assembler SH2-8.jpg   How to setup free C compiler and assembler SH2-9.jpg  

Last edited by jcsbanks; Apr 4, 2017 at 06:22 AM.
Offline
 
Reply With Quote
Old Apr 4, 2017, 06:13 AM   #2
Evolved Member
Thread Starter
 
Join Date: May 2006
Location: UK
Posts: 2,399
Thanks: 0
Thanked 0 Times in 0 Posts

Drives: R35 GTR

How to build assembly language and fix linker errors, define section. The code is relocatable until linked, so arbitrary 0 for address is OK if you are patching code from obj or other files.

-noprelink -nomessage -list="$(CONFIGDIR)\$(PROJECTNAME).map" -nooptimize -start=P/00 -nologo -output="$(CONFIGDIR)\$(PROJECTNAME).abs" -end -input="$(CONFIGDIR)\$(PROJECTNAME).abs" -form=stype -output="$(CONFIGDIR)\$(PROJECTNAME).mot" -exit

This goes into the highlighted box in 13.jpg.
Attached Thumbnails
How to setup free C compiler and assembler SH2-10.jpg   How to setup free C compiler and assembler SH2-11.jpg   How to setup free C compiler and assembler SH2-12.jpg   How to setup free C compiler and assembler SH2-13.jpg  
Offline
 
Reply With Quote
Old Apr 16, 2017, 09:22 AM   #3
Evolved Member
 
Join Date: Jan 2006
Location: Oxfordshire
Posts: 951
Thanks: 0
Thanked 0 Times in 0 Posts

Drives: Evo7 GSR

Good to see you back if only for a fleeting time. Will check this out, hopefully it'll make sense now I have a little more coding experience.
Offline
 
Reply With Quote
 
 
Reply

Related Topics
Thread Thread Starter Forum Replies Last Post
Write new code? Deepnine EcuFlash 58 Mar 9, 2017 12:15 AM
ROM disassembly as raw text file richardjh Ecuflash 239 Dec 31, 2016 09:07 AM
ETS Tubular Exhaust Manifold Install Guide Hiboost Evo X How Tos / Installations 16 Feb 27, 2016 03:33 PM
Stay Planted -- Tried and Tested Suspension Parts // DSG Performance DSG Performance EvoX 'For Sale' Suspension / Brakes / Handling 11 Nov 27, 2015 09:28 AM
How to: Front Subframe WL Roll Center Kit & Steering Rack bushings & FSB sway bar fireroasted Evo Tires, Wheels, Brakes & Suspension - Sponsored by The Tire Rack 3 Jan 4, 2013 08:23 PM


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off



All times are GMT -7. The time now is 07:00 PM.


 
  • Ask a Question
    Get answers from community experts
Question Title:
Description:
Your question will be posted in: