When I builds =dev-lang/rust-1.23.0 with "doc" enabled I gets error: < Rustc { stage: 2, target: "x86_64-unknown-linux-gnu", host: "x86_64-unknown-linux-gnu" } Build completed successfully in 0:04:28 mv: cannot stat '/tmp/portage/dev-lang/rust-1.23.0/image//usr/share/doc/rust/*': No such file or directory As I see the documentation is already placed in ${D}/usr/share/doc/rust-1.23.0/ so it shouldn't be moved. I deleted lines from ebuild and dev-lang/rust-1.23.0 installed correctly.
Thanks for the report! What lines did you remove, exactly? If you can provide a unified diff, that would be helpful.
I removed next lines from src_install: if use doc ; then dodir "/usr/share/doc/rust-${PV}/" mv "${D}/usr/share/doc/rust"/* "${D}/usr/share/doc/rust-${PV}/" || die rmdir "${D}/usr/share/doc/rust/" || die fi
I have the same issue.
Created attachment 516534 [details] build.log.gz
Created attachment 516536 [details] usr/lib64/rustlib/install.log written by Rust build system
Same here :) After the build has failed, image/usr/share/doc/rust-1.23.0 contains a few README/LICENSE/COPYRIGHT files and an "html" directory containing 123M of documentation. So it looks like Rust's build system already put the documentation where we want it, and comment #2 has it right (that part of src_install breaks everyone with USE=doc set). I suspect this happens because src_configure adds the following lines to config.toml: docs = $(toml_usex doc) docdir = "share/doc/${P}" ...and those are all we need to install documentation to the correct directory and make USE=doc work. Also note the docdir looks new to this ebuild (rust-1.19.0.ebuild set a different one).
(In reply to Oleg from comment #2) > I removed next lines from src_install: > > if use doc ; then > dodir "/usr/share/doc/rust-${PV}/" > mv "${D}/usr/share/doc/rust"/* > "${D}/usr/share/doc/rust-${PV}/" || die > rmdir "${D}/usr/share/doc/rust/" || die > fi I confirm that removing these lines resolves the problem
I've removed the offending lines from rust-1.23.0-r1, thanks!