Development discussion of WireGuard
 help / color / Atom feed
* RHEL 7.8, Kernel 3.10: ratelimiter.c:25:1: error: unknown type name 'hsiphash_key_t'
@ 2020-04-11 18:21 cwei
  2020-04-14  9:06 ` Jason
  0 siblings, 1 reply; 2+ messages in thread
From: cwei @ 2020-04-11 18:21 UTC (permalink / raw)


Hello Dear Mailinglist,

with RHEL 7.8, kernel 3.10 and current Wireguard 1.0.20191226 make
throws the obove error:

# rpm -qa "wireguard*"
wireguard-tools-1.0.20191226-1.el7.x86_64
wireguard-dkms-1.0.20200401-1.el7.noarch

# cat /etc/oracle-release
Oracle Linux Server release 7.8

# uname -a
Linux xxxxxxxx 3.10.0-1127.el7.x86_64 #1 SMP Wed Apr 1 10:20:09 PDT 2020
x86_64 x86_64 x86_64 GNU/Linux

# make
  CC [M]  /var/lib/dkms/wireguard/1.0.20200401/build/main.o
  CC [M]  /var/lib/dkms/wireguard/1.0.20200401/build/noise.o
  CC [M]  /var/lib/dkms/wireguard/1.0.20200401/build/device.o
  CC [M]  /var/lib/dkms/wireguard/1.0.20200401/build/peer.o
  CC [M]  /var/lib/dkms/wireguard/1.0.20200401/build/timers.o
  CC [M]  /var/lib/dkms/wireguard/1.0.20200401/build/queueing.o
  CC [M]  /var/lib/dkms/wireguard/1.0.20200401/build/send.o
  CC [M]  /var/lib/dkms/wireguard/1.0.20200401/build/receive.o
  CC [M]  /var/lib/dkms/wireguard/1.0.20200401/build/socket.o
  CC [M]  /var/lib/dkms/wireguard/1.0.20200401/build/peerlookup.o
  CC [M]  /var/lib/dkms/wireguard/1.0.20200401/build/allowedips.o
  CC [M]  /var/lib/dkms/wireguard/1.0.20200401/build/ratelimiter.o
/var/lib/dkms/wireguard/1.0.20200401/build/ratelimiter.c:25:1: error:
unknown type name ?hsiphash_key_t?
 static hsiphash_key_t key;
 ^
/var/lib/dkms/wireguard/1.0.20200401/build/ratelimiter.c: In function
?wg_ratelimiter_allow?:
/var/lib/dkms/wireguard/1.0.20200401/build/ratelimiter.c:109:3: error:
implicit declaration of function ?hsiphash_2u32?
[-Werror=implicit-function-declaration]
   bucket = &table_v4[hsiphash_2u32(net_word, ip, &key) &
   ^
/var/lib/dkms/wireguard/1.0.20200401/build/ratelimiter.c:116:3: error:
implicit declaration of function ?hsiphash_3u32?
[-Werror=implicit-function-declaration]
   bucket = &table_v6[hsiphash_3u32(net_word, ip >> 32, ip, &key) &
   ^
cc1: some warnings being treated as errors
make[2]: *** [/var/lib/dkms/wireguard/1.0.20200401/build/ratelimiter.o]
Error 1
make[1]: *** [_module_/var/lib/dkms/wireguard/1.0.20200401/build] Error 2
make: *** [module] Error 2


The following change works for me; make succeeds:
--- compat/compat.h.bak 2020-04-11 20:04:15.077425108 +0200
+++ compat/compat.h     2020-04-11 20:06:39.279397118 +0200
@@ -1034,7 +1034,7 @@
 }
 #endif

-#if defined(ISUBUNTU1604)
+#if defined(ISUBUNTU1604) || defined(ISRHEL7)
 #include <linux/siphash.h>
 #ifndef _WG_LINUX_SIPHASH_H
 #define hsiphash_2u32 siphash_2u32

Kind regards,
Christian


^ permalink raw reply	[flat|nested] 2+ messages in thread

* RHEL 7.8, Kernel 3.10: ratelimiter.c:25:1: error: unknown type name 'hsiphash_key_t'
  2020-04-11 18:21 RHEL 7.8, Kernel 3.10: ratelimiter.c:25:1: error: unknown type name 'hsiphash_key_t' cwei
@ 2020-04-14  9:06 ` Jason
  0 siblings, 0 replies; 2+ messages in thread
From: Jason @ 2020-04-14  9:06 UTC (permalink / raw)


Hi Christian,

Thanks. Addressed here:
https://git.zx2c4.com/wireguard-linux-compat/commit/?id=c15894ad17cb0760471c2dd798bfbbea2081b4db
. I'll have a new release out shortly.

By the way, you'll have more reliability using the elrepo kmod these days:
https://lists.zx2c4.com/pipermail/wireguard/2020-April/005239.html

Jason


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, back to index

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-11 18:21 RHEL 7.8, Kernel 3.10: ratelimiter.c:25:1: error: unknown type name 'hsiphash_key_t' cwei
2020-04-14  9:06 ` Jason

Development discussion of WireGuard

Archives are clonable: git clone --mirror http://inbox.vuxu.org/wireguard

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://inbox.vuxu.org/vuxu.archive.wireguard


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git