summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDieter Plaetinck <dieter@plaetinck.be>2008-12-20 11:47:18 +0100
committerDieter Plaetinck <dieter@plaetinck.be>2008-12-20 11:47:18 +0100
commitce3afefeb9728619a06989a67e7ffd5ed299ecf8 (patch)
tree5e35a50c37e506c72cc58b79c811e7aad30447d5 /src
parent2f839ffec30eea2025cced9fb690ab612795c6ac (diff)
softcode architecture + some small misc stuff in yaourt lib
Diffstat (limited to 'src')
-rw-r--r--src/core/libs/lib-ui-interactive.sh2
-rw-r--r--src/core/procedures/base2
-rw-r--r--src/core/procedures/quickinst6
3 files changed, 4 insertions, 6 deletions
diff --git a/src/core/libs/lib-ui-interactive.sh b/src/core/libs/lib-ui-interactive.sh
index f7f4ecb..543495a 100644
--- a/src/core/libs/lib-ui-interactive.sh
+++ b/src/core/libs/lib-ui-interactive.sh
@@ -864,7 +864,7 @@ interactive_select_mirror() {
ask_option no "Mirror selection" "Select an FTP/HTTP mirror" $MIRRORS "Custom" "_" || return 1
local _server=$ANSWER_OPTION
if [ "${_server}" = "Custom" ]; then
- ask_string "Enter the full URL to core repo." "ftp://ftp.archlinux.org/core/os/i686" || return 1
+ ask_string "Enter the full URL to core repo." "ftp://ftp.archlinux.org/core/os/$var_ARCH" || return 1
var_SYNC_URL=$ANSWER_STRING
else
# Form the full URL for our mirror by grepping for the server name in
diff --git a/src/core/procedures/base b/src/core/procedures/base
index fa88210..94a9d1e 100644
--- a/src/core/procedures/base
+++ b/src/core/procedures/base
@@ -7,6 +7,8 @@ var_RUNTIME_PACKAGES=
var_PKG_FILE=$RUNTIME_DIR/package-list
var_MIRRORLIST="/etc/pacman.d/mirrorlist"
var_UI_TYPE="cli" # set to cli or dia for dialog
+var_ARCH=`uname -m` #works for i686 TODO: check if it works for x86_64
+[ -z "$var_ARCH" ] && die_error "Could not determine your architecture"
###### Phases ( can be overridden by more specific procedures) ######
phase_preparation=(\
diff --git a/src/core/procedures/quickinst b/src/core/procedures/quickinst
index 314569c..73c1f46 100644
--- a/src/core/procedures/quickinst
+++ b/src/core/procedures/quickinst
@@ -25,11 +25,7 @@ usage() {
echo
echo "Examples:"
if [ -e /usr/bin/wget ]; then
- if [ "$(uname -m)" = "x86_64" ]; then
- echo " quickinst ftp /mnt ftp://ftp.archlinux.org/core/os/x86_64"
- else
- echo " quickinst ftp /mnt ftp://ftp.archlinux.org/core/os/i686"
- fi
+ echo " quickinst ftp /mnt ftp://ftp.archlinux.org/core/os/$var_ARCH"
fi
echo " quickinst cd /mnt /src/core/pkg"