Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 12 Sep 2014 16:21:26 -0500
From:      Bryan Drewery <bdrewery@FreeBSD.org>
To:        Glen Barber <gjb@FreeBSD.org>, src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   Re: svn commit: r271480 - head/release/scripts
Message-ID:  <541363D6.3080502@FreeBSD.org>
In-Reply-To: <201409121852.s8CIq1Eg099609@svn.freebsd.org>
References:  <201409121852.s8CIq1Eg099609@svn.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
This is an OpenPGP/MIME signed message (RFC 4880 and 3156)
--sJ2BLcToTG3CffBvFjhWeev1RoQeMkg2v
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable

On 9/12/2014 1:52 PM, Glen Barber wrote:
> Author: gjb
> Date: Fri Sep 12 18:52:01 2014
> New Revision: 271480
> URL: http://svnweb.freebsd.org/changeset/base/271480
>=20
> Log:
>   Set PKG_CACHEDIR to an 'All/' directory one level lower
>   to fix 'pkg repo' generating repository metadata for the
>   on-disc packages.
>  =20
>   MFC after:	3 days
>   X-MFC-to-10.1:	yes
>   Sponsored by:	The FreeBSD Foundation
>=20
> Modified:
>   head/release/scripts/pkg-stage.sh
>=20
> Modified: head/release/scripts/pkg-stage.sh
> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D
> --- head/release/scripts/pkg-stage.sh	Fri Sep 12 18:31:44 2014	(r271479=
)
> +++ head/release/scripts/pkg-stage.sh	Fri Sep 12 18:52:01 2014	(r271480=
)
> @@ -44,7 +44,8 @@ PKG_ABI=3D$(pkg -vv | grep ^ABI | awk '{pr
>  PKG_ABI=3D"${PKG_ABI%\";}"
>  PKG_ABI=3D"${PKG_ABI#\"}"
>  export PKG_ABI
> -export PKG_CACHEDIR=3D"dvd/packages/${PKG_ABI}"
> +export PKG_REPODIR=3D"dvd/packages/${PKG_ABI}"
> +export PKG_CACHEDIR=3D"${PKG_REPODIR}/${PKG_ABI}/All"
> =20
>  /bin/mkdir -p ${PKG_CACHEDIR}
> =20
> @@ -53,7 +54,7 @@ ${PKGCMD} -vv
>  ${PKGCMD} update -f
>  ${PKGCMD} fetch -d ${DVD_PACKAGES}
> =20
> -${PKGCMD} repo ${PKG_CACHEDIR}
> +${PKGCMD} repo ${PKG_REPODIR}
> =20
>  # Always exit '0', even if pkg(8) complains about conflicts.
>  exit 0
>=20

There's still an issue with 1.3 here. pkg-fetch now uses mangled package
names in its cache dir, and does not use the All/ subdir anymore as
you've found.

# ls /var/cache/pkg/psutils-1.17_4*
/var/cache/pkg/psutils-1.17_4-fe318c25d7.txz
/var/cache/pkg/psutils-1.17_4.txz@

Rather the polluting the DVD with these hashed filenames you can just
not set PKG_CACHEDIR and use pkg fetch -o ${PKG_REPODIR} -d ${DVD_PACKAGE=
S}.

You can also now simplify the PKG_ABI lookup 4 lines to just: export
PKG_ABI=3D$(pkg config ABI).

pkg fetch -o was added to 1.3 specifically for cases such as creating DVD=
s.

It will then store the files in dvd/packages/${PKG_ABI}/All.

See https://people.freebsd.org/~bdrewery/patches/pkg-stage-1.3.diff

--=20
Regards,
Bryan Drewery


--sJ2BLcToTG3CffBvFjhWeev1RoQeMkg2v
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: OpenPGP digital signature
Content-Disposition: attachment; filename="signature.asc"

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (MingW32)

iQEcBAEBAgAGBQJUE2PWAAoJEDXXcbtuRpfPi/kIAJzYawO0BrfXRYlNBBeTFNxw
m+unX1OwFiZYR/P1cp66TfiLjDfY4aXjsWiHPzoSlwyrg67W8jIPvaCOLZH28F/8
popFl0u+6eMRQQz1nXqWsveNePGwhewEI4yGAWWWfv1V/jqfeEdi62WNvq2jS9pj
GWRONNKKZ1BpEyE8aBMlO00aDChuS8rC4vf10LnS2yN1yD0Ccgms7KfK4hw7+/0N
mz+Kx50oVlgHWRfPCuhKIkAzEUj32uiK4mUt4lylTuJ4SQd4CwlvPCIeaHl6PTEN
c6nqyHNLYsXCAlCLTp/FR2Fd57RUEAWPsrKHNBRqzkqa8IiTUypie+9qwRCt4sQ=
=Zlfo
-----END PGP SIGNATURE-----

--sJ2BLcToTG3CffBvFjhWeev1RoQeMkg2v--



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