mirror of
https://github.com/SagerNet/sing-box.git
synced 2024-11-22 00:21:30 +00:00
Fix build embed tor for mobile
This commit is contained in:
parent
5a4e8fea81
commit
f674b4fbd5
1
go.mod
1
go.mod
|
@ -18,6 +18,7 @@ require (
|
|||
github.com/logrusorgru/aurora v2.0.3+incompatible
|
||||
github.com/mholt/acmez v1.1.0
|
||||
github.com/miekg/dns v1.1.52
|
||||
github.com/ooni/go-libtor v1.1.7
|
||||
github.com/oschwald/maxminddb-golang v1.10.0
|
||||
github.com/pires/go-proxyproto v0.6.2
|
||||
github.com/sagernet/cloudflare-tls v0.0.0-20221031050923-d70792f4c3a0
|
||||
|
|
2
go.sum
2
go.sum
|
@ -77,6 +77,8 @@ github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e/go.mod h1:zD1mROLA
|
|||
github.com/onsi/ginkgo/v2 v2.2.0 h1:3ZNA3L1c5FYDFTTxbFeVGGD8jYvjYauHD30YgLxVsNI=
|
||||
github.com/onsi/ginkgo/v2 v2.2.0/go.mod h1:MEH45j8TBi6u9BMogfbp0stKC5cdGjumZj5Y7AG4VIk=
|
||||
github.com/onsi/gomega v1.20.1 h1:PA/3qinGoukvymdIDV8pii6tiZgC8kbmJO6Z5+b002Q=
|
||||
github.com/ooni/go-libtor v1.1.7 h1:ooVcdEPBqDox5OfeXAfXIeQFCbqMLJVfIpO+Irr7N9A=
|
||||
github.com/ooni/go-libtor v1.1.7/go.mod h1:q1YyLwRD9GeMyeerVvwc0vJ2YgwDLTp2bdVcrh/JXyI=
|
||||
github.com/oschwald/maxminddb-golang v1.10.0 h1:Xp1u0ZhqkSuopaKmk1WwHtjF0H9Hd9181uj2MQ5Vndg=
|
||||
github.com/oschwald/maxminddb-golang v1.10.0/go.mod h1:Y2ELenReaLAZ0b400URyGwvYxHV1dLIxBuyOsyYjHK0=
|
||||
github.com/pierrec/lz4/v4 v4.1.14 h1:+fL8AQEZtz/ijeNnpduH0bROTu0O3NZAlPjQxGn8LwE=
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
//go:build with_embedded_tor
|
||||
//go:build with_embedded_tor && !(android || ios)
|
||||
|
||||
package outbound
|
||||
|
||||
|
|
15
outbound/tor_embed_mobile.go
Normal file
15
outbound/tor_embed_mobile.go
Normal file
|
@ -0,0 +1,15 @@
|
|||
//go:build with_embedded_tor && (android || ios)
|
||||
|
||||
package outbound
|
||||
|
||||
import (
|
||||
"github.com/cretz/bine/tor"
|
||||
"github.com/ooni/go-libtor"
|
||||
)
|
||||
|
||||
func newConfig() tor.StartConf {
|
||||
return tor.StartConf{
|
||||
ProcessCreator: libtor.Creator,
|
||||
UseEmbeddedControlConn: true,
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue