distro info

This commit is contained in:
Bob Mottram 2016-09-05 21:40:07 +01:00
parent c9d854362d
commit e86f90d2f9
3 changed files with 82 additions and 58 deletions

View File

@ -0,0 +1,18 @@
version,codename,series,created,release,eol
1.1,Buzz,buzz,1993-08-16,1996-06-17,1997-06-05
1.2,Rex,rex,1996-06-17,1996-12-12,1998-06-05
1.3,Bo,bo,1996-12-12,1997-06-05,1999-03-09
2.0,Hamm,hamm,1997-06-05,1998-07-24,2000-03-09
2.1,Slink,slink,1998-07-24,1999-03-09,2000-10-30
2.2,Potato,potato,1999-03-09,2000-08-15,2003-07-30
3.0,Woody,woody,2000-08-15,2002-07-19,2006-06-30
3.1,Sarge,sarge,2002-07-19,2005-06-06,2008-03-30
4.0,Etch,etch,2005-06-06,2007-04-08,2010-02-15
5.0,Lenny,lenny,2007-04-08,2009-02-14,2012-02-06
6.0,Squeeze,squeeze,2009-02-14,2011-02-06,2014-05-31
7,Wheezy,wheezy,2011-02-06,2013-05-04
8,Jessie,jessie,2013-05-04,2015-04-25
9,Stretch,stretch,2015-04-25
10,Buster,buster,2018-07-01
,Sid,sid,1993-08-16
,Experimental,experimental,1993-08-16
Can't render this file because it has a wrong number of fields in line 13.

View File

@ -36,7 +36,7 @@ export TEXTDOMAINDIR="/usr/share/locale"
PROJECT_INSTALL_DIR=/usr/local/bin
if [ -f /usr/bin/${PROJECT_NAME} ]; then
PROJECT_INSTALL_DIR=/usr/bin
PROJECT_INSTALL_DIR=/usr/bin
fi
source /usr/share/${PROJECT_NAME}/utils/${PROJECT_NAME}-utils-setup
@ -80,8 +80,8 @@ vendor_dir="${basedir}/vendor"
vmdebootstrap_dir="${vendor_dir}/vmdebootstrap"
if [ -z "$MIRROR" ] || [ -z "$SUITE" ] ; then
echo $"error: Missing MIRROR and SUITE settings inherited from Makefile."
exit 1
echo $"error: Missing MIRROR and SUITE settings inherited from Makefile."
exit 1
fi
# Packages to install in all Freedombone environments
@ -100,9 +100,9 @@ dev_pkgs="build-essential devscripts make man-db emacs org-mode git mercurial"
echo Building $MACHINE $PROJECT_NAME for $ARCHITECTURE.
case "$MACHINE" in
beaglebone)
extra_pkgs="$beaglebone_pkgs"
extra_opts="\
beaglebone)
extra_pkgs="$beaglebone_pkgs"
extra_opts="\
--variant minbase \
--bootoffset=2mib \
--bootsize 128M \
@ -112,10 +112,10 @@ case "$MACHINE" in
--foreign /usr/bin/qemu-arm-static \
--roottype btrfs \
"
;;
cubietruck | a20-olinuxino-lime | a20-olinuxino-lime2 | a20-olinuxino-micro | cubieboard2)
extra_pkgs="$a20_pkgs"
extra_opts="\
;;
cubietruck | a20-olinuxino-lime | a20-olinuxino-lime2 | a20-olinuxino-micro | cubieboard2)
extra_pkgs="$a20_pkgs"
extra_opts="\
--variant minbase \
--bootoffset=1mib \
--bootsize 128M \
@ -125,29 +125,29 @@ case "$MACHINE" in
--foreign /usr/bin/qemu-arm-static \
--roottype btrfs \
"
;;
virtualbox)
extra_opts="\
;;
virtualbox)
extra_opts="\
--grub \
--roottype btrfs \
" ;;
qemu)
extra_opts="\
qemu)
extra_opts="\
--grub \
--roottype btrfs \
" ;;
usb)
extra_opts="\
usb)
extra_opts="\
--grub \
--roottype btrfs \
" ;;
meshclient)
extra_opts="\
meshclient)
extra_opts="\
--grub \
--roottype btrfs \
" ;;
all)
extra_opts="\
all)
extra_opts="\
--grub \
--roottype btrfs \
" ;;
@ -156,29 +156,29 @@ esac
# allow for lots of extra fun customization options.
for customization in $CUSTOMIZATIONS
do
case "$customization" in
development)
extra_pkgs="$extra_pkgs $dev_pkgs"
;;
esac
case "$customization" in
development)
extra_pkgs="$extra_pkgs $dev_pkgs"
;;
esac
done
for p in $base_pkgs $extra_pkgs; do
pkgopts="$pkgopts --package $p"
pkgopts="$pkgopts --package $p"
done
# Make sure file is owned by current user, not root
touch $(dirname $IMAGE)/${PROJECT_NAME}.log
if [ -x vendor/vmdebootstrap/vmdebootstrap ] ; then
VMDEBOOTSTRAP=vendor/vmdebootstrap/vmdebootstrap
VMDEBOOTSTRAP=vendor/vmdebootstrap/vmdebootstrap
else
VMDEBOOTSTRAP=vmdebootstrap
VMDEBOOTSTRAP=vmdebootstrap
fi
PROJECT_INSTALL_DIR=/usr/local/bin
if [ -f /usr/bin/${PROJECT_NAME} ]; then
PROJECT_INSTALL_DIR=/usr/bin
PROJECT_INSTALL_DIR=/usr/bin
fi
echo $'Making customised customisation script'
@ -190,17 +190,17 @@ TEMP_CUSTOMISE4=/tmp/${PROJECT_NAME}-image-customise4
# cat all the things together
combine_all_scripts $TEMP_CUSTOMISE2
if [ ! -f $TEMP_CUSTOMISE2 ]; then
echo $'Could not combine scripts'
exit 627219
echo $'Could not combine scripts'
exit 627219
fi
echo $'Changing values within customised customisation script'
cp $PROJECT_INSTALL_DIR/${PROJECT_NAME}-image-customise $TEMP_CUSTOMISE3
if [ $MYUSERNAME ]; then
sed -i "s|MY_USERNAME=.*|MY_USERNAME=${MYUSERNAME}|g" $TEMP_CUSTOMISE3
sed -i "s|MY_USERNAME=.*|MY_USERNAME=${MYUSERNAME}|g" $TEMP_CUSTOMISE3
fi
if [ $MYPASSWORD ]; then
sed -i "s|MY_PASSWORD=.*|MY_PASSWORD=${MYPASSWORD}|g" $TEMP_CUSTOMISE3
sed -i "s|MY_PASSWORD=.*|MY_PASSWORD=${MYPASSWORD}|g" $TEMP_CUSTOMISE3
fi
sed -i "s|ROUTER_IP_ADDRESS=.*|ROUTER_IP_ADDRESS=${ROUTER_IP_ADDRESS}|g" $TEMP_CUSTOMISE3
sed -i "s|BOX_IP_ADDRESS=.*|BOX_IP_ADDRESS=${BOX_IP_ADDRESS}|g" $TEMP_CUSTOMISE3
@ -229,13 +229,13 @@ sed -i 's|#!/bin/bash||g' $TEMP_CUSTOMISE3
cat $TEMP_CUSTOMISE2 $TEMP_CUSTOMISE3 > $TEMP_CUSTOMISE4
if [ -f $TEMP_CUSTOMISE ]; then
sudo rm $TEMP_CUSTOMISE
sudo rm $TEMP_CUSTOMISE
fi
sudo mv $TEMP_CUSTOMISE4 $TEMP_CUSTOMISE
rm $TEMP_CUSTOMISE2 $TEMP_CUSTOMISE3
if [ ! -f $TEMP_CUSTOMISE ]; then
echo $'Customised customisation script could not be created'
exit 735892
echo $'Customised customisation script could not be created'
exit 735892
fi
sudo chmod +x $TEMP_CUSTOMISE
echo $'Customised customisation script created'
@ -245,27 +245,27 @@ echo $"starting $VMDEBOOTSTRAP"
# Run vmdebootstrap script to create image
sudo -H \
SUITE="$SUITE" \
MIRROR="$MIRROR" \
BUILD_MIRROR="$BUILD_MIRROR"\
MACHINE="$MACHINE" \
ARCHITECTURE="$ARCHITECTURE" \
SOURCE="$SOURCE" \
CUSTOM_SETUP="$CUSTOM_SETUP" \
$VMDEBOOTSTRAP \
--log $(dirname $IMAGE)/${PROJECT_NAME}.log \
--log-level debug \
--size $IMAGE_SIZE \
--image $IMAGE.img \
--hostname ${PROJECT_NAME} \
--verbose \
--mirror $BUILD_MIRROR \
--customize "$TEMP_CUSTOMISE" \
--lock-root-password \
--arch $ARCHITECTURE \
--distribution $SUITE \
$extra_opts \
$pkgopts
SUITE="$SUITE" \
MIRROR="$MIRROR" \
BUILD_MIRROR="$BUILD_MIRROR"\
MACHINE="$MACHINE" \
ARCHITECTURE="$ARCHITECTURE" \
SOURCE="$SOURCE" \
CUSTOM_SETUP="$CUSTOM_SETUP" \
$VMDEBOOTSTRAP \
--log $(dirname $IMAGE)/${PROJECT_NAME}.log \
--log-level debug \
--size $IMAGE_SIZE \
--image $IMAGE.img \
--hostname ${PROJECT_NAME} \
--verbose \
--mirror $BUILD_MIRROR \
--customize "$TEMP_CUSTOMISE" \
--lock-root-password \
--arch $ARCHITECTURE \
--distribution $SUITE \
$extra_opts \
$pkgopts
echo $'Removing customised customisation script'
sudo shred -zu $TEMP_CUSTOMISE

View File

@ -37,6 +37,12 @@ if [ -d vendor/vmdebootstrap ] ; then
else
git clone git://git.liw.fi/vmdebootstrap vendor/vmdebootstrap
fi
if [ ! -d /usr/share/distro-info ]; then
sudo mkdir -p /usr/share/distro-info
cp distro-info/* /usr/share/distro-info
fi
cd vendor/vmdebootstrap
git checkout tags/vmdebootstrap-0.8 -b tags/vmdebootstrap-0.8
for f in ../../vendor-patches/vmdebootstrap/* ; do