From bc55542a602637ea4169b084c1b78aada0382ee7 Mon Sep 17 00:00:00 2001 From: "A. Wilcox" Date: Fri, 6 Dec 2019 21:00:29 -0600 Subject: Qt UI: Implement UI.Packages.Choices requirements --- ui/qt5/horizonwizard.cc | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) (limited to 'ui/qt5/horizonwizard.cc') diff --git a/ui/qt5/horizonwizard.cc b/ui/qt5/horizonwizard.cc index 4c12d72..50c526d 100644 --- a/ui/qt5/horizonwizard.cc +++ b/ui/qt5/horizonwizard.cc @@ -48,6 +48,7 @@ extern "C" { #include "datetimepage.hh" #include "hostnamepage.hh" #include "pkgsimple.hh" +#include "pkgdefaults.hh" #include "bootpage.hh" #include "rootpwpage.hh" #include "accountpage.hh" @@ -180,7 +181,11 @@ HorizonWizard::HorizonWizard(QWidget *parent) : QWizard(parent) { * Determine which platform kernel is being used, if any (-power8 etc) * Determine hardware requirements (easy or mainline) */ + grub = true; kernel = "easy-kernel"; + binsh = Dash; + sbininit = S6; + eudev = true; /* REQ: UI.Global.Back.Save */ setOption(IndependentPages); @@ -202,6 +207,7 @@ HorizonWizard::HorizonWizard(QWidget *parent) : QWizard(parent) { setPage(Page_DateTime, new DateTimePage); setPage(Page_Hostname, new HostnamePage); setPage(Page_PkgSimple, new PkgSimplePage); + setPage(Page_PkgCustomDefault, new PkgDefaultsPage); setPage(Page_Boot, new BootPage); setPage(Page_Root, new RootPassphrasePage); setPage(Page_Accounts, new AccountPage); @@ -358,6 +364,32 @@ QString HorizonWizard::toHScript() { lines << "pkginstall grub"; } + switch(this->binsh) { + case Dash: + lines << "pkginstall dash-binsh"; + break; + case Bash: + lines << "pkginstall bash-binsh"; + break; + } + + switch(this->sbininit) { + case S6: + lines << "pkginstall s6-linux-init"; + break; + case SysVInit: + lines << "pkginstall sysvinit"; + break; + } + + if(this->eudev) { + lines << "pkginstall eudev"; + } else { + lines << "pkginstall mdevd"; + } + + lines << "pkginstall sysklogd"; + lines << ("pkginstall " + QString::fromStdString(this->kernel) + " " + QString::fromStdString(this->kernel) + "-modules"); -- cgit v1.2.3-60-g2f50