summaryrefslogtreecommitdiff
path: root/functions/architecture.sh
diff options
context:
space:
mode:
Diffstat (limited to 'functions/architecture.sh')
-rwxr-xr-xfunctions/architecture.sh35
1 files changed, 33 insertions, 2 deletions
diff --git a/functions/architecture.sh b/functions/architecture.sh
index fb0e910c1..29164d8b6 100755
--- a/functions/architecture.sh
+++ b/functions/architecture.sh
@@ -1,7 +1,7 @@
#!/bin/sh
# architecture.sh - handle architecture specific support
-# Copyright (C) 2007 Otavio Salvador <otavio@debian.org>
+# Copyright (C) 2006-2007 Daniel Baumann <daniel@debian.org>
#
# live-helper comes with ABSOLUTELY NO WARRANTY; for details see COPYING.
# This is free software, and you are welcome to redistribute it
@@ -16,7 +16,7 @@ Check_architecture ()
for ARCHITECTURE in ${ARCHITECTURES}
do
- if [ "${ARCHITECTURE}" = "${LIVE_ARCHITECTURE}" ]
+ if [ "`echo ${LIVE_ARCHITECTURE} | grep ${ARCHITECTURE}`" ]
then
VALID="true"
break
@@ -29,3 +29,34 @@ Check_architecture ()
exit 0
fi
}
+
+Check_multiarchitecture ()
+{
+ if [ "`echo ${LIVE_ARCHITECTURE} | wc -w`" -gt "1" ]
+ then
+ # First, only support multiarch on iso
+ if [ "${LIVE_BINARY_IMAGES}" = "iso" ]
+ then
+ # Assemble multi-arch
+ case "${LIVE_CURRENT_ARCHITECTURE}" in
+ amd64)
+ DESTDIR="${DESTDIR}.amd"
+ DESTDIR_LIVE="${DESTDIR_LIVE}.amd"
+ DESTDIR_INSTALL="${DESTDIR_INSTALL}.amd"
+ ;;
+
+ i386)
+ DESTDIR="${DESTDIR}.386"
+ DESTDIR_LIVE="${DESTDIR_LIVE}.386"
+ DESTDIR_INSTALL="${DESTDIR_INSTALL}.386"
+ ;;
+
+ powerpc)
+ DESTDIR="${DESTDIR}.ppc"
+ DESTDIR_LIVE="${DESTDIR_LIVE}.ppc"
+ DESTDIR_INSTALL="${DESTDIR_INSTALL}.ppc"
+ ;;
+ esac
+ fi
+ fi
+}