Browse Source

chore(tools): add the gentoo grub_auto_install support (#827)

donjuanplatinum 9 months ago
parent
commit
6cf1947dcf
1 changed files with 16 additions and 5 deletions
  1. 16 5
      tools/grub_auto_install.sh

+ 16 - 5
tools/grub_auto_install.sh

@@ -38,14 +38,25 @@ export OBJCOPY=objcopy
 if [ -d ${grub_dir_i386_efi}/bin ] && [ -d ${grub_dir_i386_legacy}/bin ] && [ -d ${grub_dir_x86_64_efi}/bin ] ; then
 	exit 0
 fi
-#仅支持Ubuntu/Debain, Arch, Centos/RHEL8/Fedora下的自动安装
-supported_package_manager="apt-get pacman dnf"
+#仅支持Ubuntu/Debain, Arch, Centos/RHEL8/Fedora gentoo下的自动安装
+supported_package_manager="apt-get pacman dnf yum emerge"
 packages=("make binutils bison gcc gettext flex bison automake autoconf wget gawk" \
-          "make binutils bison gcc gettext flex bison automake autoconf wget gawk")
+              "make binutils bison gcc gettext flex bison automake autoconf wget gawk" \
+	      "make binutils bison gcc gettext flex bison automake autoconf wget gawk" \
+	      "make binutils bison gcc gettext flex bison automake autoconf wget gawk" \
+	      "dev-build/make sys-devel/binutils sys-devel/bison sys-devel/gcc sys-devel/gettext sys-devel/flex dev-build/automake dev-build/autoconf net-misc/wget sys-apps/gawk")
 update_options=("update" \
-                "-Sy")
+                    "-Sy" \
+		    "update" \
+		    "update" \
+		    "--sync"
+	       )
 install_options=("install -y" \
-                 "-S --needed --noconfirm")
+                     "-S --needed --noconfirm" \
+		     "install -y" \
+		     "install -y" \
+		     ""
+		)
 found_pm=0
 pm_index=0
 for pm in ${supported_package_manager}; do