NLnetLabs / routinator

An RPKI Validator and RTR server written in Rust
https://nlnetlabs.nl/projects/routing/routinator/
BSD 3-Clause "New" or "Revised" License
464 stars 71 forks source link

error: failed to compile `routinator v0.9.0` #598

Closed nullARC77 closed 3 years ago

nullARC77 commented 3 years ago

Trying to compile routinator following: https://github.com/racompton/routinator_centos7_install

Step 13: cargo install routinator

System: CentOS Linux release 7.9.2009 (Core)

Following packages are installed: sudo yum install -y vim wget curl net-tools lsof bash-completion yum-utils htop nginx httpd-tools tcpdump rust cargo rsync policycoreutils-python [sudo] password for user: Loaded plugins: fastestmirror, langpacks Loading mirror speeds from cached hostfile

[routinator@rpki-server-4 ~]$ cargo install routinator Updating crates.io index Downloaded routinator v0.9.0 Downloaded 1 crate (2.4 MB) in 0.46s Installing routinator v0.9.0 Downloaded syslog v5.0.0 Downloaded want v0.3.0 Downloaded unicode-width v0.1.8 Downloaded uuid v0.8.2 Downloaded ucd-trie v0.1.3 Downloaded tracing-core v0.1.18 Downloaded webpki v0.21.4 Downloaded serde_json v1.0.64 Downloaded unicode-normalization v0.1.19 Downloaded quick-xml v0.22.0 Downloaded hyper v0.14.10 Downloaded h2 v0.3.3 Downloaded reqwest v0.11.4 Downloaded nix v0.20.0 Downloaded syn v1.0.73 Downloaded clap v2.33.3 Downloaded webpki-roots v0.21.1 Downloaded rustls v0.19.1 Downloaded idna v0.2.3 Downloaded chrono v0.4.19 Downloaded futures-util v0.3.15 Downloaded fern v0.6.0 Downloaded flate2 v1.0.20 Downloaded bcder v0.6.0 Downloaded url v2.2.2 Downloaded mio v0.7.13 Downloaded http v0.2.4 Downloaded arc-swap v1.3.0 Downloaded tracing v0.1.26 Downloaded tokio-util v0.6.7 Downloaded rand v0.8.4 Downloaded tokio v1.8.1 Downloaded libc v0.2.98 Downloaded sled v0.34.6 Downloaded hashbrown v0.11.2 Downloaded rpki v0.11.1 Downloaded futures-executor v0.3.15 Downloaded futures v0.3.15 Downloaded crc32fast v1.2.1 Downloaded cc v1.0.69 Downloaded base64 v0.13.0 Downloaded async-compression v0.3.8 Downloaded toml v0.5.8 Downloaded tokio-stream v0.1.7 Downloaded serde v1.0.126 Downloaded pest v2.1.3 Downloaded fs2 v0.4.3 Downloaded fnv v1.0.7 Downloaded error-chain v0.12.4 Downloaded crossbeam-utils v0.8.5 Downloaded crossbeam-epoch v0.9.5 Downloaded bytes v1.0.1 Downloaded untrusted v0.7.1 Downloaded unicode-xid v0.2.2 Downloaded unicode-bidi v0.3.5 Downloaded tokio-socks v0.5.1 Downloaded tinyvec v1.2.0 Downloaded socket2 v0.4.0 Downloaded serde_derive v1.0.126 Downloaded ryu v1.0.5 Downloaded miniz_oxide v0.4.4 Downloaded memchr v2.4.0 Downloaded indexmap v1.7.0 Downloaded futures-sink v0.3.15 Downloaded futures-io v0.3.15 Downloaded futures-channel v0.3.15 Downloaded dirs-sys v0.3.6 Downloaded dirs v3.0.2 Downloaded byteorder v1.4.3 Downloaded bitflags v1.2.1 Downloaded ansi_term v0.11.0 Downloaded tokio-rustls v0.22.0 Downloaded thiserror v1.0.26 Downloaded textwrap v0.11.0 Downloaded proc-macro2 v1.0.27 Downloaded parking_lot v0.11.1 Downloaded num-traits v0.2.14 Downloaded log v0.4.14 Downloaded futures-macro v0.3.15 Downloaded futures-core v0.3.15 Downloaded form_urlencoded v1.0.1 Downloaded either v1.6.1 Downloaded crossbeam-queue v0.3.2 Downloaded cfg-if v1.0.0 Downloaded autocfg v1.0.1 Downloaded adler v1.0.2 Downloaded encoding_rs v0.8.28 Downloaded version_check v0.9.3 Downloaded vec_map v0.8.2 Downloaded try-lock v0.2.3 Downloaded tower-service v0.3.1 Downloaded tokio-macros v1.3.0 Downloaded tinyvec_macros v0.1.0 Downloaded time v0.1.43 Downloaded thiserror-impl v1.0.26 Downloaded tempfile v3.2.0 Downloaded smallvec v1.6.1 Downloaded signal-hook-registry v1.4.0 Downloaded semver-parser v0.10.2 Downloaded semver v0.11.0 Downloaded sct v0.6.1 Downloaded rand_core v0.6.3 Downloaded quote v1.0.9 Downloaded ppv-lite86 v0.2.10 Downloaded pin-project-lite v0.2.7 Downloaded parking_lot_core v0.8.3 Downloaded once_cell v1.8.0 Downloaded num-integer v0.1.44 Downloaded lock_api v0.4.4 Downloaded ipnet v2.3.1 Downloaded hyper-rustls v0.22.1 Downloaded httparse v1.4.1 Downloaded getrandom v0.2.3 Downloaded atty v0.2.14 Downloaded strsim v0.8.0 Downloaded spin v0.5.2 Downloaded slab v0.4.3 Downloaded serde_urlencoded v0.7.0 Downloaded scopeguard v1.1.0 Downloaded rustc_version v0.3.3 Downloaded remove_dir_all v0.5.3 Downloaded rand_chacha v0.3.1 Downloaded proc-macro-nested v0.1.7 Downloaded proc-macro-hack v0.5.19 Downloaded pin-utils v0.1.0 Downloaded percent-encoding v2.1.0 Downloaded num_cpus v1.13.0 Downloaded mime v0.3.16 Downloaded memoffset v0.6.4 Downloaded matches v0.1.8 Downloaded log-reroute v0.1.7 Downloaded lazy_static v1.4.0 Downloaded itoa v0.4.7 Downloaded instant v0.1.10 Downloaded httpdate v1.0.1 Downloaded http-body v0.4.2 Downloaded fxhash v0.2.1 Downloaded futures-task v0.3.15 Downloaded ring v0.16.20 Downloaded 139 crates (14.5 MB) in 3.18s (largest was ring at 5.1 MB) Compiling autocfg v1.0.1 Compiling libc v0.2.98 Compiling cfg-if v1.0.0 Compiling proc-macro2 v1.0.27 Compiling unicode-xid v0.2.2 Compiling syn v1.0.73 Compiling log v0.4.14 Compiling once_cell v1.8.0 Compiling memchr v2.4.0 Compiling pin-project-lite v0.2.7 Compiling futures-core v0.3.15 Compiling bytes v1.0.1 Compiling proc-macro-hack v0.5.19 Compiling cc v1.0.69 Compiling futures-task v0.3.15 Compiling futures-sink v0.3.15 Compiling futures-channel v0.3.15 Compiling proc-macro-nested v0.1.7 Compiling lazy_static v1.4.0 Compiling spin v0.5.2 Compiling serde_derive v1.0.126 Compiling futures-io v0.3.15 Compiling pin-utils v0.1.0 Compiling slab v0.4.3 Compiling untrusted v0.7.1 Compiling itoa v0.4.7 Compiling serde v1.0.126 Compiling crc32fast v1.2.1 Compiling matches v0.1.8 Compiling ucd-trie v0.1.3 Compiling fnv v1.0.7 Compiling ryu v1.0.5 Compiling hashbrown v0.11.2 Compiling base64 v0.13.0 Compiling tinyvec_macros v0.1.0 Compiling smallvec v1.6.1 Compiling httparse v1.4.1 Compiling crossbeam-utils v0.8.5 Compiling percent-encoding v2.1.0 Compiling scopeguard v1.1.0 Compiling try-lock v0.2.3 Compiling adler v1.0.2 Compiling bitflags v1.2.1 Compiling version_check v0.9.3 Compiling crossbeam-epoch v0.9.5 Compiling encoding_rs v0.8.28 Compiling httpdate v1.0.1 Compiling ppv-lite86 v0.2.10 Compiling tower-service v0.3.1 Compiling byteorder v1.4.3 Compiling unicode-width v0.1.8 Compiling crossbeam-queue v0.3.2 Compiling serde_json v1.0.64 Compiling either v1.6.1 Compiling remove_dir_all v0.5.3 Compiling arc-swap v1.3.0 Compiling ipnet v2.3.1 Compiling mime v0.3.16 Compiling uuid v0.8.2 Compiling strsim v0.8.0 Compiling vec_map v0.8.2 Compiling ansi_term v0.11.0 Compiling instant v0.1.10 Compiling tokio v1.8.1 Compiling futures-macro v0.3.15 Compiling futures-util v0.3.15 Compiling indexmap v1.7.0 Compiling num-traits v0.2.14 Compiling miniz_oxide v0.4.4 Compiling memoffset v0.6.4 Compiling num-integer v0.1.44 Compiling ring v0.16.20 Compiling tracing-core v0.1.18 Compiling unicode-bidi v0.3.5 Compiling http v0.2.4 Compiling pest v2.1.3 Compiling tinyvec v1.2.0 Compiling bcder v0.6.0 Compiling form_urlencoded v1.0.1 Compiling lock_api v0.4.4 Compiling error-chain v0.12.4 Compiling fxhash v0.2.1 Compiling textwrap v0.11.0 Compiling tracing v0.1.26 Compiling http-body v0.4.2 Compiling semver-parser v0.10.2 Compiling unicode-normalization v0.1.19 Compiling want v0.3.0 Compiling fern v0.6.0 Compiling log-reroute v0.1.7 Compiling mio v0.7.13 Compiling num_cpus v1.13.0 Compiling signal-hook-registry v1.4.0 Compiling getrandom v0.2.3 Compiling socket2 v0.4.0 Compiling time v0.1.43 Compiling parking_lot_core v0.8.3 Compiling dirs-sys v0.3.6 Compiling fs2 v0.4.3 Compiling atty v0.2.14 Compiling quote v1.0.9 Compiling quick-xml v0.22.0 Compiling semver v0.11.0 Compiling idna v0.2.3 Compiling nix v0.20.0 Compiling flate2 v1.0.20 Compiling rand_core v0.6.3 Compiling parking_lot v0.11.1 Compiling dirs v3.0.2 Compiling clap v2.33.3 Compiling rustc_version v0.3.3 Compiling url v2.2.2 Compiling webpki v0.21.4 Compiling sct v0.6.1 Compiling syslog v5.0.0 Compiling rand_chacha v0.3.1 Compiling sled v0.34.6 Compiling tokio-macros v1.3.0 Compiling thiserror-impl v1.0.26 Compiling routinator v0.9.0 Compiling webpki-roots v0.21.1 Compiling rustls v0.19.1 Compiling rand v0.8.4 Compiling thiserror v1.0.26 Compiling tempfile v3.2.0 Compiling tokio-util v0.6.7 Compiling tokio-rustls v0.22.0 Compiling async-compression v0.3.8 Compiling tokio-stream v0.1.7 Compiling futures-executor v0.3.15 Compiling chrono v0.4.19 Compiling serde_urlencoded v0.7.0 Compiling toml v0.5.8 Compiling tokio-socks v0.5.1 Compiling h2 v0.3.3 Compiling futures v0.3.15 Compiling rpki v0.11.1 Compiling hyper v0.14.10 Compiling hyper-rustls v0.22.1 Compiling reqwest v0.11.4 error[E0616]: field serial of struct NotificationFile is private --> /home/routinator/.cargo/registry/src/github.com-1ecc6299db9ec823/routinator-0.9.0/src/collector/rrdp.rs:711:51 711 self.metrics.serial = Some(notify.content.serial); ^^^^^^ private field

help: a method serial also exists, call it with parentheses | 711 | self.metrics.serial = Some(notify.content.serial()); | ^^

error[E0616]: field session_id of struct NotificationFile is private --> /home/routinator/.cargo/registry/src/github.com-1ecc6299db9ec823/routinator-0.9.0/src/collector/rrdp.rs:712:52 712 self.metrics.session = Some(notify.content.session_id); ^^^^^^^^^^ private field

help: a method session_id also exists, call it with parentheses | 712 | self.metrics.session = Some(notify.content.session_id()); | ^^

error[E0616]: field snapshot of struct NotificationFile is private --> /home/routinator/.cargo/registry/src/github.com-1ecc6299db9ec823/routinator-0.9.0/src/collector/rrdp.rs:755:54 755 self.rpki_notify, notify.content.snapshot.uri(), err ^^^^^^^^ private field

help: a method snapshot also exists, call it with parentheses | 755 | self.rpki_notify, notify.content.snapshot().uri(), err | ^^

error[E0616]: field snapshot of struct NotificationFile is private --> /home/routinator/.cargo/registry/src/github.com-1ecc6299db9ec823/routinator-0.9.0/src/collector/rrdp.rs:773:28 773 notify.content.snapshot.uri(), false ^^^^^^^^ private field

help: a method snapshot also exists, call it with parentheses | 773 | notify.content.snapshot().uri(), false | ^^

error[E0616]: field snapshot of struct NotificationFile is private --> /home/routinator/.cargo/registry/src/github.com-1ecc6299db9ec823/routinator-0.9.0/src/collector/rrdp.rs:792:28 792 notify.content.snapshot.hash().as_ref() ^^^^^^^^ private field

help: a method snapshot also exists, call it with parentheses | 792 | notify.content.snapshot().hash().as_ref() | ^^

error[E0616]: field session_id of struct NotificationFile is private --> /home/routinator/.cargo/registry/src/github.com-1ecc6299db9ec823/routinator-0.9.0/src/collector/rrdp.rs:890:19 890 if notify.session_id != state.session { ^^^^^^^^^^ private field

help: a method session_id also exists, call it with parentheses | 890 | if notify.session_id() != state.session { | ^^

error[E0616]: field serial of struct NotificationFile is private --> /home/routinator/.cargo/registry/src/github.com-1ecc6299db9ec823/routinator-0.9.0/src/collector/rrdp.rs:894:64 894 debug!("Serials: us {}, them {}", state.serial, notify.serial); ^^^^^^ private field

help: a method serial also exists, call it with parentheses | 894 | debug!("Serials: us {}, them {}", state.serial, notify.serial()); | ^^

error[E0616]: field serial of struct NotificationFile is private --> /home/routinator/.cargo/registry/src/github.com-1ecc6299db9ec823/routinator-0.9.0/src/collector/rrdp.rs:895:19 895 if notify.serial == state.serial { ^^^^^^ private field

help: a method serial also exists, call it with parentheses | 895 | if notify.serial() == state.serial { | ^^

error[E0616]: field deltas of struct NotificationFile is private --> /home/routinator/.cargo/registry/src/github.com-1ecc6299db9ec823/routinator-0.9.0/src/collector/rrdp.rs:903:19 903 if notify.deltas.last().map( delta delta.0) != Some(notify.serial) { ^^^^^^ private field

help: a method deltas also exists, call it with parentheses | 903 | if notify.deltas().last().map(|delta| delta.0) != Some(notify.serial) { | ^^

error[E0609]: no field 0 on type &DeltaInfo --> /home/routinator/.cargo/registry/src/github.com-1ecc6299db9ec823/routinator-0.9.0/src/collector/rrdp.rs:903:51 903 if notify.deltas.last().map( delta delta.0) != Some(notify.serial) { ^ unknown field

help: one of the expressions' fields has a field of the same name | 903 | if notify.deltas.last().map(|delta| delta.uri_and_hash.hash.0) != Some(notify.serial) { | ^^^^^^^^^^^^^^^^^^

error[E0616]: field serial of struct NotificationFile is private --> /home/routinator/.cargo/registry/src/github.com-1ecc6299db9ec823/routinator-0.9.0/src/collector/rrdp.rs:903:69 903 if notify.deltas.last().map( delta delta.0) != Some(notify.serial) { ^^^^^^ private field

help: a method serial also exists, call it with parentheses | 903 | if notify.deltas.last().map(|delta| delta.0) != Some(notify.serial()) { | ^^

error[E0616]: field deltas of struct NotificationFile is private --> /home/routinator/.cargo/registry/src/github.com-1ecc6299db9ec823/routinator-0.9.0/src/collector/rrdp.rs:908:33 908 let mut deltas = notify.deltas.as_slice(); ^^^^^^ private field

help: a method deltas also exists, call it with parentheses | 908 | let mut deltas = notify.deltas().as_slice(); | ^^

error[E0609]: no field 0 on type &DeltaInfo --> /home/routinator/.cargo/registry/src/github.com-1ecc6299db9ec823/routinator-0.9.0/src/collector/rrdp.rs:921:25 921 match first.0.cmp(&serial) { ^ unknown field

help: one of the expressions' fields has a field of the same name | 921 | match first.uri_and_hash.hash.0.cmp(&serial) { | ^^^^^^^^^^^^^^^^^^

error[E0609]: no field 0 on type &DeltaInfo --> /home/routinator/.cargo/registry/src/github.com-1ecc6299db9ec823/routinator-0.9.0/src/collector/rrdp.rs:923:65 923 debug!("First delta is too new ({})", first.0); ^ unknown field

help: one of the expressions' fields has a field of the same name | 923 | debug!("First delta is too new ({})", first.uri_and_hash.hash.0); | ^^^^^^^^^^^^^^^^^^

error[E0308]: mismatched types --> /home/routinator/.cargo/registry/src/github.com-1ecc6299db9ec823/routinator-0.9.0/src/collector/rrdp.rs:930:12 930 Ok(deltas) ^^^^^^ expected tuple, found struct DeltaInfo
= note: expected reference `&[(u64, UriAndHash)]`
           found reference `&[DeltaInfo]`
error[E0616]: field session_id of struct NotificationFile is private --> /home/routinator/.cargo/registry/src/github.com-1ecc6299db9ec823/routinator-0.9.0/src/collector/rrdp.rs:986:28 986 notify.content.session_id, serial, tree, self.max_object_size, ^^^^^^^^^^ private field

help: a method session_id also exists, call it with parentheses | 986 | notify.content.session_id(), serial, tree, self.max_object_size, | ^^

error[E0616]: field deltas of struct NotificationFile is private --> /home/routinator/.cargo/registry/src/github.com-1ecc6299db9ec823/routinator-0.9.0/src/collector/rrdp.rs:1437:17 1437 content.deltas.sort_by_key( delta delta.0); ^^^^^^ private field

help: a method deltas also exists, call it with parentheses | 1437 | content.deltas().sort_by_key(|delta| delta.0); | ^^

error[E0609]: no field 0 on type &DeltaInfo --> /home/routinator/.cargo/registry/src/github.com-1ecc6299db9ec823/routinator-0.9.0/src/collector/rrdp.rs:1437:50 1437 content.deltas.sort_by_key( delta delta.0); ^ unknown field

help: one of the expressions' fields has a field of the same name | 1437 | content.deltas.sort_by_key(|delta| delta.uri_and_hash.hash.0); | ^^^^^^^^^^^^^^^^^^

error[E0616]: field session_id of struct NotificationFile is private --> /home/routinator/.cargo/registry/src/github.com-1ecc6299db9ec823/routinator-0.9.0/src/collector/rrdp.rs:1479:38 1479 if session_id != self.notify.session_id { ^^^^^^^^^^ private field

help: a method session_id also exists, call it with parentheses | 1479 | if session_id != self.notify.session_id() { | ^^

error[E0616]: field session_id of struct NotificationFile is private --> /home/routinator/.cargo/registry/src/github.com-1ecc6299db9ec823/routinator-0.9.0/src/collector/rrdp.rs:1481:39 1481 expected: self.notify.session_id, ^^^^^^^^^^ private field

help: a method session_id also exists, call it with parentheses | 1481 | expected: self.notify.session_id(), | ^^

error[E0616]: field serial of struct NotificationFile is private --> /home/routinator/.cargo/registry/src/github.com-1ecc6299db9ec823/routinator-0.9.0/src/collector/rrdp.rs:1485:34 1485 if serial != self.notify.serial { ^^^^^^ private field

help: a method serial also exists, call it with parentheses | 1485 | if serial != self.notify.serial() { | ^^

error[E0616]: field serial of struct NotificationFile is private --> /home/routinator/.cargo/registry/src/github.com-1ecc6299db9ec823/routinator-0.9.0/src/collector/rrdp.rs:1487:39 1487 expected: self.notify.serial, ^^^^^^ private field

help: a method serial also exists, call it with parentheses | 1487 | expected: self.notify.serial(), | ^^

error[E0616]: field session_id of struct NotificationFile is private --> /home/routinator/.cargo/registry/src/github.com-1ecc6299db9ec823/routinator-0.9.0/src/collector/rrdp.rs:1675:37 1675 session: notify.content.session_id, ^^^^^^^^^^ private field

help: a method session_id also exists, call it with parentheses | 1675 | session: notify.content.session_id(), | ^^

error[E0616]: field serial of struct NotificationFile is private --> /home/routinator/.cargo/registry/src/github.com-1ecc6299db9ec823/routinator-0.9.0/src/collector/rrdp.rs:1676:36 1676 serial: notify.content.serial, ^^^^^^ private field

help: a method serial also exists, call it with parentheses | 1676 | serial: notify.content.serial(), | ^^

error: aborting due to 24 previous errors

Some errors have detailed explanations: E0308, E0609, E0616. For more information about an error, try rustc --explain E0308. error: could not compile routinator

To learn more, run the command again with --verbose. warning: build failed, waiting for other jobs to finish... error: failed to compile routinator v0.9.0, intermediate artifacts can be found at /tmp/cargo-installdi3omQ

Caused by: build failed

partim commented 3 years ago

Looks like releasing rpki-rs 0.11.1 was a mistake and it should have been 0.12.0. I shall fix this today.

Meanwhile, you can make this work by using the --locked options when installing Routinator, i.e.:

cargo install --locked routinator

This will force cargo to use rpki-rs 0.11.0 and should work.

nullARC77 commented 3 years ago

Thank you issue is resolved.