Rust Rocket install problem build failed proc-macro2

Hello, i new in rust, and try to develop web. I use rocket and try to install in CentOS 7
for my reference Getting Started - Rocket Programming Guide

This's my error :
[root@localhost html]# cargo run
Compiling proc-macro2 v0.4.28
Compiling libc v0.2.51
Compiling byteorder v1.3.1
Compiling syn v0.15.32
Compiling httparse v1.3.3
Compiling serde v1.0.90
Compiling memchr v2.2.0
Compiling log v0.4.6
Compiling pear_codegen v0.1.2
Compiling unicase v1.4.2
Compiling unicode-bidi v0.3.4
Compiling ring v0.13.5
error: failed to run custom build command for proc-macro2 v0.4.28
could not execute process /var/www/html/target/debug/build/proc-macro2-716ba4b45c924754/build-script-build (never executed)
warning: build failed, waiting for other jobs to finish...
error: build failed

anyone help me?

The fact that it's proc-macro2 that failed really makes me think it's a Rust version problem. Did you install Rust from the CentOS repository with yum or did you install it using rustup like the linked Getting Started guide said to do?

I install Rust with curl https://sh.rustup.rs -sSf | sh

Rust Version : rustup 1.18.0 (8603e2c56 2019-04-22)
Cargo Version : cargo 1.36.0-nightly (6be12653d 2019-04-19)

Good.

Can I see the output of running rustc --version from inside your project's source directory?

rustc 1.36.0-nightly (e305df184 2019-04-24)

do you know something? :star_struck:

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.