termux-packages/packages/kphp/common-resolver.cpp.patch

19 lines
375 B
Diff
Raw Normal View History

2022-01-13 13:07:28 +01:00
--- a/common/resolver.cpp
+++ b/common/resolver.cpp
@@ -15,10 +15,14 @@
#include <sys/types.h>
#include <unistd.h>
+#ifdef __ANDROID__
+#include <sys/endian.h>
+#endif
+
#include "common/kprintf.h"
#include "common/options.h"
-#define HOSTS_FILE "/etc/hosts"
+#define HOSTS_FILE "@TERMUX_PREFIX@/etc/hosts"
#define MAX_HOSTS_SIZE (1L << 24)
int kdb_hosts_loaded;