Skip to content

Commit

Permalink
Fix bug that prevented install of syslinux bootloader. Added AntiX an…
Browse files Browse the repository at this point in the history
…d MX Linux distros
  • Loading branch information
Root User committed Mar 26, 2020
1 parent 77b1c38 commit bf6d2fe
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 8 deletions.
10 changes: 6 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,8 @@ distroflash.lua has been seen to work with the following distributions. If anyon

## Perfect, runs live and installs from live environment

* AntiX Linux 19
* MX Linux 19.1
* Bodhi Linux 5.0.0
* Trisquel-mini 8.0
* Linux Mint 19.3
Expand All @@ -88,16 +90,16 @@ distroflash.lua has been seen to work with the following distributions. If anyon

## Finiky, can be made to install

* Salix 14.2 - has to be told to install from harddrive, and given both the device name and path to files on disk
* Slax 9.11.0 - no automated installer, apparently can be installed from live by copying files manually
* Gentoo - no automated installer, apparently can be installed manually from live
* Salix 14.2 - has to be told to install from harddrive, and given both the device name and path to files on disk
* Slax 9.11.0 - no automated installer, apparently can be installed from live by copying files manually
* Gentoo - no automated installer, apparently can be installed manually from live
* Damn Small Linux 4.4.10 - difficult to use installer, not had a successful install from it yet, but it may work.

## Live environment only

* Kali Linux 2020.1
* Clonezilla
* Fatdog Linux 721
* Damn Small Linux 4.4.10
* Puppy Linux slacko 6.3.2 - installs, but installed system doesn't seem to boot
* Puppy Linux tahr 6.0.5 - installs, but installed system doesn't seem to boot
* Puppy Linux xenialpup 7.5 - installs, but installed system doesn't seem to boot
Expand Down
2 changes: 2 additions & 0 deletions distroflash.conf
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
# "append" is the boot parameters. This can include the variable '$(distdir)'
# which is the directory name that the distro will be installed to on disk

name="AntiX" id="antiX/vmlinuz" kernel="antiX/vmlinuz" initrd="antiX/initrd.gz" append="bdir=$(distdir)/antiX rootdelay=5 from=usb,cd,hd splasht disable=lxF xorg=safe"
name="Clonezilla" id="Clonezilla-Live-Version" kernel="live/vmlinuz" initrd="live/initrd.img" append="live-media-path=/$(distdir)/live boot=live union=overlay username=user config components noswap edd=on nomodeset nodmraid noeject locales= keyboard-layouts= ocs_live_run=ocs-live-general ocs_live_extra_param= ocs_live_batch=no ip= nosplash i915.blacklist=yes radeonhd.blacklist=yes nouveau.blacklist=yes vmwgfx.enable_fbdev=1 vga=791"
name="Damn Small Linux" id="boot/isolinux/linux24" kernel="boot/isolinux/linux24" initrd="boot/isolinux/minirt24.gz" append="ramdisk_size=100000 init=/etc/init lang=us apm=power-off vga=791 knoppix_dir=/$(distdir)/KNOPPIX"
name="Gentoo" id="isolinux/gentoo" kernel="isolinux/gentoo" initrd="isolinux/gentoo.xz" append="init=/linuxrc looptype=squashfs loop=/$(distdir)/image.squashfs cdroot subdir=$(distdir) console=tty1"
name="Kali" id="dists/kali-last-snapshot" kernel="live/vmlinuz" initrd="live/initrd.img" append="boot=live components splash hostname=kali live-media-path=/$(distdir)/live"
name="lUbuntu" id="preseed/lubuntu.seed" kernel="casper/vmlinuz" initrd="" append="file=$(distdir)/preseed/lubuntu.seed boot=casper ignore_uuid only-ubiquity initrd=$(distdir)/casper/initrd live-media-path=$(distdir)/casper"
Expand Down
13 changes: 9 additions & 4 deletions distroflash.lua
Original file line number Diff line number Diff line change
Expand Up @@ -255,6 +255,7 @@ end

function SetupDest()
local devname, devtype, removable, mounted
local from, to

--diskname is the name of the parent disk for a destination. For disk destinations devname and diskname will
--be the same. For partitions, for example /dev/sda1, devname=sda1 and diskname=sda
Expand Down Expand Up @@ -288,7 +289,11 @@ local devname, devtype, removable, mounted
Settings.Format=true
end

filesys.copy(Settings.SyslinuxDir .."/".. Settings.SyslinuxMBR, "/dev/"..diskname)
from=Settings.SyslinuxDir .."/".. Settings.SyslinuxMBR
to="/dev/"..diskname
print("install mbr: ".. from.. " to "..to)
filesys.copy(from, to)

Settings.tmpMount=("/tmp/.usb_install_"..tostring(process.pid()))
filesys.mkdir(Settings.tmpMount)
Settings.MountPoint=Settings.tmpMount
Expand Down Expand Up @@ -415,15 +420,15 @@ item=toks:next()
while item ~= nil
do
print("Install Syslinux: "..item)
filesys.copy(Settings.SyslinuxDir..item, Settings.MountPoint.."/boot/"..item)
filesys.copy(Settings.SyslinuxDir.."/"..item, Settings.MountPoint.."/boot/"..item)
item=toks:next()
end
end


function ActivateSyslinux()
print("Activate syslinux")
str=Settings.programs["syslinux"] .. " -m --install -d /boot "..Settings.InstallDest
str=Settings.programs["syslinux"] .. " --install -d /boot "..Settings.InstallDest
os.execute(str)
print("Activated: "..str)
end
Expand All @@ -432,7 +437,7 @@ end
function InitConfig()
local str

Settings.Version="1.0"
Settings.Version="1.1"
Settings.MountPoint="/mnt"
str=string.gsub(process.getenv("PATH"), "/bin", "/share")
Settings.SyslinuxDir=filesys.find("syslinux", str)
Expand Down

0 comments on commit bf6d2fe

Please sign in to comment.