DSBMC is a Qt5 client which allows accessing the functions the mounting daemon DSBMD provides, like mounting/unmounting media and disk images, and setting the reading speed of CD/DVD drives.
# cd DSBMC
# cmake -S . -B build
# cmake --build build
# cmake --build build -t installInstall DSBMD via pkg(8)
# pkg install dsbmdor via the FreeBSD Ports
# cd /usr/ports/sysutils/dsbmd
# make install distcleanEnable vfs.usermount
# sysctl vfs.usermount=1and make it permanent by adding the line vfs.usermount=1 to
/etc/sysctl.conf:
# echo 'vfs.usermount=1' >> /etc/sysctl.confThis allows DSBMD to mount media as regular user, and it allows you to unmount devices you mounted without having special privileges. That is, you can unmount media using your filemanager.
Finally, enable DSBMD in /etc/rc.conf, and start it
# sysrc dsbmd_enable=YES
# service dsbmd startEach device which can be mounted by DSBMD is represented by an icon matching
the device type (CD/DVD, HDD, USB disk, MMC SD card, PTP (camera), MTP), and
a label. If possible, the volume label of the device is used. Otherwise, the
name of the device node (e.g. da0p1) is used. Mounted devices are represented
by a folder icon.
The status bar at the bottom of the main window shows the device node name, the capacity, and the number of free bytes of the selected device. The number of free bytes is 0 if the device is a CD/DVD or if it’s not mounted. Depending on the size, the unit is GB, MB, or KB.
The visibility of the main window can be toggled by pressing DSBMC's tray icon. Pressing the window’s close button will minimize it to tray. Every time a new device is added to the system, the main window and a balloon message pops up. You can control this behavior under File → Preferences → General settings → Behavior. The theme used for the tray icon can be changed under File → Preferences → Tray Icon Theme.
Each device icon provides a context menu which offers the possible actions of a device, like Mount, Unmount, Play, etc. Except for audio CDs, all device icons can be double-clicked to mount the device and open its mount point in a filemanager. The commands for opening mount points (filemanager) and playing media can be defined under File → Preferences → Commands.
The mounting daemon (DSBMD) accesses disk image files through the memory
disk interface (md(4)). You can open an image file via filemanager,
by letting it open the file with DSBMC, or you can use the command line:
% dsbmc /path/to/image/file.imgOne or more md devices will appear in the main window, which you can mount
like any other device.
Depending on the type of device, the Eject action behaves differently:
If mounted, the device is first unmounted, and then detached from the CAM subsystem. This flushed all the device’s caches and makes sure pending data gets written. Finally, the device node will be removed.
|
💡
|
Eject your Kindle if you want to use it while charging on your computer. |
If you want devices to be automatically mounted when they are inserted, you can enable automount under File → Preferences → Behavior.
If you don’t want certain devices, partitions, or mount points to appear
in the main window, like EFI partitions, you can add the device’s node
path (e.g. /dev/da0s1) to the comma separated Ignore Devices list under
File → Preferences → Ignore Devices. It is also possible to use
the device’s volume Label (e.g. EFISYS).
If you want CD/DVDs to be played automatically when inserted, you can enable Autoplay for each media type separately under File → Preference → Commands.
Let’s say you want to add French translations, you can proceed as follows:
-
Create a fork of this repo, and clone it:
% git clone url-of-your-fork
-
Install devel/qt5-linguist
-
cdtoyour-forked-dsbmc-dir -
Add
locale/dsbmc_fr.tsto theTS_FILESlist inCMakeLists.txt. -
In order to create the
dsbmc_fr.tsfile, runQt5% cmake -S . -B build % cmake --build buildor
Qt6% cmake -D USE_QT6=ON -S . -B build % cmake --build build -t dsbmc_lupdate -
Run
linguist locale/dsbmc_fr.ts -
Add the file to the repo:
git add locale/dsbmc_fr.ts -
Commit:
git commit -am 'Add French translations.' -
Send a pull request.
If you are not using a desktop environment like KDE or GNOME, there are two ways to control the appearance of Qt5 applications:
qt5ct is a tool that allows you to
configure themes, fonts, and icons of Qt5 applications.
It can be installed via pkg
# pkg install qt5ctor via the FreeBSD ports:
# cd /usr/ports/misc/qt5ct
# make installIn order to make Qt5 applications use qt5ct, add the line
export QT_QPA_PLATFORMTHEME=qt5ct to one of the following files, depending
on how you start your X session:
| X Session Start Method | File |
|---|---|
SliM, startx, xinit |
|
GDM, LightDM, LXDM, SDDM |
|
WDM, XDM |
|
Alternatively, you can add the line to your window manager’s startup
script, or, if you are using a Bourne shell compatible login shell, to
your ~/.profile.
After loggin out and in again, proceed with the next section.
Kvantum is a SVG-based theme
engine for Qt, KDE and LXQt. Install it via pkg:
# pkg install Kvantum-qt5or via the FreeBSD ports:
# cd /usr/ports/x11-themes/Kvantum
# make install distcleanStart qt5ct and choose kvantum under Appeareance → Style, and
press Ok.
|
💡
|
You can use Kvantum directly without qt5ct by setting
|
Now you can start kvantummanager to set, install and configure themes.
|
💡
|
You can download Kvantum themes from KDE Store. Unpack them, and use the Kvantum Manager to install new themes. |
Qt5-style-plugins
is a theme engine which allows using GTK-2 themes with Qt5 applications.
Install it via pkg
# pkg install qt5-style-pluginsor via the FreeBSD ports
# cd /usr/ports/x11-themes/qt5-style-plugins
# make install distcleanIn order to make Qt5 applications use qt5-style-plugins, add the line
export QT_QPA_PLATFORMTHEME=gtk2 to one of the following files, depending
on how you start your X session:
| X Session Start Method | File |
|---|---|
SliM, startx, xinit |
|
GDM, LightDM, LXDM, SDDM |
|
WDM, XDM |
|
Alternatively, you can add the line to your window manager’s startup
script, or, if you are using a Bourne shell compatible login shell, to
your ~/.profile.
After loggin out and in again, your Qt5 applications should look like your GTK applications.


