[En-Nut-Discussion] Need help on Makefiles

Thiago A. Corrêa thiago.correa at gmail.com
Wed Sep 9 15:38:39 CEST 2009


Hi,

On Wed, Sep 9, 2009 at 5:33 AM, Harald Kipp<harald.kipp at egnite.de> wrote:
> Ulrich Prinz wrote:
>> I did a quick integration of openocd into the Makefiles to use "make
>> burn" with that tool and an openocd-usb dongle too.
>>
>> But my script is fixed to a CPU and the user has to modify script if he
>> as another CPU than my SAM7X256.
>>
>> How can I find out the CPU type in the Makefile so I can select the
>> right script?
>
> No chance. By accident avrdude still supports the same symbolic names,
> that are used by the compiler for the target CPU. Although this is not
> documented. Thus, in most cases this works on the AVR platform out of
> the box.
>

Well, you could always make some if's in the Makeburn to translate the
different names.

I assume you want to create a Makeburn.openocd right?
Then you could translate the MCU variable to some OPENOCD_MCU using ifs.

Kind Regards,
   Thiago A. Correa



More information about the En-Nut-Discussion mailing list