From owner-freebsd-ports@FreeBSD.ORG Tue May 19 18:44:59 2015 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id C118B11E for ; Tue, 19 May 2015 18:44:59 +0000 (UTC) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:1900:2254:206c::16:87]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B243114C6 for ; Tue, 19 May 2015 18:44:59 +0000 (UTC) Received: from jacob.local (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.9/8.14.9) with ESMTP id t4JIiwHL009538 for ; Tue, 19 May 2015 18:44:59 GMT (envelope-from jonathan@FreeBSD.org) Message-ID: <555B84AA.30901@FreeBSD.org> Date: Tue, 19 May 2015 16:14:58 -0230 From: Jonathan Anderson User-Agent: Postbox 3.0.11 (Macintosh/20140602) MIME-Version: 1.0 To: freebsd-ports@freebsd.org Subject: USE_GITHUB and submodules Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 19 May 2015 18:44:59 -0000 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? Cheers, Jon -- jonathan@FreeBSD.org