Skip to content
This repository has been archived by the owner on Feb 25, 2019. It is now read-only.

Multiple definition with libring #1

Open
jbboehr opened this issue May 11, 2018 · 3 comments
Open

Multiple definition with libring #1

jbboehr opened this issue May 11, 2018 · 3 comments
Labels
bug Something isn't working

Comments

@jbboehr
Copy link

jbboehr commented May 11, 2018

I am using rust nightly 2018-04-29:

let
  defaultPkgs = import <nixpkgs> {};
  defaultRustChannel = defaultPkgs.rustChannelOf { date = "2018-04-29"; channel = "nightly"; };
  defaultRust = defaultRustChannel.rust;
  buildRustCrate = defaultPkgs.callPackage (import <nixpkgs/pkgs/build-support/rust/build-rust-crate.nix>) {
    rustc = defaultRust;
  };
in
  { pkgs ? defaultPkgs, rust ? defaultRust }:

  import ./Cargo.nix {
    pkgs = pkgs // {
        inherit buildRustCrate;
    };
  }

My current top-level dependencies:

├── bart v0.1.4
├── bart_derive v0.1.4
├── bcrypt v0.2.0
├── chrono v0.3.0
├── diesel v1.2.2
├── diesel_cli v1.2.0
├── dotenv v0.11.0
├── env_logger v0.5.9
├── error-chain v0.11.0 (*)
├── jsonwebtoken v2.0.3
├── lazy_static v1.0.0 (*)
├── lettre v0.8.2
├── lettre_email v0.8.2
├── log v0.4.1 (*)
├── maplit v1.0.1
├── multipart v0.14.2
├── openssl-sys v0.9.28 (*)
├── regex v0.2.10 (*)
├── reqwest v0.8.5
├── rocket v0.3.9
├── rocket_codegen v0.3.9
├── rocket_contrib v0.3.9
├── rusoto_core v0.32.0
├── rusoto_s3 v0.32.0
├── serde v1.0.43 (*)
├── serde_derive v1.0.43 (*)
├── serde_json v1.0.16 (*)
├── stripe-rust v0.4.5
├── syslog v3.3.0
├── tempdir v0.3.7 (*)
├── validator v0.6.3
└── validator_derive v0.6.5

Here is the relevant output: https://gist.github.com/jbboehr/dd72f354d1310ed223e326f100bfe7b6

@tazjin tazjin added the bug Something isn't working label May 11, 2018
@jbboehr
Copy link
Author

jbboehr commented May 17, 2018

I managed to create a (mostly) reduced example that breaks: https://github.com/jbboehr/carnix-ring-issue-demo

@jbboehr
Copy link
Author

jbboehr commented May 17, 2018

Possibly related: rwf2/Rocket#627

@jbboehr
Copy link
Author

jbboehr commented May 17, 2018

FWIW I don't think it's an issue with multiple versions. It kind of looks like it's being linked statically multiple times in dependent crates and then fails when those two are linked to the final result - at least I believe this is what would cause the error if it was straight C. I don't know enough about how rustc works to say for sure though.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants