Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 645562 - dev-lang/rust-1.23.0[extended] with dev-util/cargo-0.24.0 - file collision in /usr/share/zsh/site-functions/_cargo /usr/bin/cargo
Summary: dev-lang/rust-1.23.0[extended] with dev-util/cargo-0.24.0 - file collision in...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Gentoo Rust Project
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-01-24 15:15 UTC by Attila Tóth
Modified: 2018-08-11 11:40 UTC (History)
7 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Attila Tóth 2018-01-24 15:15:46 UTC
* Detected file collision(s):
 *
 *      /usr/share/zsh/site-functions/_cargo
 *      /usr/bin/cargo
 *
 * Searching all installed packages for file collisions...
 *
 * Press Ctrl-C to Stop
 *
 * dev-util/cargo-0.24.0:0::gentoo
 *      /usr/bin/cargo
 *      /usr/share/zsh/site-functions/_cargo

The new dev-lang/rust-1.23.0 version provides its own Cargo. Two packages depends on Cargo: older rust-1.19.0 and firefox. Firefox ebuild should take into account that newer rust has Cargo, so that separate cargo package can be unmerged while upgrading to this new version.
Comment 1 Attila Tóth 2018-01-24 15:18:24 UTC
Sorry but I have to realize, I'm talking about the rust overlay ebuild, not the one in the tree...
Comment 2 Attila Tóth 2018-01-24 15:33:32 UTC
(In reply to Attila Tóth from comment #1)
> Sorry but I have to realize, I'm talking about the rust overlay ebuild, not
> the one in the tree...

And rust overlay's and the tree differs in this regards...
Comment 3 Vasilis Lourdas 2018-01-28 09:01:03 UTC
I get the same error with rust-1.23.0-r1, its files collide with dev-util/cargo-0.24:

>>> Installing (3 of 6) dev-lang/rust-1.23.0-r1::gentoo
 * checking 2098 files for package collisions
1098 files remaining ...
98 files remaining ...
 * This package will overwrite one or more files that may belong to other
 * packages (see list below). You can use a command such as `portageq
 * owners / <filename>` to identify the installed package that owns a
 * file. If portageq reports that only one package owns a file then do
 * NOT file a bug report. A bug report is only useful if it identifies at
 * least two or more packages that are known to install the same file(s).
 * If a collision occurs and you can not explain where the file came from
 * then you should simply ignore the collision since there is not enough
 * information to determine if a real problem exists. Please do NOT file
 * a bug report at https://bugs.gentoo.org/ unless you report exactly
 * which two packages install the same file(s). See
 * https://wiki.gentoo.org/wiki/Knowledge_Base:Blockers for tips on how
 * to solve the problem. And once again, please do NOT file a bug report
 * unless you have completely understood the above message.
 * 
 * Detected file collision(s):
 * 
 * 	/usr/share/zsh/site-functions/_cargo
 * 	/usr/bin/cargo
 * 
 * Searching all installed packages for file collisions...
 * 
 * Press Ctrl-C to Stop
 * 
 * dev-util/cargo-0.24.0:0::gentoo
 * 	/usr/bin/cargo
 * 	/usr/share/zsh/site-functions/_cargo
 * 
 * Package 'dev-lang/rust-1.23.0-r1' NOT merged due to file collisions.
 * If necessary, refer to your elog messages for the whole content of the
 * above message.

>>> Failed to install dev-lang/rust-1.23.0-r1, Log file:

>>>  '/var/tmp/portage/dev-lang/rust-1.23.0-r1/temp/build.log'

I don't have the rust overlay installed.
Comment 4 Attila Tóth 2018-01-28 11:08:31 UTC
Reopened for dev-lang/rust-1.23.0-r1.
Comment 5 Sven B. 2018-01-28 12:58:04 UTC
(In reply to Vasilis Lourdas from comment #3)
> I get the same error with rust-1.23.0-r1, its files collide with
> dev-util/cargo-0.24:
> 
> I don't have the rust overlay installed.

Did you enable the extended use flag?

 - - extended : Build and install rls, rustfmt and cargo alongside the compiler
                and stdlib

PDEPEND="!extended? ( >=dev-util/cargo-${CARGO_DEPEND_VERSION} )"

I suppose there is a check for having cargo installed missing.

extended? ( !dev-util/cargo )
Comment 6 Attila Tóth 2018-01-28 14:28:30 UTC
(In reply to Sven B. from comment #5)
> (In reply to Vasilis Lourdas from comment #3)
> > I get the same error with rust-1.23.0-r1, its files collide with
> > dev-util/cargo-0.24:
> > 
> > I don't have the rust overlay installed.
> 
> Did you enable the extended use flag?
> 
>  - - extended : Build and install rls, rustfmt and cargo alongside the
> compiler
>                 and stdlib
> 
> PDEPEND="!extended? ( >=dev-util/cargo-${CARGO_DEPEND_VERSION} )"
> 
> I suppose there is a check for having cargo installed missing.
> 
> extended? ( !dev-util/cargo )

I haven't synced yet, so I still don't have this -r1 ebuild, but there's a line in it:
PDEPEND="!extended? ( >=dev-util/cargo-${CARGO_DEPEND_VERSION} )"

Another problem here is, that firefox explicitly depends on cargo. So mozconfig should also take into account, that rust[extended] can also supply cargo apart from dev-libs/cargo itself.
https://gitweb.gentoo.org/repo/gentoo.git/tree/eclass/mozconfig-v6.57.eclass:
DEPEND="app-arch/zip
	app-arch/unzip
	>=sys-devel/binutils-2.16.1
	sys-apps/findutils
	pulseaudio? ( media-sound/pulseaudio )
	>=virtual/rust-1.19.0
	dev-util/cargo
	${RDEPEND}"
Otherwise users may find themselves in a dependency conflict.
Comment 7 Vasilis Lourdas 2018-01-28 16:47:21 UTC
(In reply to Sven B. from comment #5)
> (In reply to Vasilis Lourdas from comment #3)
> > I get the same error with rust-1.23.0-r1, its files collide with
> > dev-util/cargo-0.24:
> > 
> > I don't have the rust overlay installed.
> 
> Did you enable the extended use flag?
> 
>  - - extended : Build and install rls, rustfmt and cargo alongside the
> compiler
>                 and stdlib
> 
> PDEPEND="!extended? ( >=dev-util/cargo-${CARGO_DEPEND_VERSION} )"
> 
> I suppose there is a check for having cargo installed missing.
> 
> extended? ( !dev-util/cargo )

Yes, I did enable the extended flag, so the ebuild should have this extra check as you say.

Regarding Firefox, I put dev-util/cargo in package.provided to resolve this issue. It seems to be ok for now.
Comment 8 Larry the Git Cow gentoo-dev 2018-04-01 11:32:22 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=03005eca7f8563a4964c7f9990e6654152aa0319

commit 03005eca7f8563a4964c7f9990e6654152aa0319
Author:     Mart Raudsepp <leio@gentoo.org>
AuthorDate: 2018-04-01 11:30:33 +0000
Commit:     Mart Raudsepp <leio@gentoo.org>
CommitDate: 2018-04-01 11:31:51 +0000

    profiles: p.use.mask rust[extended] due to unsolved file collisions for months
    
    Acked-by: Dirkjan Ochtman <djc@gentoo.org>
    Bug: https://bugs.gentoo.org/645498
    Bug: https://bugs.gentoo.org/645562

 profiles/base/package.use.mask | 5 +++++
 1 file changed, 5 insertions(+)}
Comment 9 Dirkjan Ochtman (RETIRED) gentoo-dev 2018-08-11 11:40:29 UTC
This has been fixed AFAICT.