Comments (9)
I'm going to have a look at how to fix this code along with some people from the musl project, are there any suggestions as to how you would want this handled?
from mtr.
I'd suggest using the library c-ares for DNS resolution. Possibly making it compile time optional with --disable-dns.
from mtr.
Could you test the branch "newdns"?
Today three or four reports of "things going wrong" with the self-written internal DNS resolver. I'm getting a bit tired of that....
from mtr.
@rewolff thanks, I'll happily have a look. Been busy getting patches for a lot of the stuff I'm using upstreamed :)
from mtr.
checking whether __res_state_ext needs to be defined... yes
checking whether provided __res_state_ext definition can be compiled... no
configure: error: Need definition for struct __res_state_ext but unable to define it.
^ this is as far as I got with the newdns branch, same error as before due to musl not having a resolver like that of glibc
from mtr.
I get this error:
checking whether provided __res_state_ext definition can be compiled... no configure: error: Need definition for struct __res_state_ext but unable to define it.
As I understand __anything is for internal libc use only and should not be used (or even exposed) to applications.
That said, it compiles with --disable-ipv6
from mtr.
the __res_state_ext is apparently not needed for the 'newdns' branch. After removing it it builds and appears to work just fine.
diff --git a/configure.ac b/configure.ac
index d50c253..708db4f 100644
--- a/configure.ac
+++ b/configure.ac
@@ -139,57 +139,6 @@ AC_CHECK_FUNC(getaddrinfo,
USES_IPV6=yes
fi])
-AC_DEFUN([NEED_RES_STATE_EXT_TEST_SRC], [
-AC_LANG_PROGRAM([[
-#include <netinet/in.h>
-#include <resolv.h>
-#ifdef __GLIBC__
-#define RESEXTIN6(r,i) (*(r._u._ext.nsaddrs[i]))
-#else
-#define RESEXTIN6(r,i) (r._u._ext.ext->nsaddrs[i].sin6)
-#endif
-]], [[
-struct __res_state res;
-return RESEXTIN6(res,0).sin6_addr.s6_addr[0];
-]])])
-AC_DEFUN([DEFINE_RES_STATE_EXT_TEST_SRC], [
-AC_LANG_PROGRAM([[
-#include <netinet/in.h>
-#include <resolv.h>
-#ifdef __GLIBC__
-#define RESEXTIN6(r,i) (*(r._u._ext.nsaddrs[i]))
-#else
-#define RESEXTIN6(r,i) (r._u._ext.ext->nsaddrs[i].sin6)
-struct __res_state_ext {
- union res_sockaddr_union nsaddrs[MAXNS];
- struct sort_list {
- int af;
- union {
- struct in_addr ina;
- struct in6_addr in6a;
- } addr, mask;
- } sort_list[MAXRESOLVSORT];
- char nsuffix[64];
- char nsuffix2[64];
-};
-#endif
-]], [[
-struct __res_state res;
-return RESEXTIN6(res,0).sin6_addr.s6_addr[0];
-]])])
-if test "x$USES_IPV6" = "xyes"; then
- AC_MSG_CHECKING([whether __res_state_ext needs to be defined])
- AC_COMPILE_IFELSE([NEED_RES_STATE_EXT_TEST_SRC],
- [AC_MSG_RESULT([no])],
- [AC_MSG_RESULT([yes])
- AC_MSG_CHECKING([whether provided __res_state_ext definition can be compiled])
- AC_COMPILE_IFELSE([DEFINE_RES_STATE_EXT_TEST_SRC],
- [AC_MSG_RESULT([yes])
- AC_DEFINE(NEED_RES_STATE_EXT, 1, [Define if struct __res_state_ext needs to be defined.])],
- [AC_MSG_RESULT([no])
- AC_MSG_ERROR(Need definition for struct __res_state_ext but unable to define it.)])])
-fi
-
AC_CHECK_DECLS(errno, , , [[
#include <errno.h>
#include <sys/errno.h>
from mtr.
On Fri, 19 Dec 2014, James Taylor wrote:
checking whether __res_state_ext needs to be defined... yes
checking whether provided __res_state_ext definition can be compiled... no
configure: error: Need definition for struct __res_state_ext but unable to define it.
^ this is as far as I got with the newdns branch, same error as before due to musl not having a resolver like that of glibc
I don't think those checks are needed for the newdns branch any more.
Antonio Querubin
e-mail: [email protected]
xmpp: [email protected]
from mtr.
yeah. removed and uploaded.
from mtr.
Related Issues (20)
- on cygwin build error HOT 1
- Using the -f option changes the packet rate. HOT 1
- Next release
- Show whether ICMP, UDP, or TCP is currently used HOT 1
- Show target ip when use -r or -j HOT 1
- BUG: Interface-specific binding and packet marking broken HOT 13
- Show source address when use -r HOT 1
- Proposal: Refactor Address Selection Logic for Enhanced Compatibility and Testability HOT 5
- MaxMind DB for Location HOT 9
- where can i get mtr 0.95? HOT 2
- traceroute does not stop on subnet router anycast addresses on linux routers HOT 2
- Implement DNF flag to set/clear Do Not Fragment bit
- Problems running on Ubuntu 22.04, routing information is displayed incompletely, only part of it is displayed, can't get to the final destination HOT 6
- Two host lines for each hop (regression between 0.92 and 0.95?)
- What is the meaning of 'Received error response' HOT 2
- MTR hangs on IPv6 UDP trace when both --localport and --port are specified.
- mtr-packet returns "invalid argument" for IPv6 probe command HOT 1
- Packet type unsupported HOT 8
- TCP (not TLS) RTT time report not measuring the RTT. HOT 12
- Privacy question HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mtr.