MINOR: initcall: use initcalls for most post_{check,deinit} and per_thread*

Most calls to hap_register_post_check(), hap_register_post_deinit(),
hap_register_per_thread_init(), hap_register_per_thread_deinit() can
be done using initcalls and will not require a constructor anymore.
Let's create a set of simplified macros for this, called respectively
REGISTER_POST_CHECK, REGISTER_POST_DEINIT, REGISTER_PER_THREAD_INIT,
and REGISTER_PER_THREAD_DEINIT.

Some files were not modified because they wouldn't benefit from this
or because they conditionally register (e.g. the pollers).
diff --git a/src/51d.c b/src/51d.c
index d709ec0..2a97867 100644
--- a/src/51d.c
+++ b/src/51d.c
@@ -687,11 +687,6 @@
 
 INITCALL1(STG_REGISTER, sample_register_convs, &conv_kws);
 
-__attribute__((constructor))
-static void __51d_init(void)
-{
-	hap_register_post_check(init_51degrees);
-	hap_register_post_deinit(deinit_51degrees);
-}
-
+REGISTER_POST_CHECK(init_51degrees);
+REGISTER_POST_DEINIT(deinit_51degrees);
 REGISTER_BUILD_OPTS("Built with 51Degrees support.");