The Shared Mime Info package contains a MIME database. This allows central updates of MIME information for all supporting applications.
Optional download, required to run the test suite: https://anduin.linuxfromscratch.org/BLFS/xdgmime/xdgmime.tar.xz
Install Shared Mime Info by running the following commands:
If you wish to run the test suite, you must first extract the
xdgmime
tarball into the current
directory, and compile it so that meson can find it:
tar -xf ../xdgmime.tar.xz && make -C xdgmime
Now build the package:
mkdir build && cd build && meson setup --prefix=/usr --buildtype=release -D update-mimedb=true .. && ninja
If you have followed the instructions above to build xdgmime, to test the result issue ninja test.
Now, as the root
user:
ninja install
--buildtype=release
:
Specify a buildtype suitable for stable releases of the package, as
the default may produce unoptimized binaries.
-D update-mimedb=true
: This
parameter tells the build system to run update-mime-database during
installation. Otherwise, this must be done manually in order to be
able to use the MIME database.