libasr: restore musl patch

Signed-off-by: Jürgen Buchmüller <pullmoll@t-online.de>
This commit is contained in:
Jürgen Buchmüller 2018-08-28 15:19:13 +02:00
parent 03afb3f0ef
commit 3136231f8d
No known key found for this signature in database
GPG key ID: 6764EC32352D0647

View file

@ -0,0 +1,24 @@
diff --git configure.ac configure.ac
index 10aff04..07e149f 100644
--- configure.ac
+++ configure.ac
@@ -456,6 +456,7 @@ AC_CHECK_FUNCS([ \
issetugid \
memmove \
reallocarray \
+ res_randomid \
snprintf \
strdup \
strerror \
diff --git src/asr_private.h src/asr_private.h
index 0960e37..158e7ff 100644
--- src/asr_private.h
+++ src/asr_private.h
@@ -365,3 +365,7 @@ extern FILE * asr_debug;
asr_statestr((a)->as_state), \
asr_statestr((s))); \
(a)->as_state = (s); } while (0)
+
+#ifndef HAVE_RES_RANDOMID
+#define res_randomid(x) (0xffff & getpid())
+#endif