Note that thread safety still cannot be forcefully enabled if the necessary
macros are not defined.
#endif
#if VMG_MULTIPLICITY && defined(USE_ITHREADS) && defined(dMY_CXT) && defined(MY_CXT) && defined(START_MY_CXT) && defined(MY_CXT_INIT) && (defined(MY_CXT_CLONE) || defined(dMY_CXT_SV))
-# define VMG_THREADSAFE 1
+# ifndef VMG_THREADSAFE
+# define VMG_THREADSAFE 1
+# endif
# ifndef MY_CXT_CLONE
# define MY_CXT_CLONE \
dMY_CXT_SV; \
sv_setuv(my_cxt_sv, PTR2UV(my_cxtp))
# endif
#else
+# undef VMG_THREADSAFE
# define VMG_THREADSAFE 0
# undef dMY_CXT
# define dMY_CXT dNOOP