[En-Nut-Discussion] Added "license checks" to the Makefiles

Ole Reinhardt ole.reinhardt at embedded-it.de
Sat Aug 3 17:07:39 CEST 2013


Hi all,

You remember the license issues with STM32? Me too :-) You that if you
do not accept the license in the Configurator parts of Nut/OS may not be
build.

I run into this problem myself several times and was annoyed that there
is no warning...

I tried to solve this by adding some new functions to the Makefiles
which can be used to check, if these licenses have been accepted on this
particular platform.


Therefor I implemented a new make target "check-licenses", which can be
used to add checks, if all configuration options are properly set to
completely compile the Nut/OS code.

Currently it us used by the STM32 platform, to check wether the
propriatory STM licences are accepted in the configurator. If not, a
warning is printed out during compilation to notify the user about
possible build errors caused by missing functions, that are only
available if these licenses are accepted.

(on Linux) this warning is printed out to stderr and will also show up
in the configurator log. On windows I need help (for testing) from other
developers.


To implement this feature, a few changes / additions to the configurator
scripts and the Makefiles were needed:

Configurator:

The Configurator options that shall be checked need to write an
evironment variable into Nutconf.mk, same is done when selecting STM32
as architecture.

Makefiles:

A new default target was created in Makevars.all (as it needs to stay on
top of the evaluated make targets) which is called "default".
Target "default" depends on "check-licenses all" which causes the
license check to be run onece before the compilation process starts.

The check-license target now prints out a message, which is created as
a variable in Makerules.licenses.


Could you please test these changes on your development system?
Especially I don't have a Windows system to test the makefiles on. I'm
quite shure that they will work on windows as well, but output may
contain control characters on windows.

Please report or fix any issues :-)

Best regards,

Ole Reinhardt


-- 
kernel concepts GmbH            Tel: +49-271-771091-14
Sieghuetter Hauptweg 48         Mob: +49-177-7420433
D-57072 Siegen
http://www.embedded-it.de
http://www.kernelconcepts.de


More information about the En-Nut-Discussion mailing list