#include <stdio.h>
#include <import/lru.h>
-#include <import/xxhash.h>
#include <haproxy/api.h>
#include <haproxy/arg.h>
#include <haproxy/buf-t.h>
#include <haproxy/sample.h>
#include <haproxy/thread.h>
#include <haproxy/tools.h>
+#include <haproxy/xxhash.h>
#include <51Degrees.h>
struct _51d_property_names {
#include <stdlib.h>
#include <stdarg.h>
#include <arpa/inet.h>
-#include <import/xxhash.h>
+
+#include <haproxy/xxhash.h>
__attribute__((noreturn)) void die(int code, const char *format, ...)
{
#ifndef _HAPROXY_ACTIVITY_H
#define _HAPROXY_ACTIVITY_H
-#include <import/xxhash.h>
#include <haproxy/activity-t.h>
#include <haproxy/api.h>
#include <haproxy/freq_ctr.h>
#include <haproxy/time.h>
+#include <haproxy/xxhash.h>
extern unsigned int profiling;
extern unsigned long task_profiling_mask;
#include <import/ebmbtree.h>
#include <import/ist.h>
-#include <import/xxhash.h>
#include <haproxy/api-t.h>
#include <haproxy/buf-t.h>
#include <haproxy/port_range-t.h>
#include <haproxy/protocol-t.h>
#include <haproxy/thread-t.h>
+#include <haproxy/xxhash.h>
/* referenced below */
struct connection;
#define MAX_POLLERS 10
#endif
-/* Make all xxhash functions inline, with implementations being directly
- * included within xxhash.h.
- */
-#ifndef XXH_INLINE_ALL
-#define XXH_INLINE_ALL
-#endif
-
/* system sysfs directory */
#define NUMA_DETECT_SYSTEM_SYSFS_PATH "/sys/devices/system"
--- /dev/null
+/*
+ * Copyright (C) 2020 Dragan Dosen <ddosen@haproxy.com>
+ * Copyright (C) 2021 Tim Duesterhus <tim@bastelstu.be>
+ *
+ * BSD 2-Clause License (https://www.opensource.org/licenses/bsd-license.php)
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above
+ * copyright notice, this list of conditions and the following disclaimer
+ * in the documentation and/or other materials provided with the
+ * distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#ifndef _HAPROXY_XXHASH_H
+#define _HAPROXY_XXHASH_H
+
+/* Make all xxhash functions inline, with implementations being directly
+ * included within xxhash.h.
+ */
+#ifndef XXH_INLINE_ALL
+#define XXH_INLINE_ALL
+#else
+#error "XXH_INLINE_ALL is already defined."
+#endif
+
+#include <import/xxhash.h>
+
+#endif
extern "C" {
#endif
-#include <haproxy/defaults.h>
-
/* ****************************
* INLINE mode
******************************/
#include <import/ebsttree.h>
#include <import/lru.h>
-#include <import/xxhash.h>
#include <haproxy/api.h>
#include <haproxy/global.h>
#include <haproxy/regex.h>
#include <haproxy/sample.h>
#include <haproxy/tools.h>
+#include <haproxy/xxhash.h>
const char *const pat_match_names[PAT_MATCH_NUM] = {
#include <import/mjson.h>
#include <import/sha1.h>
-#include <import/xxhash.h>
#include <haproxy/api.h>
#include <haproxy/arg.h>
#include <haproxy/tools.h>
#include <haproxy/uri_auth-t.h>
#include <haproxy/vars.h>
+#include <haproxy/xxhash.h>
/* sample type names */
const char *smp_to_type[SMP_TYPES] = {
#include <ctype.h>
#include <errno.h>
-#include <import/xxhash.h>
-
#include <haproxy/api.h>
#include <haproxy/applet-t.h>
#include <haproxy/backend.h>
#include <haproxy/tcpcheck.h>
#include <haproxy/time.h>
#include <haproxy/tools.h>
+#include <haproxy/xxhash.h>
static void srv_update_status(struct server *s);
#include <errno.h>
#include <import/eb64tree.h>
-#include <import/xxhash.h>
#include <import/ebistree.h>
#include <haproxy/api.h>
#include <haproxy/server.h>
#include <haproxy/ssl_sock.h>
#include <haproxy/tools.h>
+#include <haproxy/xxhash.h>
/* Update a server state using the parameters available in the params list.
#include <import/ebpttree.h>
#include <import/ebsttree.h>
#include <import/lru.h>
-#include <import/xxhash.h>
#include <haproxy/api.h>
#include <haproxy/arg.h>
#include <haproxy/tools.h>
#include <haproxy/vars.h>
#include <haproxy/xprt_quic.h>
+#include <haproxy/xxhash.h>
/* ***** READ THIS before adding code here! *****