Adding dependencies to ruby packages

For hiera-eyaml (a ruby program which provides eyaml) I am trying to add the optional dependency hiera-eyaml-gpg, which in turn has an optional dependency of either gpgme or ruby_gpg. gpgme is already available as a ruby package in nixpkgs, but hiera-eyaml-gpg isn’t.

Puppet also depends on hiera-eyaml as a library, so for this I need to add the same dependency.

I’ve been searching for a clean solution the past couple of hours (that does not involve redefining the entire package), but didn’t get anything working. Does someone have leads on how to inject these dependencies? Both packages have no optional flags to include this, nor have I been able to find a way to define additional gemsets for both programs.