一、编译Linux From Scratch
此步骤是基础,默认大家可以正常编译,参考链接
https://www.linuxfromscratch.org/lfs/
二、编译X Window System Environment
- Xorg-Server-1.20.13
https://www.x.org/pub/individual/xserver/xorg-server-1.20.13.tar.xz - 先设置bash环境
The following instructions assume that the shell startup files have been set up as described in The Bash Shell Startup Files.
https://www.linuxfromscratch.org/blfs/view/stable-systemd/postlfs/profile.html - 后设置Xorg Build环境
Setting up the Xorg Build Environment
export XORG_PREFIX="<PREFIX>"
export XORG_CONFIG="--prefix=$XORG_PREFIX --sysconfdir=/etc \
--localstatedir=/var --disable-static"
cat > /etc/profile.d/xorg.sh << EOF
XORG_PREFIX="$XORG_PREFIX"
XORG_CONFIG="--prefix=\$XORG_PREFIX --sysconfdir=/etc --localstatedir=/var --disable-static"
export XORG_PREFIX XORG_CONFIG
EOF
chmod 644 /etc/profile.d/xorg.sh
source /etc/profile.d/xorg.sh
sed "s@/usr/X11R6@$XORG_PREFIX@g" -i /etc/man_db.conf
ln -svf $XORG_PREFIX/share/X11 /usr/share/X11
三、GNOME
- gnome-shell-40.4
https://download.gnome.org/sources/gnome-shell/40/gnome-shell-40.4.tar.xz
四、设置xinitrc
Xorg sessions
- For the GNOME on Xorg session, add to the ~/.xinitrc file
export XDG_SESSION_TYPE=x11
export GDK_BACKEND=x11
exec gnome-session gnome-shell
- For the GNOME Classic session, add to the ~/.xinitrc file
export XDG_CURRENT_DESKTOP=GNOME-Classic:GNOME
export GNOME_SHELL_SESSION_MODE=classic
exec gnome-session gnome-shell
测试镜像:
链接:https://pan.baidu.com/s/1dNU3as-8c289xLkecHoE6A
提取码:ran2
参考链接:
https://wiki.archlinux.org/title/GNOME
https://www.cnblogs.com/black/p/5171729.html
https://wayland.freedesktop.org/architecture.html
https://feater.top/xwayland/xwayland-learning-indexes
https://help.gnome.org/admin/gdm/3.26/preface.html.zh_CN
http://www.slackbook.org/html/x-window-system-xinitrc.html
https://help.gnome.org/admin/gdm/stable/configuration.html.en
https://www.linuxfromscratch.org/blfs/view/6.3/gnome/config.html
https://www.systutorials.com/docs/linux/man/1-gnome-session/#:~:text=The%20gnome-session%20program%20starts%20up%20the%20GNOME%20desktop,gdm%2C%20xdm%2C%20or%20from%20your%20X%20startup%20scripts%29.
https://www.cnblogs.com/cnland/archive/2013/01/18/2866214.html
https://www.cnblogs.com/nightnine/p/14696471.html