ntex-rs / ntex

framework for composable networking services

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ntex 0.6.2 + ntex-mqtt 0.10.0 upgrade undefined reference to `ntex::server::builder::ServerBuilder::bind'

Antiarchitect opened this issue · comments

uname -a
Linux workstation 6.0.17-300.fc37.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Jan 4 15:58:35 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux
rustc --version
rustc 1.67.0 (fc594f156 2023-01-24)
= note: /usr/bin/ld: /home/andrey/PROJECTS/mqtt-proxy/target/debug/deps/mqtt_proxy-6d91ebff2fb423f9.4c3b5lnbp2a18qc9.rcgu.o: in function `mqtt_proxy::mqtt::server::run_internal::{{closure}}':
          /home/andrey/PROJECTS/ENAPTER/RUST/mqtt-proxy/src/mqtt/server.rs:407: undefined reference to ntex::server::builder::ServerBuilder::bind'
          /usr/bin/ld: /home/andrey/PROJECTS/mqtt-proxy/src/mqtt/server.rs:437: undefined reference to `ntex::server::builder::ServerBuilder::bind'
          /usr/bin/ld: /home/andrey/PROJECTS/mqtt-proxy/target/debug/deps/mqtt_proxy-6d91ebff2fb423f9: hidden symbol `_ZN4ntex6server7builder13ServerBuilder4bind17h5c41c6d84432f1d6E' isn't defined
          /usr/bin/ld: final link failed: bad value
          collect2: error: ld returned 1 exit status

this seems compiler problem. could you try to build it with “lto=off”

Tried both cargo build and cargo build --release with these settings in Cargo.toml:

[profile.dev]
lto = "off"

[profile.release]
codegen-units = 1
lto = "off"
panic = "abort"

and getting the exact same error. Did I turned off lto correctly?

try 1.65,1.66 rust version. and probably report it to rust

lets keep it open for now. if you create issue in rust repo could you reference this one

seems fixed in latest rustc