buildtest: retry failed builds once

On Travis CI often builds fail spuriously.

This PR lets `make buildtest` retry the build once.
Merge pull request #1546 from Kijewski/buildtest-retry

buildtest: retry failed builds once
drivers: updated low-level PWM driver interface
cpu: adjusted pwm driver impl for lpc2387
Merge pull request #1466 from haukepetersen/fix_periph_pwmif

drivers: improvements to the low-level pwm driver interface
board/cpu: added pwm driver for stm32f4discovery
tests: added test for low-level PWM driver
Merge pull request #1467 from haukepetersen/add_stm32f4_pwm

cpu: added pwm driver for the stm32f4
core: moved definition of KERNEL_PID_NULL

kernel_pid_t is defined in kernel_types.h, thus it makes sense to move
the macro for an invalid kernel pid there, too.
net: fix kernel_pid_t checks

KERNEL_PID_NULL is a negative number. If kernel_pid_t variables are
initialized to this value, one have to check for lt/gte 0.
core: renamed KERNEL_PID_NULL to KERNEL_PID_UNDEF

As @authmillenon pointed out the "null" in the old name is somewhat
misleading, since the actual value is -1.
initialize kernel_pid_t correctly
make kernel_pid_t comparisons consistent
ccnl: duplicate variable names

Some variables had multiple definitions, but could be removed or
declared with a smaller scope.
net: changed name of internal variable

To avoid naming conflicts + made variable static and volatile as it
should be.
tests: combine declaration and definition
fixed remaining variables to kernel_pid_t