wok-next diff linux-dev/stuff/vm-uml.in @ rev 20534
Clean default configure options when site script used.
author | Aleksej Bobylev <al.bobylev@gmail.com> |
---|---|
date | Fri Mar 30 19:31:50 2018 +0300 (2018-03-30) |
parents | |
children |
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/linux-dev/stuff/vm-uml.in Fri Mar 30 19:31:50 2018 +0300 1.3 @@ -0,0 +1,17 @@ 1.4 +#!/bin/sh 1.5 + 1.6 +# /etc/inittab: "tty21::respawn:/bin/su -c '/boot/vm-uml 1 /boot/guests/slitaz.img 2 512m' nobody" 1.7 +n=${1:-0} 1.8 +tap=tap$n 1.9 +args="rw root=/dev/null" 1.10 +dev="initrd=$(ls -r /boot/rootfs*.gz | sed q)" 1.11 +if [ -n "$2" ]; then 1.12 + args="ro root=620${3:-1} screen=text sound=noconf" 1.13 + dev="ubd0=$2" 1.14 +fi 1.15 + 1.16 +cd $(dirname $0) 1.17 +ifconfig $tap 192.168.$n.1 1.18 +./linux-uml-@VERSION@ $dev mem=${4:-512m} fakehd fake_ide ubd=3 con0=fd:0,fd:1 \ 1.19 + con=pts ssl=pts eth0=tuntap,$tap,fe:f0:00:00:00:0$n,192.168.$n.1 \ 1.20 + $args cpuinfo=$(sed '/model name/!d;s/.*: //;s/ /_/g;q' /proc/cpuinfo)