Nothin' but Slackware

バイクとLinuxに戯れる日々

2020年09月

Xfce-4.16pre1 リリース&テスト

Xfce-4.16pre1 がリリースされているので Slackware64-current の Xfce関連パッケージを
アップデートしてみた。

Xfce-4.16pre1 ソース元:

パッケージ作成のための SlackBuild は R.Workman氏のスクリプトを参考にさせていただいた。

[ 2020-11-15 更新}
下記情報に基づき、パッケージを更新した。
ほぼ、 Xfce-4.16pre2 に近い環境になったと思う。

ベース環境:
 ・ slackware64-current
 ・ elogind (ConsoleKit2 を削除)

アップグレード&新規インストールしたパッケージとバージョン:
(順不同) 2020-11-15 現在
※)
=================================================
exo-4.15.3-x86_64-1jw
garcon-0.7.2.1-x86_64-1jw ← リリース版ではない。 0.7.2 の gitソース
libdbusmenu-18.10.20180917~bzr492-x86_64-2jw
libgtop-2.38.0-x86_64-2jw
libxfce4ui-4.15.4-x86_64-4jw ← 「Xfceについて」のダイアログで表示されないicon があったのを修正
libxfce4util-4.15.4-x86_64-2jw
thunar-4.15.3-x86_64-1jw
thunar-volman-4.15.0-x86_64-2jw
tumbler-0.3.0.1-x86_64-2jw ← リリース版ではない。 0.3.0 の gitソース
upower-0.99.11-x86_64-2jw
xfce4-appfinder-4.15.2-x86_64-2jw
xfce4-dev-tools-4.15.1-x86_64-2jw
xfce4-panel-4.15.5-x86_64-2jw
xfce4-panel-profiles-1.0.10-x86_64-7jw
xfce4-power-manager-1.7.1-x86_64-1jw
xfce4-session-4.15.1-x86_64-1jw
xfce4-settings-4.15.3-x86_64-1jw
xfconf-4.15.1-x86_64-2jw
xfdesktop-4.15.1-x86_64-2jw
xfwm4-4.15.3-x86_64-2jw
Greybird-3.22.12-noarch-1_rlw
elementary-xfce-0.15-x86_64-1_rlw
libsass-3.6.4-x86_64-1_rlw
libwnck3-3.36.0-x86_64-2jw
sassc-3.6.1-x86_64-2_rlw
xfce4-clipman-plugin-1.6.1-x86_64-2_rlw
xfce4-notifyd-0.6.2-x86_64-2_rlw
xfce4-pulseaudio-plugin-0.4.3-x86_64-2_rlw
xfce4-screensaver-0.1.11-x86_64-2jw
xfce4-screenshooter-1.9.7-x86_64-2_rlw
xfce4-systemload-plugin-1.2.3-x86_64-2_rlw
xfce4-taskmanager-1.2.3-x86_64-2_rlw
xfce4-terminal-0.8.9.2-x86_64-2_rlw
xfce4-weather-plugin-0.10.1-x86_64-4_rlw
xfce4-whiskermenu-plugin-2.4.6-x86_64-1_rlw
mint-themes-1.8.5-noarch-1jw
Xfce-Theme-Manager-0.3.4-x86_64-1jw
=================================================

動作状況:
 ・ ストレスなく動作している
 ・ elogind 導入環境においてユーザーによる再起動、シャットダウンも問題無し
 ・ デスクトップ設定画面の背景色選択において、以前のバージョン(4.12) で可能だった
 スポイトによる色選択が無くなっていたのが惜しい。

参考画像:
 

Slackware64-current での elogind 導入テスト

Slackware64-current 環境で ConsoleKit2 から elogind に移行してみた。

elogind パッケージ作成のソースは R.Workman氏のソースを使わせていただいた。

Step-1) ConsoleKit2 削除
 elogind パッケージのインストール前に、ConsoleKit2 パッケージを削除する。
 # slackpkg remove ConsoleKit2
 # upgradepkg --install-new elogind-243.7-x86_64-1jw.txz

Step-2) 各種設定ファイルの編集、追加
1) /etc/pam.d/system-auth
   Add following one line to the bottom of /etc/pam.d/system-auth
----- >8 ----- >8 ----- >8 ----- >8 -----
#########################
# elogind setting       #
#########################
-session optional   pam_elogind.so

----- >8 ----- >8 -----    >8 ----- >8 -----

2) Add following one line to /etc/sudoers
----- >8 ----- >8 -----    >8 ----- >8 -----
# Added for elogind
%user  ALL=(ALL) NOPASSWD: /usr/lib64/xfce4/session/xfsm-shutdown-helper

----- >8 ----- >8 ----- >8 ----- >8 -----

3) Add /etc/polkit-1/rules.d/49-nopasswd_global.rules
----- >8 ----- >8 ----- >8 ----- >8 -----
/* Allow members of the wheel group to execute any actions

* without password authentication, similar to "sudo NOPASSWD:"

*/

polkit.addRule(function(action, subject) {

if (subject.isInGroup("wheel")) {

return polkit.Result.YES;

}

});

----- >8 ----- >8 ----- >8 ----- >8 -----

4) Add user to power group
# usermod -a -G power abe

5) Confirm [HOME]/.xinitrc
Re-confirm follwing settings at startxfce4 line

----- >8 ----- >8 ----- >8 ----- >8 -----
########################################################################
##  Start xfce Desktop Environment                                    ##
########################################################################

if [ -z "$DESKTOP_SESSION" -a -x /usr/bin/ck-launch-session ]; then
  exec ck-launch-session dbus-launch --exit-with-session /usr/bin/startxfce4
else
  exec dbus-launch --exit-with-session /usr/bin/startxfce4
fi
----- >8 ----- >8 ----- >8 ----- >8 -----


[ Update 2020-10-02 ]
polkit-0.118--enable-libelogind=yes サポートでリビルド&インストールするためにやったこと

glibc-2.32 へアップグレード(必須かどうか定かではないが)
linux-doc-tools をリビルド&インストール
 参考) 64-current のChangeLogsより
 +--------------------------+
    Tue Sep 15 18:51:00 UTC 2020
    a/libgudev-234-x86_64-1.txz: Upgraded.
    ap/htop-3.0.2-x86_64-1.txz: Upgraded.
    l/glib2-2.66.0-x86_64-2.txz: Rebuilt.
       Build against system gtk-doc and don't bundle a newer version. You'll need
       to reinstall the linuxdoc-tools package to restore the correct version of
       gtk-doc. Thanks to chrisVV.


[ Update 2020-10-03 ]
dbus-1.12.20--enable-elogind サポートでリビルド&インストールするためにやったこと
・ 自環境では dbusコンパイルのために autocon-archive が必要であった。
     autoconf-archive-2019.01.06 をインストール。(参考:SlackBuild )
dbus-1.12.20 リビルド(参考:R.Workman氏のソース

modified PlamoBuild.ghostscript-9.52

PlamoBuild.ghostscript-9.52 を自分のカスタム環境用に編集した。

・カスタマイズの目的:
 1) ghostscript の source に含まれている CJK表示確認用の psファイル類が
   plamolinux デフォルトの ghostscriptパッケージに含まれていないので
   /usr/share/ghostscript/9.52/examples / に配置するよう修正した。
 2)cidfmap に幾つか追記し、WadaMin-RegularH や HeiseiKakuGo-W5 などの
   非埋め込みフォント指定されている psファイルも日本語表示されるようにした。

$ cat PlamoBuild.ghostscript-9.52
-----------------------------------------------------------------------------------------------------
#!/bin/sh
##############################################################
pkgbase='ghostscript'
vers="9.52"
url="https://github.com/ArtifexSoftware/ghostpdl-downloads/releases/download/gs${vers/./}/${pkgbase}-${vers}.tar.xz"
digest="md5sum:2dd455dba172010b46225819a5485389"
#fonturl="https://downloads.sourceforge.net/gs-fonts/ghostscript-fonts-std-8.11.tar.gz
#	https://downloads.sourceforge.net/gs-fonts/gnu-gs-fonts-other-6.0.tar.gz"
fonturl="https://downloads.sourceforge.net/gs-fonts/ghostscript-fonts-std-8.11.tar.bz2"
verify=""
arch=`uname -m`
build=B5
src="${pkgbase}-${vers}"
OPT_CONFIG="--enable-dynamic
	--with-ijs
	--with-jbig2dec
	--with-x
	--with-drivers=ALL
	--enable-fontconfig
	--enable-freetype
	--enable-openjpeg
        --enable-cups
        --enable-dynamic 
     	--with-system-libtiff
	--with-libpaper
	--disable-compile-inits"
fontpath="/usr/share/ghostscript/fonts
	/usr/share/fonts
        /usr/share/fonts/TTF
	/usr/share/poppler/cMap/"
DOCS='LICENSE'
# CVE-2020-15900
# https://github.com/ArtifexSoftware/ghostpdl/commit/5d499272b95a6b890a1397e11d20937de000d31b.patch
patchfiles="5d499272b95a6b890a1397e11d20937de000d31b.patch"
compress=txz
##############################################################

source /usr/share/plamobuild_functions.sh

# このスクリプトで使う1文字変数の意味
#
# $W : このスクリプトを動かすカレントディレクトリ
# $S : ソースコードのあるディレクトリ(デフォルト: $W/${src})
# $B : ビルド用ディレクトリ(デフォルト: /tmp/build{,32})
# $P : ビルドしたファイルをインストールするディレクトリ(デフォルト: $W/work)


if [ $# -eq 0 ] ; then
  opt_download=0 ; opt_config=1 ; opt_build=1 ; opt_package=1
else
  opt_download=0 ; opt_config=0 ; opt_build=0 ; opt_package=0
  for i in $@ ; do
    case $i in
    download) opt_download=1 ;;
    config) opt_config=1 ;;
    build) opt_build=1 ;;
    package) opt_package=1 ;;
    esac
  done
fi
if [ $opt_download -eq 1 ] ; then
  download_sources
  for f in $fonturl
  do
    if [ ! -f ${f##*/} ]; then
      wget $f
    fi
  done
fi

if [ $opt_config -eq 1 ] ; then
  if [ -d $B ] ; then rm -rf $B ; fi ; cp -a $S $B
######################################################################
#  don't copy sources, so need patch in the src dir
######################################################################
  cd $B
  for patch in $patchfiles ; do
    patch -p1 < $W/$patch
  done

  # force to use system libraries
  # rm -r cups/libs freetype ijs jpeg lcms2 libpng openjpeg tiff zlib
  # use in-tree freetype because bug
  rm -rf freetype jpeg lcms2 libpng libtiff png tiff zlib
  autoreconf -vi
  ( cd jbig2dec ; autoreconf --force --install )
  ( cd ijs ; autoreconf --force --install )

  # fontpath
  fp=
  for p in $fontpath
  do
      fp=${fp}:$p
  done
  fp=${fp/:/}

  export PKG_CONFIG_PATH=/usr/${libdir}/pkgconfig:/usr/share/pkgconfig:/opt/kde/${libdir}/pkgconfig
  export LDFLAGS='-Wl,--as-needed' 
  ./configure --prefix=/usr --sysconfdir=/etc --localstatedir=/var --mandir='${prefix}'/share/man ${OPT_CONFIG} \
	      --with-fontpath="$fp"
    
  if [ $? != 0 ]; then
    echo "configure error. $0 script stop"
    exit 255
  fi
fi
    
if [ $opt_build -eq 1 ] ; then
  cd $B
  export LDFLAGS='-Wl,--as-needed'
  make
  make so
  if [ $? != 0 ]; then
    echo "build error. $0 script stop"
    exit 255
  fi
fi

if [ $opt_package -eq 1 ] ; then
  check_root
  if [ -d $P ] ; then rm -rf $P ; fi ; mkdir -p $P
  cd $B
  export LDFLAGS='-Wl,--as-needed'
  make install DESTDIR=$P
  make soinstall DESTDIR=$P

  # Don't ship .la files:
  pushd $P
    for lafile in usr/lib/*.la ; do
      rm -f ${lafile} /${lafile}
    done
  popd

  # copy examples to /usr/share/ghostscript/${vers}/
  cp -a $S/examples $P/usr/share/ghostscript/${vers}/

  # remove man of de
  rm -rfv $P/usr/share/man/de

  # header
  install -v -m644 base/*.h $P/usr/include/ghostscript
  ln -v -s ghostscript $P/usr/include/ps

  # install cidfmap
  # install -v -m644 -D $W/cidfmap $P/usr/share/ghostscript/${vers}/Resource/Init/cidfmap

  cat <<"EOF" >> $P/usr/share/ghostscript/${vers}/Resource/Init/cidfmap
/ipag 	 << /FileType /TrueType /Path (/usr/share/fonts/TTF/ipag.ttf) 	/SubfontID 0 /CSI [ (Japan1) 6 ] >> ;
/ipagp 	 << /FileType /TrueType /Path (/usr/share/fonts/TTF/ipagp.ttf) 	/SubfontID 0 /CSI [ (Japan1) 6 ] >> ;
/ipam	 << /FileType /TrueType /Path (/usr/share/fonts/TTF/ipam.ttf) 	/SubfontID 0 /CSI [ (Japan1) 6 ] >> ;
/ipamp	 << /FileType /TrueType /Path (/usr/share/fonts/TTF/ipamp.ttf) 	/SubfontID 0 /CSI [ (Japan1) 6 ] >> ;
/Ryumin-Light		/ipam ;
/Ryumin-Medium		/ipam ;
/GothicBBB-Medium	/ipag ;
/ChuGothicBBB-Medium	/GothicBBB-Medium	;
/ChuGothicBBB-Medium-Mono	/MS-Gothic	;
/FutoGoB101-Bold	/GothicBBB-Medium	;
/FutoMinA101-Bold	/Ryumin-Light		;
/GothicMB101-Bold	/GothicBBB-Medium	;
/GothicMB101-hea	/GothicBBB-Medium	;
/GothicMB101-Ult	/GothicBBB-Medium	;
/ShinGo-Bold		/GothicBBB-Medium	;
/ShinGo-Medium		/GothicBBB-Medium	;
/ShinGo-regular		/GothicBBB-Medium	;
/MS-Gothic		/ipag			;
/MS-PGothic		/ipagp			;
/MSPGothic		/ipagp			;
/MSMincho		/ipam			;
/MS-Mincho		/ipam			;
/MS-PMincho		/ipamp			;
/MSPMincho		/ipamp			;
/HeiseiMin-W3		/Ryumin-Light		;
/HeiseiKakuGo-W5 	/GothicBBB-Medium	;
/Kochi-Mincho      	/Ryumin-Light		;
/Kochi-Gothic      	/GothicBBB-Medium	;
/WadaMin-Regular	/ipam			;
/WadaMin-RegularH	/ipam			;
/WadaMin-Bold		/ipam			;
/WadaGo-Regular		/ipag			;
/WadaGo-RegularH        /ipag                   ;
/WadaGo-Bold		/ipag			;
/Adobe-Japan1      	/Ryumin-Light		;
/Adobe-Japan2      	/Ryumin-Light		;
EOF

  # install std_font
  for f in $fonturl
  do
    tar xvf $W/${f##*/} --no-same-owner -C $P/usr/share/ghostscript/
  done

  # link to /usr/share/fonts
  mkdir -p $P/usr/share/fonts
  ln -sfv ../ghostscript/fonts $P/usr/share/fonts/gsfonts

  mkdir -p $P/install
  cat <> $P/install/initpkg
if [ -x /usr/bin/fc-cache ]; then
  /usr/bin/fc-cache -v 
fi
EOF

################################
#      install tweaks
#  strip binaries, delete locale except ja, compress man, 
#  install docs and patches, compress them and  chown root.root
################################
  install_tweak

  # move doc dir
  mv -v $P/usr/share/doc/ghostscript/${vers}/* $docdir/$src/
  rm -rfv $docdir/ghostscript

#############################
#   convert symlink to null file and 
#   add "ln -sf" command into install/doinst.sh
################################
  convert_links

  cd $P
  /sbin/makepkg ../$pkg.$compress <y
1
EOF

fi
------------------------------------------------------------------------------------------------------------------
アップデート後の表示テスト結果

$ gv /usr/share/ghostscript/9.52/examples/cjk/all_aj1.ps
 (HeiseiKakuGo-W5 フォントを ipaゴシックフォントでエミュレーション)
gs-all_aj1.ps_emulate_HeiseiKakuGo-W5

このページ(11ページ目)を印刷コマンドでプリンタに流したところ、
問題なくゴシック体で印刷できた。
( $ lp /usr/share/ghostscript/9.52/examples/cjk/all_aj1.ps -P 11 -d HP_Photosmart_5520 )

$ gv /usr/share/ghostscript/9.52/examples/cjk/all_aj2.ps
 (WadaMin-RegularH フォントを ipa明朝フォントでエミュレーション)
gs-all_aj2.ps_emulate_WadaMin-RegularH

ギャラリー
  • deepl-clip.sh で簡単翻訳 [更新:2025-04-29]
  • Avidemux 2.8.2_20250323_7cf15b3
  • Avidemux 2.8.2_20250323_7cf15b3
  • Avidemux 2.8.x with Qt6 GUI
  • Avidemux 2.8.x with Qt6 GUI
  • MEGAcmd-2.0.0_Linux
  • gcolor3 with Japanese menu and LC_MESSAGES
  • avidemux2 TEST package from the latest git source (on jul.23.2024)
  • fcitx5-mozc-2.29.5135.102.1 (15jw) -- Added "merge-ut-dictionaries"