link with -latomic when needed
Some architecture such as sparc and some flavors of arm needs -latomic to avoid the following build failure:
gthread-posix.c:(.text+0xda8): undefined reference to `__atomic_compare_exchange_4'
Signed-off-by: Fabrice Fontaine fontaine.fabrice@gmail.com