This is a naive implementation using one single dnsmasq daemon. This does not work for vlans, and only listens to interfaces with an IP address. Is this what you had in mind?