Recently I started a repository that houses a template which may be used to compile STM32F0 projects with a GCC toolchain. There are two code packages from STM that I used when putting this together, the firmware for the Discovery board itself, and the Standard Peripheral Library for the chip family. I read the license agreements in the root of both packages and I think they’re quite fair. Basically the agreement is you can use them for any purposes as long as the code is only being used on STM hardware. Fair enough.
You can image I was quite upset so see a comment from a reader stating that I have a copyright violation with one of the files in the repo. It seems the linker script that is given as an example for Atollic’s TrueSTUDIO has it’s own extremely strict copyright:
** (c)Copyright Atollic AB.
** You may use this file as-is or modify it according to the needs of your
** project. Distribution of this file (unmodified or modified) is not
** permitted. Atollic AB permit registered Atollic TrueSTUDIO(R) users the
** rights to distribute the assembled, compiled & linked contents of this
** file as part of an application binary file, provided that it is built
** using the Atollic TrueSTUDIO(R) toolchain.
First off, I’m in violation just for posting the file in a repository. But read a bit deeper. Any code that is compiled with this using a GCC toolchain also breaks the copyright unless it’s Atollic’s toolchain.
My beef here is that STM is distributing this. Why? Why put something so restrictive into a software library with such an otherwise reasonable license? Surely there are many engineers at STM capable of writing a linker script that they could release under their own license which would work with TrueSTUDIO. And, it would have the added benefit of allowing other GCC-based toolchains a convenient (and legal) method of linking code.
So I’ve completely removed the file from the repository. If you were one of the ten people watching it on github, this had the unintended consequence of dumping your watch request. In the mean time I’m trying to learn how to write my own linker. This guide regarding Cortex-M3 linkers has been a great help. If you have the skills to contribute a working linker script, please issue a pull request or raise an issue over at github.