Allow calls to ct:pal and ct:print even if CT is not running

Also make sure calls to ct:log and ct:pal don't cause crash
if test_server is not running (could happen during startup or
shutdown of CT).

OTP-11176
Add test

OTP-11176
Make the CT logger print to stdout if test_server is not running

OTP-11176
Fix compile error on ARM and GCC < 4.1.0

Since b29ecbd (OTP-10418, R15B03) Erlang does not compile anymore with
old versions of GCC that do not have atomic ops builtins on platforms
where there is no native ethread implementation (e.g. ARM):

In file included from ../include/internal/gcc/ethread.h:29,
                 from ../include/internal/ethread.h:354,
                 from beam/erl_threads.h:264,
                 from beam/erl_smp.h:27,
                 from beam/sys.h:413,
                 from hipe/hipe_mkliterals.c:29:
../include/internal/gcc/ethr_membar.h:49:4: error: #error "No __sync_val_compare_and_swap"

This patch adds a header guard in "gcc/ethread.h", as is present in
"libatomic_ops/ethread.h".
xmerl: fix typos
Merge remote branch 'origin/peppe/common_test/ct_log_updates' into maint

* origin/peppe/common_test/ct_log_updates:
  Make the CT logger print to stdout if test_server is not running
  Add test
  Allow calls to ct:pal and ct:print even if CT is not running

OTP-11176
Merge branch 'fredrik/xmerl/fix_doc/OTP-11224' into maint

* fredrik/xmerl/fix_doc/OTP-11224:
  xmerl: fix typos
Merge branch 'weisslj/fix-gcc40-arm-compile-error/OTP-11214' into maint

* weisslj/fix-gcc40-arm-compile-error/OTP-11214:
  Fix compile error on ARM and GCC < 4.1.0