2. インストール
pkg install -y xorg numlockx ja-font-migmix
pkg install -y sddm sddm-freebsd-black-theme hal cursor-neutral-white-theme
pkg install -y fluxbox
最終行の、「Fluxbox」のインストールは、一瞬で終わります。
2020年11月9日の時点で「Fluxbox」のバージョンは、下記の通りでした。
$ pkg info fluxbox
fluxbox-1.3.7_5
Name : fluxbox
Version : 1.3.7_5
Installed on : Mon Nov 9 15:08:57 2020 JST
Origin : x11-wm/fluxbox
Architecture : FreeBSD:12:amd64
Prefix : /usr/local
Categories : x11-wm
Licenses : MIT
Maintainer : jgh@FreeBSD.org
WWW : http://fluxbox.org/
Comment : Small and fast window manager based on BlackBox
Options :
DEBUG : off
DOCS : on
IMLIB2 : off
NLS : on
REMEMBER : on
SLIT : on
SYSTRAY : on
TOOLBAR : on
XINERAMA : on
XRENDER : on
Shared Libs required:
libXpm.so.4
libXext.so.6
libXrender.so.1
libXrandr.so.2
libfreetype.so.6
libfribidi.so.0
libfontconfig.so.1
libXinerama.so.1
libXft.so.2
libX11.so.6
Annotations :
FreeBSD_version: 1201000
repo_type : binary
repository : FreeBSD
Flat size : 2.79MiB
Description :
Fluxbox is a window manager based on BlackBox with some new features:
- Transparent menus
- Pixmap themes
- Window snapping
- Integrated bbkeys
- Iconbar
- Configurable titlebar (slit)
- Windows tabs
- Wheel scroll changes workspace
- KDE and partial Gnome support
WWW: http://fluxbox.org/
「FreeBSD 12.1 RELEASE」「FreeBSD 11.4 RELEASE」でのインストール時と、バージョンは、変わっていません。
3. SDDM カスタマイズ
ログイン画面の解像度を「1366x768」とし、キーボードレイアウトを「jp.106」にします。
「root」ユーザで
cat << EOF >> /usr/local/share/sddm/scripts/Xsetup
xrandr --output VGA-0 --mode 1366x768 --rate 60
setxkbmap -layout jp
EOF
ログイン画面のテーマとカーソルを変更します。
「root」ユーザのまま
sddm --example-config > /usr/local/etc/sddm.conf
vi /usr/local/etc/sddm.conf
[Theme]
# Current theme name
Current=breeze
# Cursor theme used in the greeter
CursorTheme=breeze_cursors
を下記へ変更します。
[Theme]
# Current theme name
Current=sddm-freebsd-black-theme
# Cursor theme used in the greeter
CursorTheme=Neutral++_White
4. .desktop ファイルの作成
ログイン時に有効となるよう、「.desktop」ファイルを作成します。
「root」ユーザで
mkdir -pv /usr/local/share/xsessions
cat - << EOF >> /usr/local/share/xsessions/fluxbox.desktop
[Desktop Entry]
Name=Fluxbox
Comment=A lightweight window manager for the X Windowing System
Exec=fluxbox
Terminal=false
TryExec=fluxbox
Type=Application
EOF
5. ユーザ用初期化ファイルの作成
「root」ユーザで
cat - << EOF >> /usr/share/skel/dot.xsession
#!/bin/sh
# set locale
export LC_ALL=ja_JP.UTF-8
export LANGUAGE=ja_JP.UTF-8
export LANG=ja_JP.UTF-8
#
/usr/local/bin/VBoxClient-all
#
setxkbmap -layout jp
numlockx &
EOF
chmod +x /usr/share/skel/dot.xsession
既存のログインユーザで
cp /usr/share/skel/dot.xsession ~/.xsession
6. /etc/rc.conf 編集
前項までインストール・設定したものを有効にします。
cat - << EOF >> /etc/rc.conf
polkitd_enable="YES"
dbus_enable="YES"
hald_enable="YES"
sddm_enable="YES"
EOF
7. ログインマネージャ起動
「root」ユーザで
service dbus start
service hald start
service sddm start
うまく設定できていれば、ログイン画面が表示されます。
ユーザ名・パスワードを入力してログインします。