Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

xray-core编译失败 #183

Open
ChaingTsung opened this issue Sep 12, 2024 · 3 comments
Open

xray-core编译失败 #183

ChaingTsung opened this issue Sep 12, 2024 · 3 comments

Comments

@ChaingTsung
Copy link

...
1 CC="x86_64-openwrt-linux-musl-gcc" CXX="x86_64-openwrt-linux-musl-g++" CGO_CFLAGS="-Os -pipe -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=/home/holive/lede/build_dir/target-x86_64_musl/Xray-core-1.8.24=Xray-core-1.8.24 -Wformat -Werror=format-security -fstack-protector -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro" CGO_CPPFLAGS="-I/home/holive/lede/staging_dir/toolchain-x86_64_gcc-11.3.0_musl/usr/include -I/home/holive/lede/staging_dir/toolchain-x86_64_gcc-11.3.0_musl/include/fortify -I/home/holive/lede/staging_dir/toolchain-x86_64_gcc-11.3.0_musl/include" CGO_CXXFLAGS="-Os -pipe -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=/home/holive/lede/build_dir/target-x86_64_musl/Xray-core-1.8.24=Xray-core-1.8.24 -Wformat -Werror=format-security -fstack-protector -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro" CGO_LDFLAGS="-L/home/holive/lede/staging_dir/toolchain-x86_64_gcc-11.3.0_musl/usr/lib -L/home/holive/lede/staging_dir/toolchain-x86_64_gcc-11.3.0_musl/lib -znow -zrelro" GOPATH="/home/holive/lede/build_dir/target-x86_64_musl/Xray-core-1.8.24/.go_work/build" GOCACHE="/home/holive/lede/tmp/go-build" GOMODCACHE="/home/holive/lede/dl/go-mod-cache" GOENV=off GOTOOLCHAIN=local /usr/bin/env bash /home/holive/lede/feeds/packages/lang/golang//golang-build.sh build -v -buildvcs=false -trimpath -ldflags "all=-buildid '1725819138' -linkmode external -extldflags '-L/home/holive/lede/staging_dir/toolchain-x86_64_gcc-11.3.0_musl/usr/lib -L/home/holive/lede/staging_dir/toolchain-x86_64_gcc-11.3.0_musl/lib -Wl,-z,now -Wl,-z,relro'"        -ldflags "-s -w -X github.com/xtls/xray-core/core.build=OpenWrt -X github.com/xtls/xray-core/core.version=1.8.24 -buildid '1725819138' -linkmode external -extldflags '-L/home/holive/lede/staging_dir/toolchain-x86_64_gcc-11.3.0_musl/usr/lib -L/home/holive/lede/staging_dir/toolchain-x86_64_gcc-11.3.0_musl/lib -Wl,-z,now -Wl,-z,relro'"
Finding targets
go: downloading gvisor.dev/gvisor v0.0.0-20231202080848-1f7806d17489

Building targets
go: downloading gvisor.dev/gvisor v0.0.0-20231202080848-1f7806d17489
get "gvisor.dev/gvisor": found meta tag vcs.metaImport{Prefix:"gvisor.dev/gvisor", VCS:"git", RepoRoot:"https://github.com/google/gvisor"} at //gvisor.dev/gvisor?go-get=1
../../proxy/wireguard/gvisortun/tun.go:16:2: gvisor.dev/[email protected]: invalid version: unknown revision 1f7806d17489
../../proxy/wireguard/gvisortun/tun.go:17:2: gvisor.dev/[email protected]: invalid version: unknown revision 1f7806d17489
../../proxy/wireguard/gvisortun/tun.go:18:2: gvisor.dev/[email protected]: invalid version: unknown revision 1f7806d17489
../../proxy/wireguard/gvisortun/tun.go:19:2: gvisor.dev/[email protected]: invalid version: unknown revision 1f7806d17489
../../proxy/wireguard/gvisortun/tun.go:20:2: gvisor.dev/[email protected]: invalid version: unknown revision 1f7806d17489
../../proxy/wireguard/gvisortun/tun.go:21:2: gvisor.dev/[email protected]: invalid version: unknown revision 1f7806d17489
../../proxy/wireguard/gvisortun/tun.go:22:2: gvisor.dev/[email protected]: invalid version: unknown revision 1f7806d17489
../../proxy/wireguard/gvisortun/tun.go:23:2: gvisor.dev/[email protected]: invalid version: unknown revision 1f7806d17489
../../proxy/wireguard/gvisortun/tun.go:24:2: gvisor.dev/[email protected]: invalid version: unknown revision 1f7806d17489
../../proxy/wireguard/gvisortun/tun.go:25:2: gvisor.dev/[email protected]: invalid version: unknown revision 1f7806d17489
../../proxy/wireguard/gvisortun/tun.go:26:2: gvisor.dev/[email protected]: invalid version: unknown revision 1f7806d17489
../../proxy/wireguard/tun.go:22:2: gvisor.dev/[email protected]: invalid version: unknown revision 1f7806d17489

make[3]: *** [Makefile:53: /home/holive/lede/build_dir/target-x86_64_musl/Xray-core-1.8.24/.built] Error 1
make[3]: Leaving directory '/home/holive/lede/feeds/smpackage/xray-core'
time: package/feeds/smpackage/xray-core/compile#3.63#5.90#46.34
    ERROR: package/feeds/smpackage/xray-core failed to build.
make[2]: *** [package/Makefile:116: package/feeds/smpackage/xray-core/compile] Error 1
make[2]: Leaving directory '/home/holive/lede'
make[1]: *** [package/Makefile:110: /home/holive/lede/staging_dir/target-x86_64_musl/stamp/.package_compile] Error 2
make[1]: Leaving directory '/home/holive/lede'
make: *** [/home/holive/lede/include/toplevel.mk:231:world] 错误 2
@kenzok8
Copy link
Owner

kenzok8 commented Sep 14, 2024

golang 版本错误,或者下载失败

rm -rf feeds/packages/lang/golang
git clone https://github.com/kenzok8/golang feeds/packages/lang/golang

@ChaingTsung
Copy link
Author

golang 版本错误,或者下载失败

rm -rf feeds/packages/lang/golang
git clone https://github.com/kenzok8/golang feeds/packages/lang/golang

openwrt官方goloang或者lede的golang都不行

@ChaingTsung
Copy link
Author

golang 版本错误,或者下载失败

rm -rf feeds/packages/lang/golang
git clone https://github.com/kenzok8/golang feeds/packages/lang/golang

按照你的说明这样弄后还是不行

...
LUDES="" GO_GO_GENERATE="" GO_INSTALL_BIN_PATH="/usr/bin" BUILD_DIR="/home/holive/openwrt/build_dir/target-x86_64_musl/Xray-core-1.8.24" GO_BUILD_DIR="/home/holive/openwrt/build_dir/target-x86_64_musl/Xray-core-1.8.24/.go_work/build" GO_BUILD_BIN_DIR="/home/holive/openwrt/build_dir/target-x86_64_musl/Xray-core-1.8.24/.go_work/build/bin" GO_BUILD_DEPENDS_PATH="/usr/share/gocode" GO_BUILD_DEPENDS_SRC="/home/holive/openwrt/staging_dir/target-x86_64_musl/usr/share/gocode/src" GOOS="linux" GOARCH="amd64" GO386="" GOAMD64="v1" GOARM="" GOMIPS="" GOMIPS64="" GOPPC64="" CGO_ENABLED=1 CC="x86_64-openwrt-linux-musl-gcc" CXX="x86_64-openwrt-linux-musl-g++" CGO_CFLAGS="-Os -pipe -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=/home/holive/openwrt/build_dir/target-x86_64_musl/Xray-core-1.8.24=Xray-core-1.8.24 -Wformat -Werror=format-security -fstack-protector -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro" CGO_CPPFLAGS="-I/home/holive/openwrt/staging_dir/toolchain-x86_64_gcc-13.3.0_musl/usr/include -I/home/holive/openwrt/staging_dir/toolchain-x86_64_gcc-13.3.0_musl/include -I/home/holive/openwrt/staging_dir/toolchain-x86_64_gcc-13.3.0_musl/include/fortify" CGO_CXXFLAGS="-Os -pipe -fno-caller-saves -fno-plt -fhonour-copts -fmacro-prefix-map=/home/holive/openwrt/build_dir/target-x86_64_musl/Xray-core-1.8.24=Xray-core-1.8.24 -Wformat -Werror=format-security -fstack-protector -D_FORTIFY_SOURCE=1 -Wl,-z,now -Wl,-z,relro" CGO_LDFLAGS="-L/home/holive/openwrt/staging_dir/toolchain-x86_64_gcc-13.3.0_musl/usr/lib -L/home/holive/openwrt/staging_dir/toolchain-x86_64_gcc-13.3.0_musl/lib -fuse-ld=bfd -znow -zrelro" GOPATH="/home/holive/openwrt/build_dir/target-x86_64_musl/Xray-core-1.8.24/.go_work/build" GOCACHE="/home/holive/openwrt/tmp/go-build" GOMODCACHE="/home/holive/openwrt/dl/go-mod-cache" GOENV=off GOTOOLCHAIN=local /usr/bin/env bash ../../lang/golang//golang-build.sh build -v -buildvcs=false -trimpath -ldflags "all=-buildid '1726314915' -linkmode external -extldflags '-L/home/holive/openwrt/staging_dir/toolchain-x86_64_gcc-13.3.0_musl/usr/lib -L/home/holive/openwrt/staging_dir/toolchain-x86_64_gcc-13.3.0_musl/lib -fuse-ld=bfd -Wl,-z,now -Wl,-z,relro'"        -ldflags " -X github.com/xtls/xray-core/core.build=OpenWrt -X github.com/xtls/xray-core/core.version=1.8.24 -buildid '1726314915' -linkmode external -extldflags '-L/home/holive/openwrt/staging_dir/toolchain-x86_64_gcc-13.3.0_musl/usr/lib -L/home/holive/openwrt/staging_dir/toolchain-x86_64_gcc-13.3.0_musl/lib -fuse-ld=bfd -Wl,-z,now -Wl,-z,relro'"
Finding targets
go: downloading gvisor.dev/gvisor v0.0.0-20231202080848-1f7806d17489

Building targets
go: downloading gvisor.dev/gvisor v0.0.0-20231202080848-1f7806d17489
get "gvisor.dev/gvisor": found meta tag vcs.metaImport{Prefix:"gvisor.dev/gvisor", VCS:"git", RepoRoot:"https://github.com/google/gvisor"} at //gvisor.dev/gvisor?go-get=1
../../proxy/wireguard/gvisortun/tun.go:16:2: gvisor.dev/[email protected]: invalid version: unknown revision 1f7806d17489
../../proxy/wireguard/gvisortun/tun.go:17:2: gvisor.dev/[email protected]: invalid version: unknown revision 1f7806d17489
../../proxy/wireguard/gvisortun/tun.go:18:2: gvisor.dev/[email protected]: invalid version: unknown revision 1f7806d17489
../../proxy/wireguard/gvisortun/tun.go:19:2: gvisor.dev/[email protected]: invalid version: unknown revision 1f7806d17489
../../proxy/wireguard/gvisortun/tun.go:20:2: gvisor.dev/[email protected]: invalid version: unknown revision 1f7806d17489
../../proxy/wireguard/gvisortun/tun.go:21:2: gvisor.dev/[email protected]: invalid version: unknown revision 1f7806d17489
../../proxy/wireguard/gvisortun/tun.go:22:2: gvisor.dev/[email protected]: invalid version: unknown revision 1f7806d17489
../../proxy/wireguard/gvisortun/tun.go:23:2: gvisor.dev/[email protected]: invalid version: unknown revision 1f7806d17489
../../proxy/wireguard/gvisortun/tun.go:24:2: gvisor.dev/[email protected]: invalid version: unknown revision 1f7806d17489
../../proxy/wireguard/gvisortun/tun.go:25:2: gvisor.dev/[email protected]: invalid version: unknown revision 1f7806d17489
../../proxy/wireguard/gvisortun/tun.go:26:2: gvisor.dev/[email protected]: invalid version: unknown revision 1f7806d17489
../../proxy/wireguard/tun.go:22:2: gvisor.dev/[email protected]: invalid version: unknown revision 1f7806d17489

make[3]: *** [Makefile:91: /home/holive/openwrt/build_dir/target-x86_64_musl/Xray-core-1.8.24/.built] Error 1
make[3]: Leaving directory '/home/holive/openwrt/feeds/packages/net/xray-core'
time: package/feeds/packages/xray-core/compile#2.14#1.28#18.69
    ERROR: package/feeds/packages/xray-core failed to build.
make[2]: *** [package/Makefile:177: package/feeds/packages/xray-core/compile] Error 1
make[2]: Leaving directory '/home/holive/openwrt'
make[1]: *** [package/Makefile:171: /home/holive/openwrt/staging_dir/target-x86_64_musl/stamp/.package_compile] Error 2
make[1]: Leaving directory '/home/holive/openwrt'
make: *** [/home/holive/openwrt/include/toplevel.mk:248:world] 错误 2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants