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

Environment variable to control crate-type #8275

Open
chinedufn opened this issue May 24, 2020 · 3 comments
Open

Environment variable to control crate-type #8275

chinedufn opened this issue May 24, 2020 · 3 comments
Labels
A-crate-types Area: crate-type declaration (lib, staticlib, dylib, cdylib, etc.) C-feature-request Category: proposal for a feature. Before PR, ping rust-lang/cargo if this is not `Feature accepted` S-triage Status: This issue is waiting on initial triage.

Comments

@chinedufn
Copy link

chinedufn commented May 24, 2020

Problem

I'd like to set crate-type using an environment variable but I can't seem to find a Cargo environment variable for it.

RUSTFLAGS="--crate-type=staticlib" gives me linking errors.

I'm trying to steer clear of RUSTFLAGS after some feedback that I received in rust-lang/rust#71848 so I didn't dive too deeply into trying to understand what was happening. Something to do with eh_personality

Background

Providing some background in case there's a better approach that I don't know about

I currently have the following two crates

game-server
game-server-staticlib

game-server-staticlib's Cargo.toml looks like this:

[lib]
crate-type = ["staticlib"]

And the crate simply exposes a couple methods from game-server.

I store libgame_server_staticlib.a files in S3 because one of my integration test crates needs to be able to run against older versions of the game server.

This worked fine for a year or so - but after upgrading to a recent nightly

$ rustc -V
rustc 1.45.0-nightly (2454a68cf 2020-05-04)

my approach works on MacOS but on linux I get some sort of error with rust_eh_personality

Error error: linking with `cc` failed: exit code: 1 | = note: "cc" "-Wl,--as-needed" "-Wl,-z,noexecstack" "-m64" "-L" "/usr/local/rustup/toolchains/nightly-2020-05-04-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.10jford2ly9z7wz3.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.11on0iqpic84bxms.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.12actkze4sun26r6.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.14gab0v4a2mhqkz4.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.15v2x3g8oqiparvv.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.169o2xctfq7ac5js.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.17y2yodpq7m5txve.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.17ze57xme95lavso.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.188ba8ovb2y5jvp2.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.18peansei6nk4a9p.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.18xn6q0xb3goi503.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.19ecjnnlvi3bumft.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.1c7xptfosq5kyoxc.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.1cbww0qq8521m9ci.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.1cvsxqmgz5ux5665.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.1efyf23x4gy18x8e.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.1fhf5zp96xr0shps.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.1g8nd77mxe48ozx5.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.1hvzjhhacmqi7yjx.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.1jvzrw63pfx7if1n.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.1mrd26o6hyuh5gnh.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.1pbci4qlnh8smdhw.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.1qbqz5z1v2ig0e2g.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.1rhz6p0dqvxxwdve.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.1t9n8lvh33dcevlf.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.1tmretp6baje9m8r.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.1ua295w59btp562l.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.1w300feh4a0wuu1g.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.1xigq91m9nelcb6j.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.1y8xd6aqndlvu3g5.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.1ygzkjsolsfzyb4e.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.1ymk7rswoaoll9tq.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.1z12cbdo4u9efuzj.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.1z89rxxcxhjpbr8g.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.1za8tjw44x0tb9ok.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.1zrzvan7oc5awcyc.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.20j6gwb7ysn4dn1e.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.21fue5xe8risb81g.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.231hlsp2v5nycx8o.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.23dm5sixm93yfait.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.23nr3skhlqy87w2c.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.24sjip3f2q749iw5.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.26thls12yl0b29gh.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.27mlaz28scsohm5q.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.29ccogs6riibbkzi.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.2ber2qk9bxz8z8t4.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.2cqyhh8j1xbmvc7a.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.2homd106wcxi3drm.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.2nwzrqxcbc58ec2y.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.2o1fec81trsbaqt8.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.2oi7a2mxab74rrz5.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.2qe74uf6k6vn1y8v.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.2s9dsnkx0x1p73gn.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.2vfzwx5rjbcf3cmm.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.2vtzt6nyl3iz2yzv.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.2w3qfv81y9g3thej.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.2ynf0c80bd2khz92.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.2yvhw2akaa0tnqfx.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.30h6vfbph63wb566.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.30wywbemz06g8357.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.3186q9hluhgs8avr.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.31k8op4vex4pnku2.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.32gf7b864ignmcu9.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.32n49n0jq735q6zj.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.34tq29ss3u1ls0t5.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.3554kssszdogbqlp.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.35zdbqmem6bd6pag.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.3909d5p4m3oa0c6g.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.39ru8vfglgshdizn.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.3h7ifon2juwkodx3.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.3hvlg0cmksj8xx7a.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.3i3mjbwu2oymlnk2.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.3kwj16wy8y6jbsao.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.3macd6h8dp872x2f.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.3nvqozs540yqg3qj.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.3o5vhdtoit89c9q2.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.3op30pw6gl4shviu.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.3p1484ty11u0zkz6.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.3pt0gviqnyimvqer.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.3rpm91x4vgrmefn4.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.3rwmpynutxowmk45.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.3sxxe7mk1lfta2vp.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.3uvhmv5o5fica0zm.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.3vhpvp5y8wrjcefs.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.3w8a0r0ha8tg81rb.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.3waxb1ojgq2461oj.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.3xj0xehqq1mxxnv8.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.3ycvcjujf71bmob3.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.40hwi8040dn1pryr.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.41g6sux4pxyl6gpf.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.41ucdmyg5cg141yc.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.42h4ci4s6era74q3.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.44y4efoxqk6a110s.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.47sx7j8qnpys0lcv.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.4akjo3yehxh2fe2u.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.4f3l9mj1slvblmn8.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.4fd0e3ncw5p1wjth.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.4gptdyohf0l7ylj6.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.4grmn99mx3damvu3.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.4h170czk0w58ulhc.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.4jcn363d0tox3116.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.4qm3blyb5egulm5z.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.4u635ayz5b0kqr1x.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.4uiq0spvm34fh0l9.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.4y7wrwmxabxuai4u.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.4z7vsen1jdgej0uo.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.507peq9uyxsctc7l.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.51j2pdcngap0jpux.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.51o6u0kuqllu8xdm.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.51owjjmxdwj2tjgr.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.52cyzimacsyzq378.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.54fu2edzp50hp41w.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.550p1cw4cv1qu62n.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.55key2rhustduycf.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.5al8vwcwl2yvufo5.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.5am5kmbelybbtsg3.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.5av4chnkmu1uh7sj.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.5d13l4swavfl8gmn.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.5dcdxmqp0horyyvn.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.5dp5civc6tylnyfv.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.5fdh7r1cslh9mesb.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.7dmlabez9hnj5pf.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.96fb4snjjblb2n8.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.dksbvjb5bxco1ss.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.epyo5bdni4snhhl.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.gvgmc66zystvt5g.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.gw9aayus4lt1hga.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.h48sd6k7iri78x7.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.hrcw4pz1n5nqe8s.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.k4duxegwtd4td71.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.knrlmpy9hpnyipr.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.m3w756vadefqs2b.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.mwcv8ijp0lkwhov.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.oiqds595e75mvdq.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.rv6ruimw3yigor8.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.wwhtp2mi2fnk3rb.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.x7uiu0z3p7sof7o.rcgu.o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.xpx2869h96dzw9x.rcgu.o" "-o" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/game_server_integration_tests-5442e60183de484d.42hht793ubhxz00h.rcgu.o" "-Wl,--gc-sections" "-pie" "-Wl,-zrelro" "-Wl,-znow" "-nodefaultlibs" "-L" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps" "-L" "/root/repo/target/debug/deps" "-L" "/tmp" "-L" "/root/repo/target/x86_64-unknown-linux-gnu/debug/build/ring-a9802cdd4b5ce297/out" "-L" "/root/repo/target/x86_64-unknown-linux-gnu/debug/build/backtrace-sys-eb089ad7d6791e33/out" "-L" "/root/repo/target/x86_64-unknown-linux-gnu/debug/build/bzip2-sys-56135c4c51859ff6/out/lib" "-L" "/usr/local/rustup/toolchains/nightly-2020-05-04-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib" "-lgs_static" "-Wl,-Bstatic" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libanyhow-3a4c95e209387ad2.rlib" "/usr/local/rustup/toolchains/nightly-2020-05-04-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libtest-446ee400e11d3b7f.rlib" "/usr/local/rustup/toolchains/nightly-2020-05-04-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libterm-11bb62e30416837f.rlib" "/usr/local/rustup/toolchains/nightly-2020-05-04-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libgetopts-eab4fc102c5fc659.rlib" "/usr/local/rustup/toolchains/nightly-2020-05-04-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libunicode_width-1b0f5a508f74b5c5.rlib" "/usr/local/rustup/toolchains/nightly-2020-05-04-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/librustc_std_workspace_std-efd911910f7e26e3.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libgame_server_deploy_manager_protocol-49a08dea142856a8.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libgame_server-f39237e271341deb.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libslog_async-9cb9a65b48a0a742.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libcrossbeam_channel-ebc8230021ed879a.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libcrossbeam_utils-47b63812aaac4657.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libtake_mut-e705f27e9289cbe0.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libthread_local-5178754a27bf22e6.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libslog_json-2782cc909ed97eea.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libhostname-5b410c71b25eb1b4.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libmatch_cfg-8250dd44ba80ae5c.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libserde_yaml-c88cf79a280bf355.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libdtoa-4187bd95a23d7004.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libyaml_rust-a8ebd288461066e5.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/liblinked_hash_map-e0ae5968553c8de0.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libwebsocket-60e84f8f51fd5ed4.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libtokio_tls-9fbcf8a7eb48b860.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libtokio_tcp-12adb18d2f7388c6.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libtokio_reactor-9efe32cc0f9953ce.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libtokio_sync-7d6a90195014c741.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libfnv-1a157dae6b39e16e.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libtokio_executor-aff8357daa00d832.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libparking_lot-08ed84bae204c25e.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libparking_lot_core-efb7f3ce356e622f.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libsmallvec-672690138ab919af.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libtokio_codec-731f09f118d32f33.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libtokio_io-a37cc0edf9639178.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/librand-7224129fab7e94da.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/librand_xorshift-480b605c7bdfc576.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/librand_pcg-6040ba3e366531a7.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/librand_hc-f71dcc10174d6b7b.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/librand_chacha-ce0e89fd51e4a5b1.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/librand_isaac-d233c5ca2e7cdd3e.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/librand_os-f6c02c089ff65834.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/librand_jitter-6bda7518ae3ac9dc.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libnative_tls-920160eddcc899a5.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libopenssl_probe-40267baecdb7b5f0.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libopenssl-50cf7a09bb573eb2.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libopenssl_sys-628a0f827a185608.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libforeign_types-fb0543883542a33c.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libforeign_types_shared-934583fe75515edc.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libbitflags-68c0f5dd9f56f870.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libhyper-f000ab31e848cf76.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libmime-fd89344fb5556bbf.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/liblog-013f44c4a4a9b5c9.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/liblanguage_tags-66a2bfe3cf7f3a01.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libtypeable-00ec39347dec99f0.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libtraitobject-4fc9a4bc6c76679f.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libunicase-d702935400e143bd.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libfutures-eebbe55c9ecdc398.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libbase64-ac21a05fa3061a8d.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libauthorization-b238a8095c522d39.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libjsonwebtoken-0027f7400b349474.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libring-78c594340c12b4ea.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libuntrusted-2cc14c23599c8a17.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libbase64-a6bbc8818547e35a.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libsafemem-9c18e4bcf9ef6d58.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libserde_json-b99329240b6b109c.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libryu-b3aa9ce38a9e02f8.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libitoa-f4bfd82581e5e7c6.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libws-675fad44aaa9005e.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/liburl-a207e8fa5e86538e.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libpercent_encoding-4cf89a09e09c9323.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libidna-f6b89bf4b4fea8be.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libsha1-ddbcf5b2d6333758.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/librand-77c43dd765e8f883.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libmio_extras-2a2bea29659224e8.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/liblazycell-ad25777befa881b2.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libhttparse-29364979bfaee5e8.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libbytes-8e0f5cc6eeb95657.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libtempfile-7a5ad0bbc71c32fe.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libremove_dir_all-06a4b46f7f9c9fe5.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libautonomous_client-21128948918bf335.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libthreadpool-a4e087da1b9dc4ce.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libdatabase-dd8bafe0fa49cd9d.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libr2d2_postgres-5c81668ac3fa23dd.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libr2d2-f45aa51ae932b02e.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libscheduled_thread_pool-9d9c5167071cc43e.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libcrossbeam_channel-e88f90e85a052644.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libsnafu-48c78e060e5ffe90.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libdoc_comment-19641e766a8c56f0.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libslog-460aedc6d1e651ba.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/liberased_serde-c65cdc7fec734fa6.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libclient_server_common-b723d758b690e837.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libclient_server_common_backend-7df5566de4ccbb20.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libbincode-f10cdedc09ee535d.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libthiserror-f565638ddcf75bb8.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libpathfinding-4d9f712e5d0e113a.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libitertools-b25379658a838d2c.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libindexmap-4f3a1b26e1149cb2.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libfixedbitset-4ac1bf18ace0c984.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libnalgebra-247268aca63d43d6.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libalga-908c95112a09ac46.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/librand-ece035b985bdfcee.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/librand_core-ff87bdf38ac19106.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/librand_core-9bb71a5aeecfcbc7.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libnum_complex-ce602e08ab74e262.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libmatrixmultiply-303c372f1787dd71.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/librawpointer-fa79bbccc3707222.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libgeneric_array-e2f9f5ff4f35933e.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libapprox-75a814e7cc628076.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libspecs-805b67c5535779bb.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libtuple_utils-5697bd5aa13aad29.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libshrev-64f339a719a17cbc.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libshred-a1ff258d5eec479b.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libtynm-d81775989df374b5.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libnom-03bacd161af63a9f.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libmopa-3c80fa94839b1632.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libhashbrown-46ba7f1dc0c8d67a.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libahash-2a374e0472182275.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libconst_random-e2c1c5bb68032045.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libhibitset-ed123bb9f82d541f.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/librayon-39587b4c8899f29f.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/librayon_core-7cea476eb6bfce61.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libnum_cpus-e8f20e0f710893fd.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libcrossbeam_queue-17a44452bd1ce585.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libcrossbeam_deque-5a65e12af906af22.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libcrossbeam_epoch-046ae5635a8e6351.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libmemoffset-d49eca6eb72ee63c.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libcrossbeam_utils-b3e9ca04831fb2e2.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/liblazy_static-688f89f5881ef751.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libmaybe_uninit-58860a6b02a1841e.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libeither-fdc8213c125ee2a9.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libatom-6f5d0bf5d446126b.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libpostgres-ed79cfea16399d5f.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libtokio_postgres-7d8f9f00110b7237.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libphf-7e8441393162e89f.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libphf_shared-854c8931b2803b72.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libsiphasher-d026f5b993b524b0.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libpercent_encoding-88733da60a826127.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libtokio_util-850b72a2ecb5a6f7.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libparking_lot-58eb67e8460f03a2.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libparking_lot_core-24cbdcd942acb8e1.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/liblock_api-13f2df622e20bf15.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libscopeguard-76dbbde7be582500.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libtokio-f5189b7441833f5d.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libmio_uds-56a01fd7e0c089f4.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libmio-18ae4d550bf1bc30.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/liblog-9fa35f991c4d8560.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libiovec-df3802f4c3f43a05.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libnet2-33429ee537d9f251.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libpin_project_lite-6036da31bce523f1.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libfutures-6cbf9782da5c513e.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libfutures_executor-bd568f2a70d67f62.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libfutures_util-d163c9ba6bd3bdc8.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libproc_macro_nested-766e18cf758e8100.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libfutures_io-c46230a8809462a8.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libslab-fdf286e72b391afb.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libfutures_channel-17edb32b49f1f997.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libfutures_sink-2677e8ceac293f42.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libfutures_task-27155d0cbe6c9556.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libpin_utils-d0609f559f13fccd.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libfutures_core-96978eb91a419885.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libpostgres_types-664f502d2c41beeb.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libgeo_types-24ac4eb39e4d06af.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libchrono-a3fd673c1f7b51f0.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libnum_integer-2ccb6f8befe69fe3.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libtime-3b89b8540d39048c.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libpostgres_protocol-cf1dae9b13d4c707.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libbase64-7b18dbd201bd9429.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libstringprep-51a72957a68fc063.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libunicode_normalization-423669213ebef893.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libsmallvec-ed7bd557ec6618cd.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libunicode_bidi-eed7524f46ff7842.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libmatches-95fd42ab7b883f5c.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libmemchr-89e8c7abc069f5af.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libsha2-5257351a2a8a7d83.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libopaque_debug-35dc812873428341.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libfake_simd-38a2304294c35834.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libblock_buffer-dcf483e755f6e761.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libblock_padding-240895627a111a94.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libbyte_tools-c30b147f483f38a3.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/librand-a3e3f35dfb4e2c44.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/librand_chacha-bb7ed842fcfa6b68.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libppv_lite86-e71bba93886cdf39.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/librand_core-e44f0000e7355b23.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libgetrandom-6631794048e1f633.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libhmac-84f101d47e66a944.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libcrypto_mac-84338654a2d6df15.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libsubtle-450ffbf04d6d3d20.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libdigest-c9153c8e2d1f6171.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libgeneric_array-08ba5976eb265e4d.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libgeneric_array-9af119db5bec7e58.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libtypenum-cfa16a856880c417.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libmd5-5a7c85d4bf95e36c.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libbytes-9165e0b10125f943.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libbyteorder-00089c8de58c3ffa.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libfallible_iterator-7aef45a8adc10930.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libarrayvec-70ee95d3358f1c50.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libfailure-a5f3b9a5208a2fc7.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libbacktrace-783cd7d4026a0e68.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libbacktrace_sys-9a88ebfbb713cf9b.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/liblibc-d1fd54c09e13fcda.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libcfg_if-34bffe71ea1ea8e8.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/librustc_demangle-da13b72f2acca233.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libassets-f3e50463c00e7a32.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libnum_traits-db36e310008d10f7.rlib" "/root/repo/target/x86_64-unknown-linux-gnu/debug/deps/libserde-5ea5a404c6d398b1.rlib" "-Wl,--start-group" "/usr/local/rustup/toolchains/nightly-2020-05-04-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libstd-7d65a344221c409b.rlib" "/usr/local/rustup/toolchains/nightly-2020-05-04-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libpanic_unwind-54df1a0c3024f5bd.rlib" "/usr/local/rustup/toolchains/nightly-2020-05-04-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libhashbrown-bb312de2a5d7d307.rlib" "/usr/local/rustup/toolchains/nightly-2020-05-04-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/librustc_std_workspace_alloc-60c21d234379de22.rlib" "/usr/local/rustup/toolchains/nightly-2020-05-04-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libbacktrace-045480d965da2c45.rlib" "/usr/local/rustup/toolchains/nightly-2020-05-04-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libbacktrace_sys-8ec1303a38498da9.rlib" "/usr/local/rustup/toolchains/nightly-2020-05-04-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/librustc_demangle-18658537df359212.rlib" "/usr/local/rustup/toolchains/nightly-2020-05-04-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libunwind-b87be9f0e57bd4bf.rlib" "/usr/local/rustup/toolchains/nightly-2020-05-04-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libcfg_if-3a677d13d4ec517d.rlib" "/usr/local/rustup/toolchains/nightly-2020-05-04-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/liblibc-ac41f78688451395.rlib" "/usr/local/rustup/toolchains/nightly-2020-05-04-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/liballoc-f11f1597d535049a.rlib" "/usr/local/rustup/toolchains/nightly-2020-05-04-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/librustc_std_workspace_core-428d15b56101bdc7.rlib" "/usr/local/rustup/toolchains/nightly-2020-05-04-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libcore-941f7f6bc622e313.rlib" "-Wl,--end-group" "/usr/local/rustup/toolchains/nightly-2020-05-04-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libcompiler_builtins-e77b8f5da9460407.rlib" "-Wl,-Bdynamic" "-lssl" "-lcrypto" "-lutil" "-ldl" "-lutil" "-ldl" "-lrt" "-lpthread" "-lgcc_s" "-lc" "-lm" "-lrt" "-lpthread" "-lutil" "-ldl" "-lutil" = note: /usr/local/rustup/toolchains/nightly-2020-05-04-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libpanic_unwind-54df1a0c3024f5bd.rlib(panic_unwind-54df1a0c3024f5bd.panic_unwind.c58ezz8a-cgu.0.rcgu.o): In function `rust_eh_personality': /rustc/65b448273dd280401cd440a6740a7cd891525ba3//src/libpanic_unwind/gcc.rs:279: multiple definition of `rust_eh_personality' /tmp/libgs_static.a(game_server_staticlib-4343e9cb01b9c8ef.game_server_staticlib.aub4ljy0-cgu.1.rcgu.o):/rustc/dd67187965e136bff1ed05e035293441c60f0790//src/libpanic_unwind/gcc.rs:281: first defined here collect2: error: ld returned 1 exit status

Today I realized that I don't need a wrapper crate and can just add crate-type=['rlib', 'staticlib'] to the game-server crate, ditching the game-server-staticlib entirely.

This compiles just fine - but I don't want to add that to the Cargo.toml because it looks like it increases the compilation time of debug builds (after editing and saving a file and then compiling) by around 10 seconds (I'm assuming because the static lib is around 500mb).

Instead I want a way to programatically enable the staticlib crate type (i.e. an environment variable such as CARGO_PROFILE_CRATE_TYPE=staticlib.

Hence this issue!


Let me know if I'm missing any relevant info. Cheers!

@chinedufn chinedufn added the C-feature-request Category: proposal for a feature. Before PR, ping rust-lang/cargo if this is not `Feature accepted` label May 24, 2020
@joshtriplett
Copy link
Member

I do think it makes sense to have a way to say "I can build dynamic and static libraries", and give the builder of the crate control of which one(s) get built. I don't think this should be a fully general "provide the crate type through the environment" mechanism, but I think it makes sense to have a static/dynamic/both option for crates that can build both. This is common in C libraries, and should be possible in Rust as well.

That said, is rlib and staticlib the combination you actually want? rlib is a Rust-specific static library, and staticlib is a C-compatible static library. Does your crate export a C-compatible interface (in which case you might want cdylib and staticlib), or does it provide a Rust-compatible interface (in which case you might want dylib and rlib), or does it do some combination of both?

Short-term, if nobody else uses the static library, and you only use it for your testing, then as a workaround, could you just have CI sed the crate-type line and re-build the crate?

@chinedufn
Copy link
Author

chinedufn commented May 25, 2020

Thanks for the thoughts!

So my first introduction to linking was when I set this up maybe a year ago.

That is to say that the odds that I'm approaching things incorrectly are high.

The reason that I originally went with a staticlib was for no other reason that at the time the static library was smaller than the dynamic one. Which made no sense to me but I rolled with.

Granted it's totally possible that I simply misread the numbers at the time - especially since as I check now the dynamic library is much smaller (as expected).

It's also possible that I didn't misread the numbers and that for whatever reason there are some cases where a dynamic library can be larger than the static equivalent. Beats me.

$ ls -l target/x86_64-unknown-linux-gnu/release/libgame_server.*
-rw-r--r--  2 chinedufn  staff  48051392 May 25 15:23 target/x86_64-unknown-linux-gnu/release/libgame_server.a
-rw-r--r--  1 chinedufn  staff     18799 May 25 15:25 target/x86_64-unknown-linux-gnu/release/libgame_server.d
-rw-r--r--  2 chinedufn  staff  18372000 May 25 15:23 target/x86_64-unknown-linux-gnu/release/libgame_server.rlib
-rwxr-xr-x  2 chinedufn  staff  19100936 May 25 15:24 target/x86_64-unknown-linux-gnu/release/libgame_server.so

When I link to it I say that it's a dylib though. Since that worked when I first set it up I never changed it or investigated further into why that even works.

// This is really a staticlib even though I'm calling it a dylib.
println!("cargo:rustc-link-lib=dylib={}", lib_name);
println!("cargo:rustc-link-search={}", dir);

Ah sorry for not including that context.

My only requirement is

  • Be able to call a Rust function from a compiled Rust library file

So - no C-compatibility needed in any way. I only need access to a Rust interface.


Cool I'll try using dynamic libs going forwards for this.


The case that I need to download and test against older binaries on my own machine (not just CI) - so the stopgap that you mentioned does work totally fine.

Of course I'd like to do it "the right way" if we can figure something out thought!


do think it makes sense to have a way to say "I can build dynamic and static libraries", and give the builder of the crate control of which one(s) get built

Can you give an example of, say, the potential environment variable key/value for configuring a crate to be both an rlib and cdylib using this approach?

Just so that I can better visualize what you're suggesting here.

Thanks!

@chinedufn
Copy link
Author

@joshtriplett I'm happy to submit a PR for this if we can nail down the desired env vars.

@ehuss ehuss added the A-crate-types Area: crate-type declaration (lib, staticlib, dylib, cdylib, etc.) label Jun 25, 2020
@epage epage added the S-triage Status: This issue is waiting on initial triage. label Nov 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-crate-types Area: crate-type declaration (lib, staticlib, dylib, cdylib, etc.) C-feature-request Category: proposal for a feature. Before PR, ping rust-lang/cargo if this is not `Feature accepted` S-triage Status: This issue is waiting on initial triage.
Projects
None yet
Development

No branches or pull requests

4 participants