Remove guix

This isn't really suitable, since it builds the entire toolchain from scratch. On a BBB that could take weeks
This commit is contained in:
Bob Mottram 2017-08-26 22:00:55 +01:00
parent 30e62efa37
commit 69dc61f029
3 changed files with 0 additions and 142 deletions

View File

@ -1469,7 +1469,6 @@ configure_user_interface
image_setup_utils image_setup_utils
image_install_inadyn image_install_inadyn
image_install_nodejs image_install_nodejs
image_install_guix
image_preinstall_repos image_preinstall_repos
# remove downloaded packages # remove downloaded packages

View File

@ -34,9 +34,6 @@ GUILE_HASH='c707b9cf6f97ecca3a4e3e704e62b83f95f1aec28ed1535f5d0a1d36af07a015'
EIGHTSYNC_REPO="git://git.savannah.gnu.org/8sync.git" EIGHTSYNC_REPO="git://git.savannah.gnu.org/8sync.git"
EIGHTSYNC_COMMIT='8cbb7f22227c0afdd3b0bd758ebec0efba2fa1e1' EIGHTSYNC_COMMIT='8cbb7f22227c0afdd3b0bd758ebec0efba2fa1e1'
GUIX_VERSION='0.13.0'
GUIX_DOWNLOAD_URL='ftp://alpha.gnu.org/gnu/guix'
function install_8sync { function install_8sync {
apt-get -qy install flex libunistring-dev libgc-dev autoconf texinfo apt-get -qy install flex libunistring-dev libgc-dev autoconf texinfo
@ -95,139 +92,4 @@ function install_guile {
echo 'export PATH=$PATH:$GUILE_PATH' >> ~/.bashrc echo 'export PATH=$PATH:$GUILE_PATH' >> ~/.bashrc
} }
function install_guix_get_architecture {
if [[ ${ARCHITECTURE} == *"386" || ${ARCHITECTURE} == *"686" ]]; then
CURR_ARCH='i686'
fi
if [[ ${ARCHITECTURE} == *"amd64" || ${ARCHITECTURE} == "x86_64" ]]; then
CURR_ARCH='x86_64'
fi
if [[ ${ARCHITECTURE} == *"arm"* ]]; then
CURR_ARCH='armhf'
fi
if [ ! ${CURR_ARCH} ]; then
echo $'No architecture specified'
ARCHITECTURE=$(uname -m)
if [[ ${ARCHITECTURE} == "arm"* ]]; then
CURR_ARCH='armhf'
echo $"Using $CURR_ARCH"
fi
if [[ ${ARCHITECTURE} == "amd"* || ${ARCHITECTURE} == "x86_64" ]]; then
CURR_ARCH='x86_64'
echo $"Using $CURR_ARCH"
fi
if [[ ${ARCHITECTURE} == *"386" || ${ARCHITECTURE} == *"686" ]]; then
CURR_ARCH='i686'
echo $"Using $CURR_ARCH"
fi
fi
}
function install_guix_user {
install_path=$1
if ! grep -q 'GUIX_LOCPATH' $install_path/.bashrc; then
echo 'export GUIX_LOCPATH=$HOME/.guix-profile/lib/locale' >> $install_path/.bashrc
fi
if ! grep -q 'GUIX_PROFILE' $install_path/.bashrc; then
echo 'export GUIX_PROFILE=$HOME/.guix-profile' >> $install_path/.bashrc
echo 'source $GUIX_PROFILE/etc/profile' >> $install_path/.bashrc
fi
}
function image_install_guix {
install_guix_get_architecture
if [ ! -d $rootdir$INSTALL_DIR/guix ]; then
mkdir -p $INSTALL_DIR/guix
fi
cd $rootdir$INSTALL_DIR/guix
if [ ! -f guix-binary-${GUIX_VERSION}.${CURR_ARCH}-linux.tar.xz ]; then
wget $GUIX_DOWNLOAD_URL/guix-binary-${GUIX_VERSION}.${CURR_ARCH}-linux.tar.xz
fi
}
function install_guix {
if [[ $(app_is_installed install_guix) == "1" ]]; then
return
fi
apt-get -qy install wget xz-utils
read_config_param MY_USERNAME
read_config_param ARCHITECTURE
install_guix_get_architecture
if [ ! -d $INSTALL_DIR/guix ]; then
mkdir -p $INSTALL_DIR/guix
fi
cd $INSTALL_DIR/guix
if [ ! -f guix-binary-${GUIX_VERSION}.${CURR_ARCH}-linux.tar.xz ]; then
wget $GUIX_DOWNLOAD_URL/guix-binary-${GUIX_VERSION}.${CURR_ARCH}-linux.tar.xz
fi
if [ ! -f guix-binary-${GUIX_VERSION}.${CURR_ARCH}-linux.tar.xz ]; then
echo $"Unable to download guix from $GUIX_DOWNLOAD_URL"
exit 73826
fi
tar --warning=no-timestamp -xf guix-binary-${GUIX_VERSION}.${CURR_ARCH}-linux.tar.xz
if [ ! -d var/guix ]; then
echo $'guix directory var/guix not found'
exit 8726325
fi
if [ -d /var/guix ]; then
rm -rf /var/guix
fi
mv $INSTALL_DIR/guix/var/guix /var/
if [ ! -d gnu ]; then
echo $'guix gnu directory not found'
exit 743383235
fi
if [ -d /gnu ]; then
rm -rf /gnu
fi
mv gnu /
ln -sf /var/guix/profiles/per-user/root/guix-profile /root/.guix-profile
export GUIX_PROFILE=$HOME/.guix-profile
source $GUIX_PROFILE/etc/profile
# add build users
groupadd --system guixbuild
for i in `seq -w 1 10`;
do
useradd -g guixbuild -G guixbuild \
-d /var/empty -s `which nologin` \
-c "Guix build user $i" --system \
guixbuilder$i;
done
GUIX_DAEMON=$(find /var/guix -name guix-daemon.service)
if [ ! -f $GUIX_DAEMON ]; then
echo $"$GUIX_DAEMON"
echo $'No guix systemd daemon found'
exit 78225548
fi
cp $GUIX_DAEMON /etc/systemd/system/
systemctl enable guix-daemon
systemctl start guix-daemon
if [ ! -d /usr/local/bin ]; then
mkdir -p /usr/local/bin
fi
cd /usr/local/bin
ln -s /var/guix/profiles/per-user/root/guix-profile/bin/guix
if [ ! -d /usr/local/share/info ]; then
mkdir -p /usr/local/share/info
fi
install_guix_user /root
install_guix_user /etc/skel
install_guix_user /home/$MY_USERNAME
guix package -i glibc-locales
install_completed install_guix
}
# NOTE: deliberately no exit 0 # NOTE: deliberately no exit 0

View File

@ -997,9 +997,6 @@ function setup_utils {
function_check setup_powerline function_check setup_powerline
setup_powerline setup_powerline
function_check install_guix
install_guix
} }
function setup_email { function setup_email {