Part of what --mmcu does is it specifies the which linker script to use.  
Simply including the correct header file doesn't help the linker.  Even other 
compilers (like IAR) use linker scripts which are separate from the #include.

The --mmcu also allows you to use a more generic #include <msp430.h> and the 
precompiler figures out which #include files to use because of the use of this 
flag.

For example, if you have a project with 15 files and you had a MSP430F2416.  If 
you decide that you need to upgrade your processor to a F2417 or 2418, you can 
change it one place, and not modify 15 source files.  That happened where I 
work when we upgraded processors.

adam

-----Original Message-----
From: Yama Ploskonka [mailto:[email protected]]
Sent: Wednesday, November 28, 2012 2:41 PM
Cc: GCC for MSP430 - http://mspgcc.sf.net
Subject: Re: [Mspgcc-users] cannot open linker script file memory.x: No such 
file or directory

:-) got there on my own :-)

just joking. Even if I have to do all the hard work :-)^lots, I do mean it that 
I appreciate y'all help.
In looking for fixes, I saw your name a lot, Peter, that you have been helping 
many.

Thank you, really. and the rest of this clan.

I know my skills are very low, yet you guys do give up so much of your time, 
that it's amazing

BTW, is using *includes* for the file something deprecated and -mmcu the Right 
Way?

thanks again!

Yama

On 11/28/2012 02:02 PM, Peter Bigot wrote:
> The mcu identifier is now the standard name of the MCU; the
> genericized ones are no longer supported.
>
> E.g., if you are building for a Launchpad with an MSP430G2553 on it, use:
>
> msp430-gcc -mmcu=msp430g2553 ...
>
> Peter
>
>
> On Wed, Nov 28, 2012 at 1:57 PM, Yama Ploskonka <[email protected]
> <mailto:[email protected]>> wrote:
>
>     please help!
>
>     when trying to compile, I get
>
>     /usr/lib/gcc/msp430/4.6.3/../../../../msp430/bin/ld: cannot open
>     linker script file memory.x: No such file or directory
>     collect2: ld returned 1 exit status
>
>     - This says to re-emerge msp430mcu....
>     https://github.com/radhermit/msp430-overlay
>     no idea how to do that :-(
>
>     - There was some advice in 2011 by Peter to the effect of "passing
>     the -mmcu flag"
>     
> http://comments.gmane.org/gmane.comp.hardware.texas-instruments.msp430.gcc.user/10095
>     I tried msp430.gcc -mmcu=msp430x16x myfile.c
>     no luck.
>     msp430x16x exists indeed in /etc/msp430/include - I even tried
>     full path in the code
>     #include </etc/msp430/include/msp430x16x.h>
>
>     I'm stuck...
>     might be something obviously simple, I hope...
>
>     Fedora 17, OLPC OS.
>     I reinstalled the OS, ran all the install process again (this time
>     with /yum --nogpgcheck install /in hopes that would "connect"
>     things better), and by now have (apparently) all up to date gcc,
>     binutils, libc and mcu.
>
>
>     
> ------------------------------------------------------------------------------
>     Keep yourself connected to Go Parallel:
>     INSIGHTS What's next for parallel hardware, programming and
>     related areas?
>     Interviews and blogs by thought leaders keep you ahead of the curve.
>     http://goparallel.sourceforge.net
>     _______________________________________________
>     Mspgcc-users mailing list
>     [email protected]
>     <mailto:[email protected]>
>     https://lists.sourceforge.net/lists/listinfo/mspgcc-users
>
>


This email, including any attachments and files transmitted with it, are for 
the sole use of the intended recipient(s) to whom this email is addressed, and 
may contain confidential and/or privileged information. Any unauthorized 
review, use, disclosure or distribution is prohibited. If you are not the 
intended recipient, please be advised that you have received this email in 
error, and please contact the sender by reply email and destroy all copies 
(including all electronic and hard copies) of the original message. Thank you.

------------------------------------------------------------------------------
Keep yourself connected to Go Parallel: 
INSIGHTS What's next for parallel hardware, programming and related areas?
Interviews and blogs by thought leaders keep you ahead of the curve.
http://goparallel.sourceforge.net
_______________________________________________
Mspgcc-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mspgcc-users

Reply via email to