mirror of
https://github.com/SagerNet/sing-box.git
synced 2024-11-25 18:11:28 +00:00
19 lines
490 B
Go
19 lines
490 B
Go
|
//go:build !with_dhcp
|
||
|
|
||
|
package include
|
||
|
|
||
|
import (
|
||
|
"context"
|
||
|
|
||
|
"github.com/sagernet/sing-dns"
|
||
|
E "github.com/sagernet/sing/common/exceptions"
|
||
|
"github.com/sagernet/sing/common/logger"
|
||
|
N "github.com/sagernet/sing/common/network"
|
||
|
)
|
||
|
|
||
|
func init() {
|
||
|
dns.RegisterTransport([]string{"dhcp"}, func(ctx context.Context, logger logger.ContextLogger, dialer N.Dialer, link string) (dns.Transport, error) {
|
||
|
return nil, E.New(`DHCP is not included in this build, rebuild with -tags with_dhcp`)
|
||
|
})
|
||
|
}
|