Disable atomic refcounts with no-threads
authorJ.W. Jagersma <jwjagersma@gmail.com>
Tue, 22 Nov 2022 18:20:53 +0000 (19:20 +0100)
committerTomas Mraz <tomas@openssl.org>
Fri, 25 Nov 2022 09:29:44 +0000 (10:29 +0100)
commitb484c6268ce38ccbc1bf5ee95bbd36f76fba994f
treef281496c9f0c08be19c47be98346a0450375a5bf
parenta2ede0396addd13f7fe9a629b450a14892152a83
Disable atomic refcounts with no-threads

This is needed for building with '-march=i386 no-threads', on platforms
where libatomic is not available (djgpp, specifically).  The
implementation now falls back to 'CRYPTO_atomic_add()', which performs
plain lock-free addition in a 'no-threads' build.

Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Paul Dale <pauli@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/19751)
include/internal/refcount.h