162 lines
6.3 KiB
Plaintext
162 lines
6.3 KiB
Plaintext
.docname {Graphical Environment}
|
|
.include {docs}
|
|
|
|
The steps necessary to install graphics drivers are very dependent on your device. This guide details the settings I use
|
|
for my own hardware.
|
|
|
|
For general instructions, consult the [Arch Linux Wiki: Graphics][arch-wiki-graphics].
|
|
|
|
## Intel Graphics i915 / xe / Arc
|
|
|
|
Since Intel provides and supports open source drivers, Intel graphics are essentially plug-and-play. This guide details
|
|
some customized and improved settings, based on my personal preferences.
|
|
|
|
### Installation
|
|
|
|
Install (`sudo pacman -S ...`) the following packages
|
|
|
|
- `mesa`: open source OpenGL implementation for most modern drivers, including intel i915 3rd gen hardware
|
|
- `mesa-utils`: Utilities for `mesa`
|
|
- `vulkan-intal`: Vulkan support for intel hardware
|
|
- `vulkan-tools`: Vulkan utilities
|
|
- `intel-media-driver`: for VA-API support
|
|
- `libva-utils`: Utilities for VA-API
|
|
- `vdpauinfo`: Utilities for VDPAU
|
|
- `nvtop` Utility to show graphics card usage
|
|
|
|
Then reboot the computer.
|
|
|
|
### Enable GuC / HuC Firmware Loading
|
|
|
|
Depending on the hardware support, GuC and HuC should be en abled by default. You can check this by running the
|
|
following commands
|
|
|
|
```sh
|
|
cat /sys/kernel/debug/dri/0/gt0/uc/guc_info
|
|
cat /sys/kernel/debug/dri/0/gt0/uc/huc_info
|
|
```
|
|
|
|
> Tip: `0` might need to be replaced by a different number in the commands above. The files will only exist if GuC /
|
|
> HuC are enabled during boot. A reboot might be required if you cannot see them, or GuC / HuC is disabled in the
|
|
> system.
|
|
|
|
If GuC / HuC is disabled, you can manually enable it. Create the file `/etc/modprobe.d/i915.conf`
|
|
|
|
```txt
|
|
option i915 enable_guc=2
|
|
```
|
|
|
|
Possible options:
|
|
|
|
- `1`: Enable GuC but not HuC
|
|
- `2`: Enable Huc, but not GuC
|
|
- `3`: Enable HuC and GuC
|
|
|
|
.example {Dell XPS 13 9370 (2018)}
|
|
Supported option is `option i915 enable_guc=2`
|
|
|
|
.example {DELL XPS 13 9350 (2024)}
|
|
The xe driver is still experimental. Once it becomes mainline, GuC/HuC will be enabled by default.
|
|
|
|
Then regenerate and sign the initramfs with `mkinictpio -P`
|
|
|
|
> Warning: Manually enabling GuC or HuC firmware loading taints the kernel even when the feature is not supported.
|
|
> Moreover, enabling Guc / HuC firmware loading can cause issues on some systems; disable it if you experience freezing
|
|
> (for example, after resuming from hibernation).
|
|
|
|
### Intel ARC
|
|
|
|
Intel ARC GPUs support hardware raytracing support through onboard TSUs. Current performance is mixed.
|
|
For intel ARC, `linux-firmware-intel` should be installed on the system. It likely is from the base install already.
|
|
|
|
## AMD Graphics
|
|
|
|
AMD releases their drivers as open source. There are also closed source drivers available for special usecases. This
|
|
guide will only focus on the open source drivers.
|
|
|
|
Install (`sudo pacman -S ...`) the following packages
|
|
|
|
- `mesa` modern OpenGL drivers for most hardware
|
|
- `mesa-utils` utility programs for mesa
|
|
- `vulkan-radeon` vulkan support
|
|
- `vulkan-tools` utility programs for vulkan
|
|
- `libva-mesa-driver` to support accelerated video decoding using VA-API
|
|
- `libva-utils` utility programs for VA-API
|
|
- `mesa-vdpau` support for VDPAU
|
|
- `vdpauinfo` utility programs for VDPAU
|
|
- `nvtop` to monitor temparature, clock speed, and usage of the graphics card
|
|
|
|
Then reboot the system.
|
|
|
|
|
|
## Reboot
|
|
|
|
Do not forget to reboot the system after changes to the graphics drivers have been made.
|
|
|
|
## Install Hyprland
|
|
|
|
To install Hyprland, install the following packages that will include some necessary utilities for the system
|
|
|
|
```sh
|
|
yay -S --needed \
|
|
hyprland hyprpaper hypridle hyprlock waybar wofi kitty nemo gvfs gvfs-mtp gvfs-smb \
|
|
xdg-desktop-portal xdg-desktop-portal-hyprland xdg-desktop-portal-gtk xdg-utils \
|
|
wl-clipboard grim slurp swaync network-manager-applet polkit polkit-gnome chezmoi \
|
|
wev btop qt5-wayland qt6-wayland qt5ct qt6ct gtk-engine-murrine \
|
|
colloid-catppuccin-gtk-theme papirus-icon-theme breeze-icons \
|
|
pipewire pipewire-audio pipewire-alsa pipewire-pulse pipewire-jack wireplumber \
|
|
pavucontrol alsa-utils \
|
|
ttf-bitstream-vera ttf-croscore ttf-dejavu ttf-droid gnu-free-fonts ttf-libreation \
|
|
ttf-libertinus otf-libertinus noto-fonts ttf-roboto ttf-ubuntu-font-family \
|
|
ttf-anonymous-pro ttf-cascadia-code ttf-fira-mono otf-fira-mono inter-font \
|
|
ttf-ms-fonts ttf-vista-fonts ttf-roboto-mono-nerd ttf-firacode-nerd \
|
|
otf-firamono-nerd otf-font-awesome \
|
|
noto-fonts-emoji noto-fonts-cjk noto-fonts-extra ttf-jetbrains-mono \
|
|
ttf-jetbrains-mono-nerd \
|
|
firefox librewolf-bin thunderbird \
|
|
git make gcc curl ripgrep fzf jq tar unzip inotify-tools socat brightnessctl \
|
|
xdg-user-dirs fastfetch figlet openssh tmux man-db man-pages usbutils pciutils \
|
|
uwsm libnewt
|
|
```
|
|
|
|
You can now start hyprland with `uwsm start hyprland.desktop`.
|
|
|
|
## Automatic Configuration
|
|
|
|
A lot of the paage installation and configuration in the `$HOME` and `$HOME/.config` folders can be automated
|
|
with `chezmoi`.
|
|
|
|
1. Make sure that `chezmoi` is installed on the system with `pacman -S chezmoi`.
|
|
2. Then run the following command to clone and apply configuration files from the `fz-stack` dotfiles repository.
|
|
You can modify the path you want to checkout the dotfiles to by modifying the `-S ...` argument.
|
|
|
|
```sh
|
|
chezmoi -S $HOME/Projects/fz-stack/dotfiles init ssh://git@zechert.net:fz-stack/dotfiles.git
|
|
```
|
|
|
|
> Tip: The applied `~/.bashrc` will set up an alias to call `chezmoi` without the need to specify the `-S ...`
|
|
> argument everytime. If you install the dotfiles to a different place than the `$HOME/Projects/fz-stack/dotfiles`
|
|
> mentioned here, you will need to change this alias in the `.bashrc` configuration file.
|
|
|
|
## Automatic Login on TTY1
|
|
|
|
If the system is used by a single user, and the disk encryption password is known only to this user, it might be
|
|
desirable to automatically log in this user when the computer starts.
|
|
|
|
Create a drop-in file for `getty@tty1.service` with the following contents in `/etc/systemd/system/getty@tty1.service.d/autologin.conf`.
|
|
|
|
```ini
|
|
[Service]
|
|
ExecStart=
|
|
ExecStart=-/sbin/agetty -o '-p -f -- \\u' --noclear --autologin <username> %I $TERM
|
|
```
|
|
|
|
After the automatic login of the user, Hyprland will be started on TTY1 by the `uwsm` commands
|
|
in the `~/.bash_profile` file. On other TTYs, Hyprland will not be started automatically.
|
|
|
|
## Create Default User Directories
|
|
|
|
Execute the command `xdg-user-dirs-update` to create or update the default user directories.
|
|
|
|
[arch-wiki-graphics]: https://wiki.archlinux.org/title/Category:Graphics
|