diff options
author | Daniel Baumann <daniel@debian.org> | 2007-09-23 10:05:14 +0200 |
---|---|---|
committer | Daniel Baumann <daniel@debian.org> | 2011-03-09 18:22:26 +0100 |
commit | 0d5ff4ca7596790f853cf637e0fe225cad810a76 (patch) | |
tree | 360ca9a49f3d82d589a4b49c98e5210dfcb3b74e /functions/architecture.sh | |
parent | cd5110f6b8eb77519d704972276cfd5be6bff055 (diff) | |
download | vyos-live-build-0d5ff4ca7596790f853cf637e0fe225cad810a76.tar.gz vyos-live-build-0d5ff4ca7596790f853cf637e0fe225cad810a76.zip |
Adding live-helper 1.0~a18-1.
Diffstat (limited to 'functions/architecture.sh')
-rwxr-xr-x | functions/architecture.sh | 35 |
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 +} |