aboutsummaryrefslogtreecommitdiffstats
path: root/testing
diff options
context:
space:
mode:
authorShiz <hi@shiz.me>2017-04-14 00:30:25 +0000
committerJakub Jirutka <jakub@jirutka.cz>2017-04-14 17:59:37 +0200
commit2ebf583060c9dfe3cf1df21e97e8d8d6e017ac22 (patch)
tree3edebc1af1ee3cbf7eb04ec799e0292b04de77f1 /testing
parenta551ebb6babcbfe010095f14618a5ea4e67e9ec5 (diff)
downloadaports-2ebf583060c9dfe3cf1df21e97e8d8d6e017ac22.tar.bz2
aports-2ebf583060c9dfe3cf1df21e97e8d8d6e017ac22.tar.xz
testing/rust: fix dylib creation when crt-static is enabled
Diffstat (limited to 'testing')
-rw-r--r--testing/rust/APKBUILD4
-rw-r--r--testing/rust/static-pie.patch13
2 files changed, 15 insertions, 2 deletions
diff --git a/testing/rust/APKBUILD b/testing/rust/APKBUILD
index bf64d6d8c8..3dc03e7aba 100644
--- a/testing/rust/APKBUILD
+++ b/testing/rust/APKBUILD
@@ -6,7 +6,7 @@ pkgver=1.16.0
# Git revision of prebuilt Cargo to use for bootstrapping, from src/stage0.txt.
_cargo_gitrev=6e0c18cccc8b0c06fba8a8d76486f81a792fb420
_llvmver=3.9
-pkgrel=3
+pkgrel=4
pkgdesc="The Rust Programming Language (compiler)"
url="http://www.rust-lang.org"
arch="x86_64"
@@ -187,7 +187,7 @@ e9b10d58ae5b51b09dd31a1dbf7367917bd40a05ecb4ba3e0e7ac229a0352d3ceb77de80f7c0120f
2002faf08cca3be702f25618bc17453c5e76644a6ff6b0739b642c2c0f8536ec7f09c98182aff6b2dcc87c77b0929f2f8f732b8242a8f80d94b3824c8cd0d0fe dont-require-filecheck.patch
b0a8883e4469b60edd150c84486ab950396d757220f97bd271529576614c6c3b49456098507503832c20619d4bd74246dbc99c78116634a68a6df994793e9a94 support-dynamically-linked-musl.patch
b00997c65d1a451fafae8b547893c5cbf03f028d2d70f6971aa670f34c2d6fc82728c740ac4a9909fc1999925ff300e4525cfec745cb9c9521e564eb166872a2 allow-crt-static-on-stable.patch
-79d7eb79bb5219beab2fa8394e30b830275ce3062fd7c02077229ad1fdca492f55d321e0bc1015f62252fe4df3cc41c5168ff9d2e848ae06b14f807add7e193a static-pie.patch
+81fe34aa8e2edacacef63c6a0105da05205b86ae76535f8f9359607f10f6de96c48dc8e160cc8f96dc4a4291f1172290cb11ea5993eba023eb393d8fad6fe0c7 static-pie.patch
f436fddf7ab70ca5f1424081f5b75450270b200b3d997231323863e11addf76e1d65831a7ca09e3a5b7904ce828766c1f70b08326a175890298f28e5bc8646ef fix-linux_musl_base.patch
44f3104f506531778fede64034ff5b86f782744d7fed26b393cd88590c22b7fd1df441e2c14bb44c660c54140a4093686aa35f53357f9cd795af6cfa6df1cec4 musl-dynamic-linking-by-default.patch
37416e1fa0bc0c8651cd060a645d6245ff7e2082279ab5e13495c5ee412c71915469019cfbec95a0fd9a7fc144475079a3ad16f0eba7a2f5c8dd99e0002f3225 llvm-with-ffi.patch
diff --git a/testing/rust/static-pie.patch b/testing/rust/static-pie.patch
index 5ae091f691..8ac8a76653 100644
--- a/testing/rust/static-pie.patch
+++ b/testing/rust/static-pie.patch
@@ -215,3 +215,16 @@ library, just like static binaries, but more secure.
}
}
+--- a/src/librustc_trans/back/link.rs
++++ b/src/librustc_trans/back/link.rs
+@@ -239,8 +239,8 @@
+ /// Checks if target supports crate_type as output
+ pub fn invalid_output_for_target(sess: &Session,
+ crate_type: config::CrateType) -> bool {
+- match (sess.target.target.options.dynamic_linking,
+- sess.target.target.options.executables, crate_type) {
++ let dynamic_linking = sess.target.target.options.dynamic_linking && !sess.crt_static();
++ match (dynamic_linking, sess.target.target.options.executables, crate_type) {
+ (false, _, config::CrateTypeCdylib) |
+ (false, _, config::CrateTypeProcMacro) |
+ (false, _, config::CrateTypeDylib) => true,