From 3d977da3de1ebe4fd4232929f6bff8faf2c09636 Mon Sep 17 00:00:00 2001 From: superconvert Date: Thu, 15 Sep 2022 15:04:22 +0000 Subject: [PATCH] add upowerd script --- mk_xfce.sh | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/mk_xfce.sh b/mk_xfce.sh index b4a0e80..98e3117 100755 --- a/mk_xfce.sh +++ b/mk_xfce.sh @@ -815,6 +815,11 @@ common_build() { fi done + # 让 upower.service 能正常启动, 还需要替换系统的 libglib 库 + # sed -i "s/LockPersonality/#LockPersonality/g" ${xfce_install}/lib/systemd/system/upower.service + # sed -i "s/SystemCallArchitectures/#SystemCallArchitectures/g" ${xfce_install}/lib/systemd/system/upower.service + # sed -i "s/SystemCallFilter/#SystemCallFilter/g" ${xfce_install}/lib/systemd/system/upower.service + # 编译 xfce cd ${XFCE_SRC_DIR} @@ -886,11 +891,18 @@ if [ "${with_xfce_test}" = true ]; then rm /usr/local/share/X11/xkb -rf ln -s /usr/share/X11/xkb /usr/local/share/X11 + + # xfdesktop 需要库的路径, xfdesktop 不能运行,基本上桌面就是黑屏了,可能有 dock 栏和最上面的状态栏 libdir=`pwd`"/a/usr" libpath="${libdir}/lib:${libdir}/local/lib:${libdir}/lib/x86_64-linux-gnu" libjpegdir=`pwd`"/a/opt/libjpeg-turbo/lib64" + # 可以让 xrdp 调用,也可以手工启动 echo "LD_LIBRARY_PATH=\"${libpath}:${libjpegdir}\" xfce4-session" > ~/.xsession + # 不用起服务的方式了,太麻烦 + echo "LD_LIBRARY_PATH=\"${libpath}:${libjpegdir}\" /usr/libexec/upowerd -rd" > ~/.upowerd + chmod +x ~/.xsession + chmod +x ~/.upowerd # 整个流程说明 # 0. 运行说明