USES=cargo vs. workspaces
Jan Beich
jbeich at FreeBSD.org
Mon Dec 2 07:16:27 UTC 2019
Jan Beich <jbeich at FreeBSD.org> writes:
> Some projects (e.g., Servo, Veloren) bundle several packages together.
> When dependencies also bundle packages it confuses "git" override.
> Any tips/workarounds that scale beyond 1 port?
>
> For example,
>
> $ cat Makefile
> PORTNAME= veloren
> DISTVERSIONSUFFIX= v
> DISTVERSION= 0.3.0
> CATEGORIES= games
>
> USES= cargo
> USE_GITLAB= yes
> GL_COMMIT= ef049607e008223d6f9d8a021dd00e1eeef44b5e
>
> .sinclude "${.CURDIR}/Makefile.crates"
> .include <bsd.port.mk>
>
> $ make clean patch NO_CHECKSUM=
> $ make cargo-crates >Makefile.crates
> $ make makesum
>
> $ make clean all
> [...]
> ===> Configuring for veloren-0.3.0
> error: failed to load source for a dependency on `conrod_core`
>
> Caused by:
> Unable to update WRKDIR/conrod-d603363488870eae9df91ba45ba795509c8a6ab4-d603363488870eae9df91ba45ba795509c8a6ab4
>
> Caused by:
> found a virtual manifest at `WRKDIR/conrod-d603363488870eae9df91ba45ba795509c8a6ab4-d603363488870eae9df91ba45ba795509c8a6ab4/Cargo.toml` instead of a package manifest
> *** Error code 101
>
> Stop.
Thanks to https://svnweb.freebsd.org/changeset/ports/517982
I've got past the error using the following
CARGO_GIT_SUBDIR= conrod_core:conrod_core:conrod_core \
conrod_core:conrod_winit:backends/conrod_winit
Veloren doesn't build yet due to dependency on a Nightly-only feature
but the progress is promising. I haven't tried Servo because it'd likely
require heavy patching and probably more hacks to work as a port.
More information about the freebsd-ports
mailing list