On Sun, Jun 10, 2018 at 10:18:21 -0400, Eli Schwartz via arch-general wrote: > On 06/10/2018 09:53 AM, Tinu Weber wrote: > > On Sun, Jun 10, 2018 at 09:20:38 -0400, Eli Schwartz via arch-general wrote: > >>On 06/10/2018 09:11 AM, Tinu Weber wrote: > >>> I tried building mlocate myself, but I run into this error with makepkg: > >>> > >>> ==> Making package: mlocate 0.26.git.20170220-1 (Sun 10 Jun 2018 15:03:17 CEST) > >>> ==> Checking runtime dependencies... > >>> ==> Checking buildtime dependencies... > >>> ==> Retrieving sources... > >>> ==> ERROR: /home/ayekat/devel/pkgbuilds/mlocate/trunk/mlocate is not a clone of https://pagure.io/mlocate.git > >>> Aborting... > >>> > >>> Same error with makechrootpkg. I can't find anything weird with the > >>> mlocate PKGBUILD though. > >> > >> The obvious question would be... since makepkg (not makechrootpkg) told > >> you that that directory is not a clone of that url, then what is it a > >> clone of instead? > > > > It is not a git repo at all (or rather just > > https://git.archlinux.org/svntogit/packages.git). > > > >> I'm not sure how much clearer we could make that error message. If > >> there's something makepkg is doing dreadfully wrong in that error > >> message reporting, please tell us so we can fix it... > > > > No, the error message is clear so far, but why would that even be an > > issue at that point? From what I've seen, for git sources, makepkg > > fetches them into a bare repository. But in the case of mlocate, it just > > creates `mlocate` and `mlocate/src` (empty directory), and then > > complains and errors out. > > What src directory??? Ah, I'm sorry, it's: ~/devel/pkgbuilds/mlocate/trunk/mlocate/ ~/devel/pkgbuilds/mlocate/trunk/mlocate/src/ rather than: ~/devel/pkgbuilds/mlocate/trunk/mlocate/ ~/devel/pkgbuilds/mlocate/trunk/mlocate/branches/ ~/devel/pkgbuilds/mlocate/trunk/mlocate/config ~/devel/pkgbuilds/mlocate/trunk/mlocate/... (other bare repo things) > Hm... oh, wait, this is probably https://bugs.archlinux.org/task/58865 > > I'm going to take a wild guess that some component of > /home/ayekat/devel/pkgbuilds/mlocate/trunk/mlocate is a symlink. Oh, you're right, ~/devel/pkgbuilds is a symlink to ~/.local/var/lib/pacman/pkgbuilds. Building mlocate in the "real" path works (or at least, it errors out a lot later due to a failing test). I now also notice that this is actually the case for all other packages in ~/devel/pkgbuilds that clone a git repo. > ... > > This does explain why it thinks you've got an invalid clone. It's > considering that directory to be the already-cloned sources, *because* > it's an existing directory which is not empty. This despite the fact > that it's only non-empty due to a makepkg bug from 2012 which only > recently got exposed. > > So instead of cloning the source, it is trying to pull the source, after > checking git config --get remote.origin.url (which fails because it's > not a repo, and therefore it's checking the parent repo which is > actually an svntogit checkout). > > You could work around that by using $BUILDDIR, in which case it will > create srcdir=$BUILDDIR/mlocate/src as intended (instead of > srcdir=$PWD/mlocate/src which is not intended) BUILDDIR works if I give it another directory. But `BUILDDIR="$(pwd -P)" makepkg` still fails (but to be honest, that's more me just trying random things I don't really understand, based on https://lists.archlinux.org/pipermail/pacman-dev/2018-June/022579.html ^^). But either way, thanks a lot for the support! (also, sorry for sort of hijacking the thread) Best, Tinu P.S. To confirm the original assumption: after modifying Makefile.am accordingly, package() fails here: ... chgrp locate "/home/ayekat/.local/var/lib/pacman/pkgbuilds/mlocate/trunk/pkg/mlocate/var/lib/mlocate" \ && chmod g=rx,o= "/home/ayekat/.local/var/lib/pacman/pkgbuilds/mlocate/trunk/pkg/mlocate/var/lib/mlocate" chgrp: invalid group: ‘locate’ make[2]: *** [Makefile:1455: install-exec-local] Error 1 ... So I second Eli's suggestion to report this upstream as a bug.
Attachment:
signature.asc
Description: PGP signature