[pacman-dev] [PATCH] makepkg.sh.in is prepared for building of splittet packages

Xavier shiningxc at gmail.com
Sat Jun 14 15:06:23 EDT 2008


silvio at port1024.net wrote:
> From: Silvio fricke<silvio at port1024.net>
>
> Signed-off-by: Silvio fricke<silvio at port1024.net>
> ---
>   scripts/makepkg.sh.in |   58 ++++++++++++++++++++++++++++++++++++++++++++++++-
>   1 files changed, 57 insertions(+), 1 deletions(-)
>

I have only minor "appearance" issues to address here, I don't know what 
to think about the patch itself. Only that it does not seem too big and 
mostly concentrated in one place, which is good.

So first, isn't the correct term "splitted"?
It seems that you use both "split" and "splittet" which would then be 
incorrect.

Also you should read this :
http://archlinux.org/pacman/submitting-patches.html
Especially this part :
<<
Describe your patch.

Before the actual diff begins, it helps if you describe the changes in 
the patch. This allows others to see what you intended so as to compare 
it to what was actually done, and allows better feedback. If you use 
git-format-patch to create your patch, then your commit message will be 
shown above the patch by default.
 >>

Also it is rather strange that there is no space between your name and 
mail address. Did you do something like the above :
	git repo-config user.name "Your Name"
	git repo-config user.email "me at example.com"


> diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in
> index 5bdc5bc..3c0c6f7 100644
> --- a/scripts/makepkg.sh.in
> +++ b/scripts/makepkg.sh.in
> @@ -675,6 +675,8 @@ run_build() {
>   			mv "$BUILDLOG" "$BUILDLOG.$i"
>   		fi
>
> +		export BUILDLOG
> +
>   		build 2>&1 | tee "$BUILDLOG"; ret=${PIPESTATUS[0]}
>   	else
>   		build 2>&1 || ret=$?
> @@ -1389,7 +1391,57 @@ if [ "$INFAKEROOT" = "1" ]; then
>   		tidy_install
>   	fi
>
> -	create_package
> +	if [ "$splitinstall" != "" ] ; then
> +		backup_o=$backup
> +		conflicts_o=$conflicts
> +		depends_o=$depends
> +		groups_o=$groups
> +		install_o=$install
> +		license_o=$license
> +		pkgdesc_o=$pkgdesc
> +		pkgname_o=$pkgname
> +		pkgver_o=$pkgver
> +		provides_o=$provides
> +		replaces_o=$replaces
> +		url_o=$url
> +		create_package
> +		for it in "${splitinstall[@]}" ; do
> +			if [ -d "$pkgdir" ]; then
> +				msg "Removing existing pkg/ directory..."
> +				rm -rf "$pkgdir"
> +			fi
> +			mkdir -p "$pkgdir"
> +			msg "Building split package using function: $it"
> +

splitted?

> +			if [ "$LOGGING" = "1" ]; then
> +				[ "x$BUILDLOG" == "x" ]&&  BUILDLOG="${startdir}/${pkgname}-${pkgver}-${pkgrel}-${CARCH}.log"
> +				echo>>  "$BUILDLOG"
> +				echo>>  "$BUILDLOG"
> +				echo "--- Logging for $it ------------">>  "$BUILDLOG"
> +

What about wraiden's suggestion in the bug comments :
<<
You could change the comment appending into a single line of the
following form which would be cleaner in my opinion.

echo -e "\n\n--- Logging for $it ------------" >> "$BUILDLOG"
 >>





More information about the pacman-dev mailing list