commit: 2c58dc24df8cccf41d4126bb51e5cea8abaabb0f Author: Fabian Groffen <grobian <AT> gentoo <DOT> org> AuthorDate: Thu Nov 14 12:39:02 2019 +0000 Commit: Fabian Groffen <grobian <AT> gentoo <DOT> org> CommitDate: Thu Nov 14 12:39:02 2019 +0000 URL: https://gitweb.gentoo.org/proj/portage-utils.git/commit/?id=2c58dc24
qpkg: drop binpkgs in CATEGORY subdir for compliance emaint doesn't get a pile of binpkgs, so stash them where it expects them Signed-off-by: Fabian Groffen <grobian <AT> gentoo.org> qpkg.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/qpkg.c b/qpkg.c index 947ff84..7a1baae 100644 --- a/qpkg.c +++ b/qpkg.c @@ -29,6 +29,7 @@ #include "xarray.h" #include "xasprintf.h" #include "xchdir.h" +#include "xmkdir.h" #include "xpak.h" #define QPKG_FLAGS "cEpP:" COMMON_FLAGS @@ -309,7 +310,13 @@ qpkg_make(depend_atom *atom) unlink(filelist); - snprintf(buf, buflen, "%s/%s.tbz2", qpkg_bindir, atom_to_pvr(atom)); + /* create dirs, if necessary */ + snprintf(buf, buflen, "%s/%s", + qpkg_bindir, atom->CATEGORY); + mkdir_p(buf, 0755); + + snprintf(buf, buflen, "%s/%s/%s.tbz2", + qpkg_bindir, atom->CATEGORY, atom_to_pvr(atom)); if (rename(tbz2, buf)) { warnp("could not move '%s' to '%s'", tbz2, buf); free(buf);