glfs/shareddeps/checkpoint/whatnow.xml

302 lines
12 KiB
XML
Raw Normal View History

2024-06-07 21:06:03 +08:00
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
<!ENTITY % general-entities SYSTEM "../../general.ent">
%general-entities;
]>
<sect1 id="whatnow" xreflabel="What Now?">
<?dbhtml filename="whatnow.html"?>
<title>What Now?</title>
<para>
By now, you should have most of the packages needed to compile the following
packages after this section. The good news is you are now done with the
hardest part of this book. Congrats!
</para>
<para>
Well, how do you go from here? You could continue straight to the following
2024-08-04 08:35:41 +08:00
chapters if you wish. You can even now follow BLFS. But to run graphical
software you compile like <xref linkend="steam"/> and
<xref linkend="wine"/>, you will need a graphical environment. There are a
few components you will need in order to get a graphical environment
working and not accidently lock yourself inside of it without a hard reboot.
The installation of those components are not covered in this book and which
components you will need will depend on if you are going to use
<application>X11</application>, <application>Wayland</application>, or
both. This page acts as a simple nudge to help point you in the right
direction, and when you are done, can come back and continue on with the
next chapters.
2024-06-07 21:06:03 +08:00
</para>
<sect2>
<title>X11</title>
<para>
It is recommended to read up on the BLFS page
<ulink url="&blfs-svn;/x/xorg-config.html">Xorg-7 Testing and
Configuration</ulink>. It is pretty comprehensive. However, using
<xref linkend="nvidia"/> with <application>X11</application> requires
a slightly different setup.
</para>
<sect3>
<title>X11 With NVIDIA</title>
<para>
Using a conventional <filename>/etc/X11/xorg.conf</filename>
2024-07-22 09:54:12 +08:00
can lead to issues, if <application>X11</application> manages to
even start. In order to use the <application>NVIDIA</application>
driver when starting <application>X11</application>, run the following
command as the <systemitem class="username">root</systemitem> user:
2024-06-07 21:06:03 +08:00
</para>
<screen><userinput>nvidia-xconfig</userinput></screen>
<important>
<para>
The above command will overwrite the current <filename>
/etc/X11/xorg.conf</filename> configuration file. If you wish to
2024-07-22 09:54:12 +08:00
preserve it, move it out of the way or rename it.
</para>
2024-06-07 21:06:03 +08:00
</important>
<para>
If you desire to use a high refresh rate, using <command>cvt</command>
2024-07-22 09:54:12 +08:00
as the method will result in failure. When you start the server, launch
<command>nvidia-settings</command> as the <systemitem class="username">
root</systemitem> user and navigate to the
<quote>X Server Display Configuration</quote> section on the left sidebar
and change the Hz to the right of the screen size. Click
<quote>Apply</quote> if you are done, accept the changes, then click
<quote>Save to X Configuration File</quote> and if it gives the option,
choose to merge the file. Note that this method requires
<ulink url="&blfs-svn;/x/gtk3.html">GTK3</ulink>.
2024-06-07 21:06:03 +08:00
</para>
<para>
You should now be good to go.
</para>
</sect3>
<sect3>
<title>X11 Components</title>
<para>
There are typically three important components of an X11 environment:
</para>
<itemizedlist>
<listitem>
<para>a window manager or desktop environment</para>
</listitem>
<listitem>
2024-07-22 09:54:12 +08:00
<para>a terminal and/or launcher</para>
2024-06-07 21:06:03 +08:00
</listitem>
<listitem>
<para>and optionally a compositor</para>
</listitem>
</itemizedlist>
<sect4>
<title>Window Manager or Desktop Environment</title>
<para>
2024-07-22 09:54:12 +08:00
A window manager is an application that manages windows, their placement,
2024-06-07 21:06:03 +08:00
how they move, and more. It is a minimal option for a graphical environment,
2024-07-22 09:54:12 +08:00
not requiring a ton of packages and takes less disk and RAM usage. Good
window managers include <ulink url="https://awesomewm.org/">AwesomeWM</ulink>,
<ulink url="https://dwm.suckless.org/">DWM</ulink>, and
<ulink url="https://github.com/baskerville/bspwm">BSPWM</ulink>. In order
to start these window managers, add a line to <filename>~/.xinitrc
</filename>:
2024-06-07 21:06:03 +08:00
</para>
<screen><userinput>echo "exec <replaceable>&lt;WINDOW-MANAGER&gt;</replaceable>" &gt;&gt; ~/.xinitrc</userinput></screen>
<para>
Then launch it:
</para>
<screen><userinput>startx</userinput></screen>
<para>
A desktop environment is a more user friendly graphical environment and
2024-07-22 09:54:12 +08:00
provides much more than a standard window manager. It is also worth
noting that a desktop environment also includes a window manager. Good
desktop environments include
<ulink url="https://projects.linuxmint.com/cinnamon/">Cinnamon</ulink>,
<ulink url="&blfs-svn;/gnome/gnome.html">GNOME</ulink>, and
<ulink url="&blfs-svn;/kde/kde.html">KDE Plasma</ulink>. These can
require a lot of setup and uses more disk space and RAM. These should
be loaded by a display manager, like <ulink url="&blfs-svn;/x/sddm.html">
SDDM</ulink>. A display manager is often loaded by a service or daemon.
2024-06-07 21:06:03 +08:00
</para>
</sect4>
<sect4>
<title>Terminal or Launcher</title>
<para>
By this point, you should know what a terminal is, whether it be a TTY
2024-07-22 09:54:12 +08:00
or a graphical terminal. Terminals are almost a necessity and help
when you are in a pinch. You can launch most applications with a terminal.
This is useful when you have no other way to launch an application. There
are a wide variety of terminals and some integrate better with the system
depending on if you went with a window manager or desktop environment.
Check the Arch Wiki page
<ulink url="https://wiki.archlinux.org/title/Category:Terminal_emulators">
Category:Terminal emulators</ulink> for a comprehensive list on some
terminals you can go for and some on the page are in BLFS. If you decided
to go with a window manager, make sure to add a keybind for your chosen
terminal.
2024-06-07 21:06:03 +08:00
</para>
<para>
A launcher is what it sounds like: an application that launches the one
2024-07-22 09:54:12 +08:00
you ask it to. Some launch applications by the binary name in the
<envar>PATH</envar> variable, while others launch applications according
to desktop file entries. Desktop files are often located in <filename>
2024-06-07 21:06:03 +08:00
/usr/share/applications</filename> and <filename>
2024-07-22 09:54:12 +08:00
~/.local/share/applications</filename>. Don't be afraid to create your
own! It's okay to be creative sometimes. Check the Arch Wiki page
<ulink url="https://wiki.archlinux.org/title/Category:Application_launchers">
Category:Application launchers</ulink> for a comprehensive list on some
launchers you can go for. Desktop environments include their own
launcher and are often accessed via the <quote>start menu</quote>.
If you went with a window manager, make sure to add the keybind for the launcher.
2024-06-07 21:06:03 +08:00
</para>
</sect4>
<sect4>
<title>Compositor</title>
<para>
A compositor talks with <xref linkend="xorg-server"/> and can change
2024-07-22 09:54:12 +08:00
what is seen on screen. The changes compositors make on <application>
X11</application> can range from doing vsync, adding window animations
which helps with presentation, and opacity. They can be taxing for the
GPU if it is weak or the graphics driver isn't that performant. When
gaming, it might be a good idea to temporary kill the compositor.
These compositors aren't needed on <application>X11</application>;
however, they make the graphical environment look nicer. The choice
to have one is up to you. Check the Arch Wiki page
<ulink url="https://wiki.archlinux.org/title/Xorg#Composite">
Xorg Composite</ulink> for a list of compositors. In order to enable
them when starting a window manager, add the following line <emphasis>
2024-06-07 21:06:03 +08:00
BEFORE</emphasis> the <userinput><literal>exec ...</literal></userinput>
line:
</para>
<screen><userinput><literal><replaceable>&lt;compositor&gt;</replaceable> &amp;</literal></userinput></screen>
<para>
Desktop environments include their own and are started when the
2024-07-22 09:54:12 +08:00
desktop environment loads up.
2024-06-07 21:06:03 +08:00
</para>
</sect4>
</sect3>
</sect2>
<sect2>
<title>Wayland</title>
<para>
Wayland is much more simple to set up than <application>X11</application>.
Please read the X11 section above as much of the information is also
relevant to <application>Wayland</application>. There are a few changes,
however.
</para>
<sect3>
<title>NVIDIA</title>
<para>
Unlike X11, Wayland requires that the nvidia_drm module has the modeset
option set to true, which is not by default. Do so by creating the
following folder and file, then reboot:
</para>
<screen><userinput>mkdir -pv /etc/modprobe.d/nvidia.conf
cat &gt; /etc/modprobe.d/nvidia.conf &lt;&lt; "EOF"
<literal>options nvidia_drm modeset=1</literal></userinput></screen>
<para>
Then you will only need to worry about the refresh rate if it's applicable to
2024-07-04 15:40:11 +08:00
you. You won't need to worry about making sure the <application>NVIDIA
</application> driver is used when starting
<application>Wayland</application>. However, read through the
installation instructions for compositors as they will likely have
information regarding <application>NVIDIA</application>. Results can be
shotty, sometimes the compositor won't be able to start. Be diligent.
2024-06-07 21:06:03 +08:00
</para>
</sect3>
<sect3>
<title>Window Managers, Desktop Environments, and Compositors</title>
<para>
Unlike <application>X11</application> where components were more
seperated, especially when using a window manager, this is not the
case for <application>Wayland</application>. The window manager
and compositor will always be combined. Desktop environments will
combine both. This leaves the only things that need to be installed are
a terminal and perhaps a launcher. The minimal graphical environments
are called compositors instead of window managers, but desktop
environments are still called desktop environments.
</para>
<sect4>
<title>Compositors</title>
<para>
Many <application>X11</application> window managers do not have
<application>Wayland</application> support. There are some
unofficial ports that use certain reusable frameworks which would
be called an <application>X11</application> compositor, like
<ulink url="https://gitlab.freedesktop.org/wlroots/wlroots/">
wlroots</ulink> (these are called compositor libraries). You can
try some ports if you wish but some of them do their own thing
which you may not agree with.
</para>
<para>
Native <application>Wayland</application> compositors include
<ulink url="https://hyprland.org/">Hyprland</ulink>,
<ulink url="https://github.com/swaywm/sway">Sway</ulink>, and
<ulink url="https://github.com/WayfireWM/wayfire">Wayfire</ulink>.
In order to start these compositors, you can start them by using
a display manager or simply run the binary that is of the compositor
name. The choice is up to you how you wish to approach it.
</para>
</sect4>
<sect4>
<title>Desktop Environments</title>
<para>
Go with <ulink url="&blfs-svn;/gnome/gnome.html">GNOME</ulink> or
<ulink url="&blfs-svn;/kde/kde.html">KDE Plasma</ulink>. They have
good <application>Wayland</application> support. Like with <application>
X11</application>, you can launch these using a display manager.
</para>
</sect4>
</sect3>
</sect2>
</sect1>