Add ifdef the code which utilizes TLS-supported APIs