Lastest version: 2.82
patches:
Inspired by these repos:
Original regex patch for dnsmasq 2.63
Offical dnsmasq:
For Debian/Ubuntu:
# Install libpcre3 and pkg-config
sudo apt install libpcre3-dev pkg-config
# Clone the repo
git clone https://github.com/lixingcong/dnsmasq-regex
cd dnsmasq-regex
# update the sub-module 'dnsmasq' to latest version
# only update when a newer version is released
bash ./update_submodule.sh
# build it
make
# Run the binary, check if the compile option contains "regex(+ipset)"
./dnsmasq/src/dnsmasq --version
Tips: If you do not need the patch of regex_ipset, just edit the file "Makefile" and build from source again.
Change this line
DNSMASQ_COPTS="-DHAVE_REGEX -DHAVE_REGEX_IPSET"
to
DNSMASQ_COPTS="-DHAVE_REGEX"
Tips: A simple script to generate domains configurations: my-gfwlist
Please check this page: dnsmasq-regex-openwrt