From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server-vie001.gnuweeb.org X-Spam-Level: X-Spam-Status: No, score=-1.2 required=5.0 tests=ALL_TRUSTED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,URIBL_DBL_BLOCKED_OPENDNS, URIBL_ZEN_BLOCKED_OPENDNS autolearn=ham autolearn_force=no version=3.4.6 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gnuweeb.org; s=new2025; t=1759222489; bh=hEoeESHeuHGn0FsZXSDf8VQ+zfNWqGNQGy7Sc1nHfe8=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version:Content-Transfer-Encoding:Message-ID:Date:From: Reply-To:Subject:To:Cc:In-Reply-To:References:Resent-Date: Resent-From:Resent-To:Resent-Cc:User-Agent:Content-Type: Content-Transfer-Encoding; b=YOIp/IrfI9RCdMh09kAglp8nysAncnH8yi1EZ8jVQvCxp143F/sH+iAYjfJ1Av+eQ 0kIW/QdRx3dt+c3T80bv58JAItxXP2zHMjeLJ8HUe9gTb3/IHPYuvneQ8Nr65qoyxv L+Z1Rl9hgW/VgR2FQSS668pd5R+M9kki/j10dCGczUEVmSCathcDtvuJk1jfV6F0PV tIDjCs+ZOZQQRJvqmuIwUa7hIDrNrVhX35NMJA3+tRAY2cbdx4ee7Kfauy9MX3ciVl 9zAdKjJD3CL7sVwPQNULXjvPDVXLZsvcbCfmscGSi96OpIY25/vasmDah1RsK84KXz fCKTvhS0pEXcw== Received: from localhost.localdomain (unknown [68.183.184.174]) by server-vie001.gnuweeb.org (Postfix) with ESMTPSA id 46316312791B; Tue, 30 Sep 2025 08:54:48 +0000 (UTC) From: Alviro Iskandar Setiawan To: Ammar Faiz Cc: Alviro Iskandar Setiawan , Ahmad Gani , GNU/Weeb Mailing List Subject: [PATCH gwproxy v13 8/8] Makefile: Introduce --use-new-dns-resolver configure option Date: Tue, 30 Sep 2025 15:54:28 +0700 Message-Id: <20250930085428.717195-9-alviro.iskandar@gnuweeb.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20250930085428.717195-1-alviro.iskandar@gnuweeb.org> References: <20250930085428.717195-1-alviro.iskandar@gnuweeb.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit List-Id: Add a configure option to enable the new DNS resolver feature. By default it is disabled as it's still experimental. Signed-off-by: Alviro Iskandar Setiawan --- Makefile | 6 ++++++ configure | 8 ++++++++ 2 files changed, 14 insertions(+) diff --git a/Makefile b/Makefile index 3ac35f0..a2d1e71 100644 --- a/Makefile +++ b/Makefile @@ -83,6 +83,12 @@ endif -include config.make LIBS=$(LIB_LDFLAGS) +ifeq ($(CONFIG_NEW_DNS_RESOLVER),y) +GWPROXY_CC_SOURCES += \ + $(GWPROXY_DIR)/dns_parser.c \ + $(GWPROXY_DIR)/dns_resolver.c +endif + ifeq ($(CONFIG_IO_URING),y) GWPROXY_CC_SOURCES += $(GWPROXY_DIR)/ev/io_uring.c ALL_GWPROXY_OBJECTS += $(LIBURING_TARGET) diff --git a/configure b/configure index 44c49da..6daaeb6 100755 --- a/configure +++ b/configure @@ -37,6 +37,9 @@ for opt do --use-io-uring) use_io_uring="yes"; ;; + --use-new-dns-resolver) + use_new_dns_resolver="yes"; + ;; --sanitize) use_sanitize="yes"; ;; @@ -88,6 +91,7 @@ Options: [defaults in brackets after descriptions] --debug Build with debug enabled --use-io-uring Enable io_uring support (default: no) --sanitize Enable sanitizers (default: no) + --use-new-dns-resolver Use the new DNS resolver feature (default: no) EOF exit 0; fi @@ -346,6 +350,10 @@ if test "${use_sanitize}" = "yes"; then CXXFLAGS="${CXXFLAGS} -fsanitize=address -fsanitize=undefined"; fi; +if test "${use_new_dns_resolver}" = "yes"; then + add_config "CONFIG_NEW_DNS_RESOLVER"; +fi; + add_config "CONFIG_LINUX"; if test "${use_debug}" = "yes"; then -- Alviro Iskandar Setiawan