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

build failed on Debian 10 #307

Closed
tporwx opened this issue Oct 31, 2020 · 6 comments
Closed

build failed on Debian 10 #307

tporwx opened this issue Oct 31, 2020 · 6 comments

Comments

@tporwx
Copy link

tporwx commented Oct 31, 2020

config.status: executing depfiles commands

--- stderr
config.status: error: in /tmp/cargo-installq5WxZo/release/build/libsodium-sys-b3bc1576cd2176db/out/source/libsodium': config.status: error: Something went wrong bootstrapping makefile fragments for automatic dependency tracking. If GNU make was not used, consider re-running the configure script with MAKE="gmake" (or whatever is necessary). You can also try re-running configure with the '--disable-dependency-tracking' option to at least be able to build the package (albeit without support for automatic dependency tracking). See config.log' for more details
thread 'main' panicked at '
Failed to configure libsodium using "/tmp/cargo-installq5WxZo/release/build/libsodium-sys-b3bc1576cd2176db/out/source/libsodium/configure" "--prefix=/tmp/cargo-installq5WxZo/release/build/libsodium-sys-b3bc1576cd2176db/out/installed" "--libdir=/tmp/cargo-installq5WxZo/release/build/libsodium-sys-b3bc1576cd2176db/out/installed/lib" "--host=x86_64-unknown-linux-gnu" "--enable-shared=no"
CFLAGS=-O3 -ffunction-sections -fdata-sections -fPIC -m64 -Wall -Wextra
CC=cc

', /root/.cargo/registry/src/github.com-1ecc6299db9ec823/libsodium-sys-0.2.6/build.rs:240:9
note: run with RUST_BACKTRACE=1 environment variable to display a backtrace.

warning: build failed, waiting for other jobs to finish...
error: failed to compile shadowsocks-rust v1.8.20, intermediate artifacts can be found at /tmp/cargo-installq5WxZo

@zonyitoo
Copy link
Collaborator

Do you have build tool chains installed on your system, like gcc, make, ld, ...

@dolphinpaopao
Copy link

Ubuntu18.04.5LTS 前面几个版本都编译正常,最新拉取的代码编译出错。
error[E0658]: use of unstable library feature 'no_more_cas': no more CAS loops in user code
--> /home/tom/.cargo/registry/src/github.com-1ecc6299db9ec823/spin-0.7.0/src/mutex/ticket.rs:208:14
|
208 | .fetch_update(Ordering::SeqCst, Ordering::SeqCst, |ticket| {
| ^^^^^^^^^^^^
|
= note: see issue #48655 rust-lang/rust#48655 for more information

error[E0277]: expected a core::ops::FnMut<(usize,)> closure, found core::sync::atomic::Ordering
--> /home/tom/.cargo/registry/src/github.com-1ecc6299db9ec823/spin-0.7.0/src/mutex/ticket.rs:208:14
|
208 | .fetch_update(Ordering::SeqCst, Ordering::SeqCst, |ticket| {
| ^^^^^^^^^^^^ expected an FnMut<(usize,)> closure, found core::sync::atomic::Ordering
|
= help: the trait core::ops::FnMut<(usize,)> is not implemented for core::sync::atomic::Ordering

error[E0308]: mismatched types
--> /home/tom/.cargo/registry/src/github.com-1ecc6299db9ec823/spin-0.7.0/src/mutex/ticket.rs:208:63
|
208 | .fetch_update(Ordering::SeqCst, Ordering::SeqCst, |ticket| {
| __________________________________________________^
209 | | if self.next_serving.load(Ordering::Acquire) == ticket {
210 | | Some(ticket + 1)
211 | | } else {
212 | | None
213 | | }
214 | | });
| |
^ expected enum core::sync::atomic::Ordering, found closure
|
= note: expected enum core::sync::atomic::Ordering
found closure [closure@/home/tom/.cargo/registry/src/github.com-1ecc6299db9ec823/spin-0.7.0/src/mutex/ticket.rs:208:63: 214:14 self:_]

error: aborting due to 3 previous errors

Some errors have detailed explanations: E0277, E0308, E0658.
For more information about an error, try rustc --explain E0277.
error: could not compile spin.

To learn more, run the command again with --verbose.
warning: build failed, waiting for other jobs to finish...
error: build failed

@abcfy2
Copy link
Contributor

abcfy2 commented Nov 1, 2020

Cannot reproduce:

# lsb_release -a
No LSB modules are available.
Distributor ID: Debian
Description:    Debian GNU/Linux 10 (buster)
Release:        10
Codename:       buster

# cargo --version
cargo 1.47.0 (f3c7e066a 2020-08-28)

# rustc --version
rustc 1.47.0 (18bf6b4f0 2020-10-07)

# rustup toolchain list
stable-x86_64-unknown-linux-gnu (default)

# gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/8/lto-wrapper
OFFLOAD_TARGET_NAMES=nvptx-none
OFFLOAD_TARGET_DEFAULT=1
Target: x86_64-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Debian 8.3.0-6' --with-bugurl=file:///usr/share/doc/gcc-8/README.Bugs --enable-languages=c,ada,c++,go,brig,d,fortran,objc,obj-c++ --prefix=/usr --with-gcc-major-version-only --program-suffix=-8 --program-prefix=x86_64-linux-gnu- --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --libdir=/usr/lib --enable-nls --enable-bootstrap --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --with-default-libstdcxx-abi=new --enable-gnu-unique-object --disable-vtable-verify --enable-libmpx --enable-plugin --enable-default-pie --with-system-zlib --with-target-system-zlib --enable-objc-gc=auto --enable-multiarch --disable-werror --with-arch-32=i686 --with-abi=m64 --with-multilib-list=m32,m64,mx32 --enable-multilib --with-tune=generic --enable-offload-targets=nvptx-none --without-cuda-driver --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu
Thread model: posix
gcc version 8.3.0 (Debian 8.3.0-6)

# cargo build --release --features 'openssl-vendored local-redir'
# ...SNIP ...
   Compiling shadowsocks-rust v1.8.21 (/root/shadowsocks-rust)
    Finished release [optimized] target(s) in 2m 38s

# file target/release/sslocal
target/release/sslocal: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, for GNU/Linux 3.2.0, BuildID[sha1]=6a6ecdf68291590e8e2782ec3957cb9de18e5022, with debug_info, not stripped

# target/release/sslocal --version
shadowsocks 1.8.21

@zonyitoo
Copy link
Collaborator

zonyitoo commented Nov 1, 2020

Cannot reproduce, too. Could you provide more information about rustc version, system version, platform archtecture, and so on...

I suspect that your rustc is too old to compile spin.

@dolphinpaopao
Copy link

Description: Ubuntu 18.04.5 LTS
Release: 18.04
Codename: bionic

cargo 1.43.0

rustc 1.43.0

gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/7/lto-wrapper
OFFLOAD_TARGET_NAMES=nvptx-none
OFFLOAD_TARGET_DEFAULT=1
Target: x86_64-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Ubuntu 7.5.0-3ubuntu118.04' --with-bugurl=file:///usr/share/doc/gcc-7/README.Bugs --enable-languages=c,ada,c++,go,brig,d,fortran,objc,obj-c++ --prefix=/usr --with-gcc-major-version-only --program-suffix=-7 --program-prefix=x86_64-linux-gnu- --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --libdir=/usr/lib --enable-nls --enable-bootstrap --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --with-default-libstdcxx-abi=new --enable-gnu-unique-object --disable-vtable-verify --enable-libmpx --enable-plugin --enable-default-pie --with-system-zlib --with-target-system-zlib --enable-objc-gc=auto --enable-multiarch --disable-werror --with-arch-32=i686 --with-abi=m64 --with-multilib-list=m32,m64,mx32 --enable-multilib --with-tune=generic --enable-offload-targets=nvptx-none --without-cuda-driver --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu
Thread model: posix
gcc version 7.5.0 (Ubuntu 7.5.0-3ubuntu1
18.04)

~$ rustup toolchain list
stable-x86_64-unknown-linux-gnu (default)

感谢回复和作者的辛勤开发,打算直接下载release了,有时间再捣鼓一下。

@zonyitoo
Copy link
Collaborator

zonyitoo commented Nov 1, 2020

Yes, you should probably download the release packets directly.

Consider upgrade your rustc, current stable release is v1.47.

I am closing this issue, since it is unproducible on others environments.

@zonyitoo zonyitoo closed this as completed Nov 1, 2020
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

4 participants