Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 6 Jan 2015 20:42:51 +0000 (UTC)
From:      Glen Barber <gjb@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r276765 - head/release/scripts
Message-ID:  <201501062042.t06KgpZm021319@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: gjb
Date: Tue Jan  6 20:42:50 2015
New Revision: 276765
URL: https://svnweb.freebsd.org/changeset/base/276765

Log:
  Update pkg-stage.sh to be compatible with pkg-1.4.x.
  
  In 1.3.x and earlier, ABI format is, for example,
  freebsd:11:x86:64.
  
  In 1.4.x, ABI format is FreeBSD:11:amd64, and a new
  configuration entry, ALTABI, is: freebsd:11:x86:64.
  
  Export PKG_ABI and PKG_ALTABI accordingly, and if
  PKG_ALTABI is set, create a symlink within the dvd
  PKG_CACHEDIR so both new and old ABI directories
  exist.
  
  MFC after:	3 days
  Sponsored by:	The FreeBSD Foundation

Modified:
  head/release/scripts/pkg-stage.sh

Modified: head/release/scripts/pkg-stage.sh
==============================================================================
--- head/release/scripts/pkg-stage.sh	Tue Jan  6 20:10:42 2015	(r276764)
+++ head/release/scripts/pkg-stage.sh	Tue Jan  6 20:42:50 2015	(r276765)
@@ -40,10 +40,15 @@ if [ ! -x /usr/local/sbin/pkg ]; then
 	/usr/bin/make -C /usr/ports/ports-mgmt/pkg install clean
 fi
 
+export DVD_DIR="dvd/packages"
 export PKG_ABI=$(pkg config ABI)
-export PKG_REPODIR="dvd/packages/${PKG_ABI}"
+export PKG_ALTABI=$(pkg config ALTABI 2>/dev/null)
+export PKG_REPODIR="${DVD_DIR}/${PKG_ABI}"
 
 /bin/mkdir -p ${PKG_REPODIR}
+if [ ! -z "${PKG_ALTABI}" ]; then
+	ln -s ${PKG_ABI} ${PKG_ALTABI}
+fi
 
 # Print pkg(8) information to make debugging easier.
 ${PKGCMD} -vv



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