Building gnome-keyring in a flatpak

I’ve had to build gnome-keyring in my attempt to make a flatpak of gitahead. I’ve run into the issue of cmake not finding gnome-keyring. could someone point me in the right direction. I’m building gnome keyring like so as without this the install segment tries to write outside the flatpak.

  - name: gnome-keyring
    buildsystem: simple
    - type: archive
      sha256: a3d24db08ee2fdf240fbbf0971a98c8ee295aa0e1a774537f4ea938038a3b931
    - ./configure && make
    - make install DESTDIR=${FLATPAK_DEST}/

I am not familiar with gitahead, but in case you don’t know, the keyring is conceptually part of the host system, and applications should communicate with it over portals (instead of bundling it). See the “Secret” portal
If your Flatpak uses the GNOME Platform runtime, you don’t need to bundle libsecret.

Anyway, gnome-keyring is built with autotools. So simply change the buildsystem entry to autotools in your flatpak manifest and drop the entire build-commands section.

gitahead is a qt application so I am gnome-keyring and libsecret from source since I am using the KDE runtime. gitahead has gnome-keyring and libsecret as a build dep. I will try your suggestion to use autools as the buildsystem

using autotools I get a error since it tires to create and install files in places it shouldn’t

 /usr/bin/mkdir -p '/usr/share/p11-kit/modules'
 /usr/bin/install -c -m 644 pkcs11/rpc-layer/gnome-keyring.module '/usr/share/p11-kit/modules'
/usr/bin/install: cannot create regular file '/usr/share/p11-kit/modules/gnome-keyring.module': Read-only file system
make[3]: *** [Makefile:6300: install-pkcs11configDATA] Error 1
make[3]: Leaving directory '/run/build/gnome-keyring'
make[2]: *** [Makefile:7291: install-am] Error 2
make[2]: Leaving directory '/run/build/gnome-keyring'
make[1]: *** [Makefile:6348: install-recursive] Error 1
make[1]: Leaving directory '/run/build/gnome-keyring'
make: *** [Makefile:7285: install] Error 2
Error: module gnome-keyring: Child process exited with code 2