make: don't overwrite LINKFLAGS

Fix the boards' Makefiles were a potentially set LINKFLAGS variable were
overwritten.
tests: use correct PID for main thread

Since PIDs are not beginning at 0 any more, this test was failing.
dist/tools: add check for extern "C" declaration
Travis: add externc check
boards + cpu: atmega2560: fix non-existent GPIO
drivers/periph/gpio: fix #ifdef instead of #if
Merge pull request #1832 from OlegHahm/test_thread_msg_seq_fixup

tests: use correct PID for main thread
Merge pull request #1789 from LudwigOrtmann/externc_check

CI: extern "C" check
Merge pull request #1831 from LudwigOrtmann/periph_gpio_ifdef

drivers/periph/gpio: fix #ifdef instead of #if
Merge pull request #1833 from OlegHahm/dont_overwrite_linkflags

make: don't overwrite LINKFLAGS