Date: Tue, 19 May 2015 23:35:17 +0200 From: Mathieu Arnold <mat@FreeBSD.org> To: Jonathan Anderson <jonathan@FreeBSD.org>, freebsd-ports@freebsd.org Subject: Re: USE_GITHUB and submodules Message-ID: <81C1053609359A9436C61AF5@atuin.in.mat.cc> In-Reply-To: <555B84AA.30901@FreeBSD.org> References: <555B84AA.30901@FreeBSD.org>
next in thread | previous in thread | raw e-mail | index | archive | help
+--On 19 mai 2015 16:14:58 -0230 Jonathan Anderson <jonathan@FreeBSD.org> wrote: | Hi all, | | Is there a mechanism for using the USE_GITHUB variable in a port that | depends on submodules? For instance, the Rust port requires an embedded | (and modified) version of LLVM, which it includes as a submodule. Right | now I'm attempting to add the following to a `post-extract` rule: | | post-extract: | cd ${WRKSRC} && \ | git init && \ | git remote add origin https://github.com/${GH_ACCOUNT}/${PORTNAME} && | \ git fetch && \ | git reset --hard ${PORTVERSION} && \ | git submodule init && \ | git submodule update --recursive | | But this seems quite hackish! It would be great if submodules Just | Worked... but alternatively, is there a USE_GITHUB_URL or somesuch that | would check things out via Git instead of tarball to save me the `git | init` through `git reset` steps? You should not do it that way. First, when building on the cluster, you only have network access during the *fetch targets. Second, you should fetch all the different submodules by URL, and move them at the right place in post-extract, or something, see sysutils/consul for example. I know, it's aweful, but it's how it should be done for now. -- Mathieu Arnold
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?81C1053609359A9436C61AF5>