Try to fix undefined reference to `__sync_fetch_and_add_8' and

`__sync_val_compare_and_swap_8' for FreeBSD[8|9].
This commit is contained in:
Sergey A. Osokin 2015-05-24 23:47:56 +00:00
parent b6c9d825be
commit 41f5c927c6
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=387364

View file

@ -0,0 +1,14 @@
--- src/stats.h.orig 2015-05-25 02:43:07.925981000 +0300
+++ src/stats.h 2015-05-25 02:43:18.075337000 +0300
@@ -1,6 +1,11 @@
#ifndef STATS_H
#define STATS_H
+#if defined(__FreeBSD__)
+#include <sys/types.h>
+#include <machine/atomic.h>
+#endif /* defined(__FreeBSD__) */
+
#include <stdbool.h>
#include <stdint.h>