0002-atomic_compare_exchange.patch 1012 B

123456789101112131415161718192021222324252627
  1. Rename __atomic_compare_exchange to not clash with gcc built-in
  2. Downloaded from
  3. https://src.fedoraproject.org/cgit/rpms/libdb.git/commit/?id=d6841b3b46a51db98c162347211a5a64d154ea37
  4. Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
  5. --- db-5.3.28/src/dbinc/atomic.h.old 2018-05-23 09:20:04.216914922 +0200
  6. +++ db-5.3.28/src/dbinc/atomic.h 2018-05-23 09:20:49.510057897 +0200
  7. @@ -144,7 +144,7 @@
  8. #define atomic_inc(env, p) __atomic_inc(p)
  9. #define atomic_dec(env, p) __atomic_dec(p)
  10. #define atomic_compare_exchange(env, p, o, n) \
  11. - __atomic_compare_exchange((p), (o), (n))
  12. + __db_atomic_compare_exchange((p), (o), (n))
  13. static inline int __atomic_inc(db_atomic_t *p)
  14. {
  15. int temp;
  16. @@ -176,7 +176,7 @@
  17. * http://gcc.gnu.org/onlinedocs/gcc-4.1.0/gcc/Atomic-Builtins.html
  18. * which configure could be changed to use.
  19. */
  20. -static inline int __atomic_compare_exchange(
  21. +static inline int __db_atomic_compare_exchange(
  22. db_atomic_t *p, atomic_value_t oldval, atomic_value_t newval)
  23. {
  24. atomic_value_t was;