Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 12 Oct 2017 10:51:00 +0000 (UTC)
From:      Tobias Kortkamp <tobik@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r451845 - head/Mk/Uses
Message-ID:  <201710121051.v9CAp0WY030644@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: tobik
Date: Thu Oct 12 10:51:00 2017
New Revision: 451845
URL: https://svnweb.freebsd.org/changeset/ports/451845

Log:
  Mk/Uses/cargo.mk: Fix crate name and version split
  
  cargo.mk is a little too eager in splitting a crate's name and version
  in two when the version contains a dash (e.g. csv-1.0.0-beta.4) and
  the wrong URL ends up being used in MASTER_SITES e.g.
  
  .../csv-1.0.0/beta.4/download/...
  
  instead of the correct one
  
  .../csv/1.0.0-beta.4/download/...
  
  Reviewed by:	dumbbell
  Differential Revision:	https://reviews.freebsd.org/D12628

Modified:
  head/Mk/Uses/cargo.mk

Modified: head/Mk/Uses/cargo.mk
==============================================================================
--- head/Mk/Uses/cargo.mk	Thu Oct 12 10:14:42 2017	(r451844)
+++ head/Mk/Uses/cargo.mk	Thu Oct 12 10:51:00 2017	(r451845)
@@ -38,7 +38,7 @@ CARGO_DIST_SUBDIR?=	rust/crates
 
 # Generate list of DISTFILES.
 .for _crate in ${CARGO_CRATES}
-MASTER_SITES+=	${MASTER_SITES_CRATESIO}/${_crate:C/-[^-]*$//}/${_crate:C/^.*-//}/download?dummy=/:cargo_${_crate:S/-//g:S/.//g}
+MASTER_SITES+=	${MASTER_SITES_CRATESIO}/${_crate:C/-[0-9].*$//}/${_crate:C/^.*-([0-9].*)/\1/}/download?dummy=/:cargo_${_crate:S/-//g:S/.//g}
 DISTFILES+=	${CARGO_DIST_SUBDIR}/${_crate}.tar.gz:cargo_${_crate:S/-//g:S/.//g}
 .endfor
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201710121051.v9CAp0WY030644>