{"action":"created","issue":{"url":"https://api.github.com/repos/rust-lang/rust/issues/17141","repository_url":"https://api.github.com/repos/rust-lang/rust","labels_url":"https://api.github.com/repos/rust-lang/rust/issues/17141/labels{/name}","comments_url":"https://api.github.com/repos/rust-lang/rust/issues/17141/comments","events_url":"https://api.github.com/repos/rust-lang/rust/issues/17141/events","html_url":"https://github.com/rust-lang/rust/issues/17141","id":42376380,"number":17141,"title":"Add a `-C no-gc-sections` option to rustc","user":{"login":"jansegre","id":729870,"avatar_url":"https://avatars.githubusercontent.com/u/729870?v=3","gravatar_id":"","url":"https://api.github.com/users/jansegre","html_url":"https://github.com/jansegre","followers_url":"https://api.github.com/users/jansegre/followers","following_url":"https://api.github.com/users/jansegre/following{/other_user}","gists_url":"https://api.github.com/users/jansegre/gists{/gist_id}","starred_url":"https://api.github.com/users/jansegre/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jansegre/subscriptions","organizations_url":"https://api.github.com/users/jansegre/orgs","repos_url":"https://api.github.com/users/jansegre/repos","events_url":"https://api.github.com/users/jansegre/events{/privacy}","received_events_url":"https://api.github.com/users/jansegre/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/rust-lang/rust/labels/A-frontend","name":"A-frontend","color":"d7e102"},{"url":"https://api.github.com/repos/rust-lang/rust/labels/I-enhancement","name":"I-enhancement","color":"e10c02"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2014-09-10T04:16:38Z","updated_at":"2016-04-04T15:07:39Z","closed_at":null,"body":"I have an issue when static linking to an external library on OS X 64-bit (in my case luajit) that is known to have problems when `-dead_strip` is passed to the linker due to some code being written in asm. A brief talk in the IRC lead to @cmr suggesting me to open this issue. The name `no-gc-sections` is for matching the gnu ld `--gc-sections` nomenclature.\r\n\r\nI'm keeping it brief I can give more details if requested.\r\nEdit: PS: I'm manually linking as temporary fix."},"comment":{"url":"https://api.github.com/repos/rust-lang/rust/issues/comments/205340823","html_url":"https://github.com/rust-lang/rust/issues/17141#issuecomment-205340823","issue_url":"https://api.github.com/repos/rust-lang/rust/issues/17141","id":205340823,"user":{"login":"pnkfelix","id":173127,"avatar_url":"https://avatars.githubusercontent.com/u/173127?v=3","gravatar_id":"","url":"https://api.github.com/users/pnkfelix","html_url":"https://github.com/pnkfelix","followers_url":"https://api.github.com/users/pnkfelix/followers","following_url":"https://api.github.com/users/pnkfelix/following{/other_user}","gists_url":"https://api.github.com/users/pnkfelix/gists{/gist_id}","starred_url":"https://api.github.com/users/pnkfelix/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pnkfelix/subscriptions","organizations_url":"https://api.github.com/users/pnkfelix/orgs","repos_url":"https://api.github.com/users/pnkfelix/repos","events_url":"https://api.github.com/users/pnkfelix/events{/privacy}","received_events_url":"https://api.github.com/users/pnkfelix/received_events","type":"User","site_admin":false},"created_at":"2016-04-04T15:07:39Z","updated_at":"2016-04-04T15:07:39Z","body":"`-C link-dead-code` covers this at this point, I think.  At least, the way its implemented is that it causes the compiler to stop including `--gc-sections` in its linker invocation."}}