BuildDebug = YES
BuildProfile = YES
+Install_Headers_Directory = /usr/include/arpa
+Install_Headers = inet.h
+
CFILES = herror.c res_comp.c res_data.c res_debug.c\
res_init.c res_mkquery.c res_query.c res_send.c
-DUSE_OPTIONS_H -D__DARWIN_NON_CANCELABLE=1
include $(MAKEFILEPATH)/CoreOS/ReleaseControl/BSDCommon.make
-
-after_install:
- $(INSTALL_DIRECTORY) "$(DSTROOT)"/usr/include/arpa
- $(INSTALL_FILE) inet.h "$(DSTROOT)"/usr/include/arpa/inet.h
return _fsi_get_ether(si, NULL, SEL_ALL);
}
+static si_list_t *
+file_addrinfo(si_mod_t *si, const void *node, const void *serv, uint32_t family, uint32_t socktype, uint32_t proto, uint32_t flags, const char *interface, uint32_t *err)
+{
+ if (err != NULL) *err = SI_STATUS_NO_ERROR;
+ return _gai_simple(si, node, serv, family, socktype, proto, flags, interface, err);
+}
+
__private_extern__ si_mod_t *
si_module_static_file()
{
out->sim_mac_bymac = file_mac_bymac;
out->sim_mac_all = file_mac_all;
- /* no addrinfo support */
out->sim_wants_addrinfo = NULL;
- out->sim_addrinfo = NULL;
+ out->sim_addrinfo = file_addrinfo;
/* no nameinfo support */
out->sim_nameinfo = NULL;
return out;
}
-// embedded does not do parallel A/AAAA
-#if !TARGET_OS_EMBEDDED
static si_list_t *
_mdns_addrinfo(si_mod_t *si, const void *node, const void *serv, uint32_t family, uint32_t socktype, uint32_t proto, uint32_t flags, const char *interface, uint32_t *err)
{
}
return out;
}
-#endif // !TARGET_OS_EMBEDDED
static si_list_t *
_mdns_srv_byname(si_mod_t* si, const char *qname, const char *interface, uint32_t *err)
out->sim_host_byname = _mdns_hostbyname;
out->sim_host_byaddr = _mdns_hostbyaddr;
out->sim_item_call = _mdns_item_call;
-#if !TARGET_OS_EMBEDDED
out->sim_addrinfo = _mdns_addrinfo;
-#endif
out->sim_srv_byname = _mdns_srv_byname;
int res;
#if TARGET_OS_EMBEDDED
// log a warning for queries from the main thread
if (pthread_main_np()) asl_log(NULL, NULL, ASL_LEVEL_WARNING, "Warning: Libinfo call to mDNSResponder on main thread");
-#endif // #if TARGET_OS_EMBEDDED
+#endif // TARGET_OS_EMBEDDED
// Timeout Logic
// The kevent(2) API timeout parameter is used to enforce the total
/* _gai_simple
* Simple lookup via gethostbyname2(3) mechanism.
*/
-static si_list_t *
+__private_extern__ si_list_t *
_gai_simple(si_mod_t *si, const void *nodeptr, const void *servptr, uint32_t family, uint32_t socktype, uint32_t proto, uint32_t flags, const char *interface, uint32_t *err)
{
si_item_t *h4_item = NULL, *h6_item = NULL;
si_list_t *si_addrinfo_list_from_hostent(si_mod_t *si, uint32_t socktype, uint32_t proto, uint16_t port, uint16_t scope, const struct hostent *h4, const struct hostent *h6);
int _gai_serv_to_port(const char *serv, uint32_t proto, uint16_t *port);
+si_list_t *_gai_simple(si_mod_t *si, const void *nodeptr, const void *servptr, uint32_t family, uint32_t socktype, uint32_t proto, uint32_t flags, const char *interface, uint32_t *err);
#endif /* ! __SI_MODULE_H__ */