Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJan Steffens <jan.steffens@gmail.com>2011-03-12 15:16:31 +0100
committerJan Steffens <jan.steffens@gmail.com>2011-03-14 02:31:20 +0100
commit3491ea5d799479c9ae0da2c2864084146d61a10a (patch)
treebc02118fec7640b6d241aad213b76ce6386dd59b
parentd1304a3f1d527801b7afa1c8498b2f2a8f28ecd8 (diff)
Syntax cleanup
No functional change.
-rwxr-xr-xarchbuild4
-rwxr-xr-xmkarchroot9
2 files changed, 6 insertions, 7 deletions
diff --git a/archbuild b/archbuild
index fc2ec34..3435be5 100755
--- a/archbuild
+++ b/archbuild
@@ -4,8 +4,8 @@ base_packages='base base-devel sudo'
cmd="$(basename "${0%-build}")"
if [ "${cmd%-*}" == 'multilib' ]; then
- repo="${cmd}"
- arch='x86_64'
+ repo="${cmd}"
+ arch='x86_64'
base_packages+=' gcc-multilib libtool-multilib'
else
repo=${cmd%-*}
diff --git a/mkarchroot b/mkarchroot
index ac05a6b..254841e 100755
--- a/mkarchroot
+++ b/mkarchroot
@@ -26,7 +26,7 @@ usage() {
echo ' -C <file> Location of a pacman config file'
echo ' -M <file> Location of a makepkg config file'
echo ' -n Do not copy config files into the chroot'
- echo " -c <dir> Set pacman cache. Default: /var/cache/pacman/pkg"
+ echo ' -c <dir> Set pacman cache. Default: /var/cache/pacman/pkg'
echo ' -h This message'
exit $1
}
@@ -68,7 +68,7 @@ shift 1
if [ -z "$cache_dir" ]; then
cache_conf=${working_dir}/etc/pacman.conf
[ ! -f $cache_conf ] && cache_conf=${pac_conf:-/etc/pacman.conf}
- cache_dir=$((grep -m 1 '^CacheDir' $cache_conf || echo 'CacheDir = /var/cache/pacman/pkg') | sed 's/CacheDir\s*=\s*//')
+ cache_dir=$( (grep -m 1 '^CacheDir' $cache_conf || echo 'CacheDir = /var/cache/pacman/pkg') | sed 's/CacheDir\s*=\s*//')
unset cache_conf
fi
@@ -82,8 +82,7 @@ if echo "${host_mirror}" | grep -q 'file://'; then
host_mirror_path=$(echo "${host_mirror}" | sed -E 's#file://(/.*)/\$repo/os/\$arch#\1#g')
fi
-# {{{ functions
-
+# {{{ functions
chroot_mount() {
[ -e "${working_dir}/sys" ] || mkdir "${working_dir}/sys"
mount -t sysfs sysfs "${working_dir}/sys"
@@ -160,7 +159,7 @@ if [ "$RUN" != "" ]; then
eval chroot "${working_dir}" ${RUN}
# }}}
- else
+else
# {{{ build chroot
if [ -e "${working_dir}" -a "${FORCE}" = "n" ]; then
echo "error: working dir '${working_dir}' already exists - try using -f"