glib-compile-resources

Compiles resource files (e.g. images) into a binary resource bundle. These may be linked into GTK applications using the GResource API. More information: <https://manned.org/glib-compile-resources>.

Install

All systems
curl cmd.cat/glib-compile-resources.sh
Debian Debian
apt-get install libglib2.0-dev-bin
Ubuntu
apt-get install libglib2.0-dev-bin
Arch Arch Linux
pacman -S glib2
image/svg+xml Kali Linux
apt-get install libglib2.0-dev-bin
CentOS
yum install glib2-devel
Fedora
dnf install glib2-devel
Windows (WSL2)
sudo apt-get update sudo apt-get install libglib2.0-dev-bin
Raspbian
apt-get install libglib2.0-bin

Compiles resource files (e.g. images) into a binary resource bundle. These may be linked into GTK applications using the GResource API. More information: <https://manned.org/glib-compile-resources>.

  • Compile resources referenced in `file.gresource.xml` to a .gresource binary:
    glib-compile-resources file.gresource.xml
  • Compile resources referenced in `file.gresource.xml` to a C source file:
    glib-compile-resources --generate-source file.gresource.xml
  • Compile resources in `file.gresource.xml` to a chosen target file, with `.c`, `.h` or `.gresource` extension:
    glib-compile-resources --generate --target=file.ext file.gresource.xml
  • Print a list of resource files referenced in `file.gresource.xml`:
    glib-compile-resources --generate-dependencies file.gresource.xml

© tl;dr; authors and contributors