--- a/libopendkim/dkim-dns.c
+++ b/libopendkim/dkim-dns.c
@@ -163,6 +163,9 @@ int
 dkim_res_query(void *srv, int type, unsigned char *query, unsigned char *buf,
                size_t buflen, void **qh)
 {
+#ifdef __UCLIBC__
+	return DKIM_DNS_ERROR;
+#else
 	int n;
 	int ret;
 	struct dkim_res_qh *rq;
@@ -209,6 +212,7 @@ dkim_res_query(void *srv, int type, unsigned char *query, unsigned char *buf,
 	*qh = (void *) rq;
 
 	return DKIM_DNS_SUCCESS;
+#endif // __UCLIBC__
 }
 
 /*
