gpg --batch --no-permission-warning \ --import ./pubdemo.asc gpg: keybox '/Users/fabian/Gentoo-10.10/var/tmp/portage/app-crypt/gpgme-1.10.0/work/gpgme-1.10.0/tests/gpg/pubring.kbx' created gpg: /Users/fabian/Gentoo-10.10/var/tmp/portage/app-crypt/gpgme-1.10.0/work/gpgme-1.10.0/tests/gpg/trustdb.gpg: trustdb created gpg: key 2D727CC768697734: public key "Alfa Test (demo key) <alfa@example.net>" imported gpg: can't connect to the agent: File name too long gpg: key FE180B1DA9E3B0B2: public key "Bob (demo key)" imported gpg: can't connect to the agent: File name too long gpg: key 413F4AF31AFDAB6C: public key "Charlie Test (demo key) <charlie@example.net>" imported gpg: can't connect to the agent: File name too long gpg: key EBA9F240EB9DC9E6: public key "Delta Test (demo key) <delta@example.net>" imported gpg: can't connect to the agent: File name too long gpg: key 318C1FAEFAEF6D1B: public key "Echelon (demo key)" imported gpg: can't connect to the agent: File name too long gpg: key D4BF57F37372E243: public key "Foxtrot Test (demo key) <foxtrot@example.net>" imported gpg: can't connect to the agent: File name too long gpg: key 168410A48FC282E6: public key "Golf Test (demo key) <golf@example.net>" imported gpg: can't connect to the agent: File name too long gpg: key 13DB965534C6E3F1: public key "Hotel Test (demo key) <hotel@example.net>" imported gpg: can't connect to the agent: File name too long gpg: key 1FE8FC6F04259677: public key "India Test (demo key) <india@example.net>" imported gpg: can't connect to the agent: File name too long gpg: key 0C820C71D2699313: public key "Juliet Test (demo key) <juliet@example.net>" imported gpg: can't connect to the agent: File name too long gpg: key AD1B0FAD43C2D0C7: public key "Kilo Test (demo key) <kilo@example.net>" imported gpg: can't connect to the agent: File name too long gpg: key 37CAB51FB79103F8: public key "Lima Test (demo key) <lima@example.net>" imported etc. gpg: can't connect to the agent: File name too long gpg: Total number processed: 26 gpg: imported: 26 make[3]: *** [Makefile:1110: pubring-stamp] Error 2 make[3]: Leaving directory '/Users/fabian/Gentoo-10.10/var/tmp/portage/app-crypt/gpgme-1.10.0/work/gpgme-1.10.0/tests/gpg' make[2]: *** [Makefile:693: all-recursive] Error 1 make[2]: Leaving directory '/Users/fabian/Gentoo-10.10/var/tmp/portage/app-crypt/gpgme-1.10.0/work/gpgme-1.10.0/tests' make[1]: *** [Makefile:507: all-recursive] Error 1 make[1]: Leaving directory '/Users/fabian/Gentoo-10.10/var/tmp/portage/app-crypt/gpgme-1.10.0/work/gpgme-1.10.0' make: *** [Makefile:438: all] Error 2 * ERROR: app-crypt/gpgme-1.10.0::gentoo_prefix failed (compile phase): The build env uses abs_builddir, which is obviously too long in this Portage context. Please consider disabling these tests during install, or consider shortening the socket path (perhaps use something like /var/tmp/$RANDOM so this can never be set to a too long string?) such that this package can be installed.
Modifying the title as obviously it can be more helpful.
The gnupg home cannot be placed outside of package as you seen while breaking the build, as it should contain more than only the socket. I will disable the tests when path is too long.
I don't see why it can't be placed outside of "package", if that is what you think is what I did, because that works just fine for people with default setups? (= stable amd64 non-prefix Linux) Obviously sandbox will not just accept writing to /var/tmp, but most preferable would IMO be to just disable the testing if it isn't required, such that by default stuff doesn't have special length requirements. PORTAGE_TMPDIR can be set appropriately (as you suggest as workaround I understand) by testers that way, but anyone doing anything (tinderboxy) fancy with it is likely to run into that limit.
My change isn't right, so the issue at hand really is a problem to install this package even when it would run once installed. What can we do to make the package install when we're on a location which exceeds the length limit of unix socket paths?
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=667661ef848cdf373d55784a00158c630135fedb commit 667661ef848cdf373d55784a00158c630135fedb Author: Alon Bar-Lev <alonbl@gentoo.org> AuthorDate: 2018-01-06 20:44:52 +0000 Commit: Alon Bar-Lev <alonbl@gentoo.org> CommitDate: 2018-01-06 20:46:45 +0000 app-crypt/gpgme: fail pretend if workdir is too long Bug: https://bugs.gentoo.org/643696 Package-Manager: Portage-2.3.13, Repoman-2.3.3 app-crypt/gpgme/gpgme-1.10.0.ebuild | 16 ++++++++++++++++ 1 file changed, 16 insertions(+)}
I gave slack as much as I could, however, the build also fails if WORKDIR is too long as gpg cannot import artifacts during build. If on your system it magically works, we need to figure out how come your usock definition/limitations are different than the common ones.
Thanks. How about something like passing --disable-gpg-test to configure and then running make -C tests from src_test()? Would that be acceptible to you? Something like that would at least allow installing gpgme, while it would unconditionally die portage right now.
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0a4d9e09377bf103f34eb3ae945cd1e2d181df8b commit 0a4d9e09377bf103f34eb3ae945cd1e2d181df8b Author: Alon Bar-Lev <alonbl@gentoo.org> AuthorDate: 2018-01-07 18:10:39 +0000 Commit: Alon Bar-Lev <alonbl@gentoo.org> CommitDate: 2018-01-07 18:10:55 +0000 app-crypt/gpgme: skip tests when WORKDIR is too long Closes: https://bugs.gentoo.org/643696 Package-Manager: Portage-2.3.13, Repoman-2.3.3 app-crypt/gpgme/gpgme-1.10.0.ebuild | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-)
(In reply to Fabian Groffen from comment #7) > Thanks. How about something like passing --disable-gpg-test to configure > and then running make -C tests from src_test()? Would that be acceptible to > you? Something like that would at least allow installing gpgme, while it > would unconditionally die portage right now. we do not abuse the upstream packages. I provided alternate solution that may be usable.