OSDN Git Service

Start removal of offline install options
authornatemaia <natemaia10@gmail.com>
Mon, 3 Dec 2018 02:09:41 +0000 (18:09 -0800)
committernatemaia <natemaia10@gmail.com>
Sun, 17 Mar 2019 04:21:47 +0000 (21:21 -0700)
src/lib/dialogs.sh
src/lib/install.sh
src/lib/utils.sh

index 7b8f432..6428edd 100644 (file)
@@ -14,7 +14,7 @@ declare -g WARN=false
 declare -g AUTOLOGIN=false
 declare -g CONFIG_DONE=false
 declare -g SEPERATE_BOOT=false
-declare -g HAS_NETWORK=false
+declare -g BROADCOM_WL=false
 
 declare -g BT="$DIST Installer - (x86_64) - Version $VER"
 declare -g ROOT_PART=""
@@ -536,23 +536,12 @@ configure_system_settings()
     fi
 
     tput civis
-    if [[ $HAS_NETWORK == true ]]; then
-        if ! KERNEL="$(menubox "$_KernelTitle" "$_KernelBody" 0 0 0 'linux' '-' 'linux-lts' '-')"; then
-            return 1
-        fi
-        select_wm_or_de  || return 1
-        select_packages  || return 1
-        select_mirrorcmd || return 1
-    else
-        # defaults for when there is no network connection
-        KERNEL='linux'
-        AUTOLOGIN=true
-        LOGIN_TYPE='xinit'
-        INSTALL_WMS='openbox'
-        LOGIN_WM='openbox-session'
-        MIRROR_CMD="reflector --score 100 -l 50 -f 10 --sort rate --verbose"
-        EDIT_FILES[11]="/home/$NEWUSER/.xinitrc /home/$NEWUSER/.xprofile"
+    if ! KERNEL="$(menubox "$_KernelTitle" "$_KernelBody" 0 0 0 'linux' '-' 'linux-lts' '-')"; then
+        return 1
     fi
+    select_wm_or_de  || return 1
+    select_packages  || return 1
+    select_mirrorcmd || return 1
 
     export CONFIG_DONE=true
     return 0
index f6b322b..2ff0aea 100644 (file)
@@ -27,16 +27,12 @@ install()
     echeck "genfstab -U $MNT > $MNT/etc/fstab"
     [[ -f $MNT/swapfile ]] && sed -i "s~${MNT}~~" $MNT/etc/fstab
 
-    if [[ $HAS_NETWORK == true ]]; then
-        # update the mirrorlist..  MUST be done before updating or it may be slow
-        # this may already have been done if 
-        oneshot mirrorlist_sort
+    # update the mirrorlist..  MUST be done before updating or it may be slow
+    # this may already have been done if 
+    oneshot mirrorlist_sort
 
-        # MUST be before bootloader and running mkinitcpio
-        oneshot package_operations
-    else
-        chrun 'pacman -Rns archlabs-installer --noconfirm'
-    fi
+    # MUST be before bootloader and running mkinitcpio
+    oneshot package_operations
 
     # mkinitcpio and bootloader install should only be done after installing the packages
     # and updating the mirrorlist, otherwise the chosen kernel may not be fully set up
@@ -63,7 +59,6 @@ install_base()
         printf "\nUnpacking base system --- Total: ~ 2.9G\n\n"
         rsync -ah --info=progress2 /run/archiso/sfs/airootfs/ $MNT/
     else
-
         # update the mirrorlist..  MUST be done before pacstrapping or it may be slow
         oneshot mirrorlist_sort
 
@@ -112,7 +107,9 @@ EOF
     fi
 
     # copy network settings
-    [[ -e /etc/NetworkManager/system-connections ]] && cp -rf /etc/NetworkManager/system-connections $MNT/etc/NetworkManager/
+    if [[ -e /etc/NetworkManager/system-connections ]]; then
+        cp -rf /etc/NetworkManager/system-connections $MNT/etc/NetworkManager/
+    fi
     cp -f /etc/resolv.conf $MNT/etc/
 
 
@@ -126,10 +123,13 @@ EOF
     sed -i "s/#en_US.UTF-8/en_US.UTF-8/g; s/#${LOCALE}/${LOCALE}/g" $MNT/etc/locale.gen
     chrun "locale-gen" 2>/dev/null
 
-
     # set the timezone
     chrun "ln -sf /usr/share/zoneinfo/$ZONE/$SUBZONE /etc/localtime" 2>/dev/null
 
+    if [[ $BROADCOM_WL == true ]]; then
+        echo 'blacklist bcma' >> $MNT/etc/modprobe.d/blacklist.conf
+        rm -f $MNT/etc/modprobe/
+    fi
 
     # set the keymaps
     cat > $MNT/etc/X11/xorg.conf.d/00-keyboard.conf <<EOF
index 0f5c666..18a67de 100644 (file)
@@ -149,6 +149,13 @@ system_checks()
     [[ $(whoami) == "root" ]] || { infobox "$_ErrTitle" "$_NotRoot\n$_Exit" && die 1; }
     grep -qw 'lm' /proc/cpuinfo || { infobox "$_ErrTitle" "$_Not64Bit\n$_Exit" && die 1; }
 
+    if grep -qw 'BCM4352' <<< "$(lspci -vnn -d 14e4:)"; then
+        rmmod bcma >/dev/null 2>&1
+        rmmod wl >/dev/null 2>&1
+        modprobe wl >/dev/null 2>&1
+        export BROADCOM_WL=true
+    fi
+
     if ! curl -s --head 'https://www.archlinux.org/mirrorlist/all/' | sed '1q' | grep -qw '200'; then
         if [[ $(systemctl is-active NetworkManager) == "active" ]] && hash nmtui >/dev/null 2>&1; then
             tput civis; nmtui-connect