[pacman-dev] [PATCH 5/7] makepkg: encode epoch in version specifier if > 0

Allan McRae allan at archlinux.org
Sat Jan 22 09:43:39 EST 2011


On 21/01/11 10:33, Dan McGee wrote:
> This makes things consistent with everywhere else we are incorporating the
> new optional epoch field. Add a helper function that forms the version
> string for you and use it in makepkg where I found 'pkgver.*-.*pkgrel'.
>
> This exposes a few shortcomings in a previous "Override pkgver" patch
> (2020e629) in the install package and check if built functions.
>
> Signed-off-by: Dan McGee<dan at archlinux.org>

Ack-by: Allan

> ---
>   scripts/makepkg.sh.in |   69 ++++++++++++++++++++++++++++++++-----------------
>   1 files changed, 45 insertions(+), 24 deletions(-)
>
> diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in
> index c01ae0c..b97ae0c 100644
> --- a/scripts/makepkg.sh.in
> +++ b/scripts/makepkg.sh.in
> @@ -142,18 +142,19 @@ clean_up() {
>   		msg "$(gettext "Cleaning up...")"
>   		rm -rf "$pkgdir" "$srcdir"
>   		if [[ -n $pkgbase ]]; then
> +			local fullver=$(get_full_version $epoch $pkgver $pkgrel)
>   			# Can't do this unless the BUILDSCRIPT has been sourced.
>   			if (( BUILDFUNC )); then
> -				rm -f "${pkgbase}-${pkgver}-${pkgrel}-${CARCH}-build.log"*
> +				rm -f "${pkgbase}-${fullver}-${CARCH}-build.log"*
>   			fi
>   			if (( CHECKFUNC )); then
> -				rm -f "${pkgbase}-${pkgver}-${pkgrel}-${CARCH}-check.log"*
> +				rm -f "${pkgbase}-${fullver}-${CARCH}-check.log"*
>   			fi
>   			if (( PKGFUNC )); then

You can add the TODO item regarding pkgver/pkgrel overrides here too. 
And where logs are created.

Allan



More information about the pacman-dev mailing list