Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

aurto doesn't install makedeps when updating vcs packages #93

Open
bjo81 opened this issue Mar 27, 2024 · 8 comments · May be fixed by #103
Open

aurto doesn't install makedeps when updating vcs packages #93

bjo81 opened this issue Mar 27, 2024 · 8 comments · May be fixed by #103

Comments

@bjo81
Copy link

bjo81 commented Mar 27, 2024


 srcver: makepkg --nobuild --nodeps --skipinteg failed for path /var/tmp/build/.cache/aurutils/sync/conduwuit-git with exit 4
 ==> Making package: conduwuit-git 0.7.0.2615.g7809f0a6-1 (Wed 27 Mar 2024 08:30:56 AM CET)
 ==> WARNING: Skipping dependency checks.
 ==> Retrieving sources...
   -> Updating conduwuit git repo...
 From https://github.com/girlbossceo/conduwuit
  - [deleted]           (none)             -> 2024-03-23
  - [deleted]           (none)             -> renovate/async-trait-0.x
  - [deleted]           (none)             -> renovate/clap-4.x
  - [deleted]           (none)             -> renovate/docker-26.x
  - [deleted]           (none)             -> renovate/reqwest-0.x
  - [deleted]           (none)             -> renovate/serde_json-1.x
  - [deleted]           (none)             -> renovate/serde_yaml-0.x
  - [deleted]           (none)             -> renovate/tracing-opentelemetry-0.x
  - [deleted]           (none)             -> refs/pull/205/merge
  - [deleted]           (none)             -> refs/pull/218/merge
  - [deleted]           (none)             -> refs/pull/219/merge
  - [deleted]           (none)             -> refs/pull/223/merge
  - [deleted]           (none)             -> refs/pull/230/merge
  - [deleted]           (none)             -> refs/pull/232/merge
  - [deleted]           (none)             -> refs/pull/233/merge
  - [deleted]           (none)             -> refs/pull/234/merge
    101cb34f..051668b6  main               -> main
  + 0a1fed23...00cbcc90 refs/pull/230/head -> refs/pull/230/head  (forced update)
  * [new ref]           refs/pull/235/head -> refs/pull/235/head
  * [new ref]           refs/pull/236/head -> refs/pull/236/head
 ==> WARNING: Skipping all source file integrity checks.
 ==> Extracting sources...
   -> Creating working copy of conduwuit git repo...
 From /var/tmp/build/.cache/aurutils/sync/conduwuit-git/conduwuit
    101cb34f..051668b6  main       -> origin/main
 Reset branch 'makepkg'
 ==> Starting prepare()...
 /var/tmp/build/.cache/aurutils/sync/conduwuit-git/PKGBUILD: line 26: cargo: command not found
 ==> ERROR: A failure occurred in prepare().
     Aborting...

cargo is in makedeps.

@alexheretic
Copy link
Owner

I can't reproduce, this package starts building with cargo fine for me.

Perhaps ensure aurutils is up to date and try to reproduce using it directly:

aur sync --no-view --no-confirm --database=aurto -k0 --chroot --makepkg-conf=/etc/aurto/makepkg-chroot.conf --pacman-conf=/etc/aurto/pacman-chroot.conf conduwuit-git

@bjo81
Copy link
Author

bjo81 commented Mar 27, 2024

The initial build went also fine here, and aurutils are uptodate.

Running your above command leads to

dependency conduwuit satisfied by aurto/conduwuit-git
sync: there is nothing to do

Here's the complete output when /usr/lib/aurto/check-vcs exists:

Running: aur sync --no-view --no-confirm --database=aurto --upgrades -k0 --chroot --makepkg-conf=/etc/aurto/makepkg-chroot.conf --pacman-conf=/etc/aurto/pacman-chroot.conf
==> Using [aurto] repository
sync: there is nothing to do
Checking 4 VCS packages matching .*-(cvs|svn|git|hg|bzr|darcs)$ for updates...
srcver: makepkg --nobuild --nodeps --skipinteg failed for path /var/lib/build/.cache/aurutils/sync/conduwuit-git with exit 4
==> Making package: conduwuit-git 0.7.0.2615.g7809f0a6-1 (Wed 27 Mar 2024 10:39:23 AM CET)
==> WARNING: Skipping dependency checks.
==> Retrieving sources...
  -> Cloning conduwuit git repo...
Cloning into bare repository '/var/lib/build/.cache/aurutils/sync/conduwuit-git/conduwuit'...
==> WARNING: Skipping all source file integrity checks.
==> Extracting sources...
  -> Creating working copy of conduwuit git repo...
Cloning into 'conduwuit'...
done.
==> Starting prepare()...
/var/lib/build/.cache/aurutils/sync/conduwuit-git/PKGBUILD: line 26: cargo: command not found
==> ERROR: A failure occurred in prepare().
    Aborting...
8<----
 VCS packages up to date ✓
aurto.db is up to date
==> no candidate packages found for pruning

@alexheretic
Copy link
Owner

srcver: makepkg --nobuild --nodeps --skipinteg failed for path /var/lib/build/.cache/aurutils/sync/conduwuit-git with exit 4

Look suspicious. The vcs update goes

  • aur sync conduwuit-git --no-ver-argv --no-build --no-view --database=aurto to ensure aurutils git cache in initialised.
  • Then /usr/lib/aurto/aur-vercmp-devel --database=aurto prints out the outdated packages
  • Then aurto remove $pkg + aurto add $pkg

Yours seems to be failing somewhere along the way. What do you get if you run the first step?

@bjo81
Copy link
Author

bjo81 commented Mar 28, 2024

I've switched my buildsystem back to aurutils alone, but I'll try to reproduce the issue within a aurto docker container.

But btw, the same issue exists when using https://github.com/aurutils/aurutils/blob/master/examples/vercmp-devel within standalone aurutils.

@alexheretic
Copy link
Owner

Could be a issue with aur-vercmp then? If you can reproduce it with aurutils you can try reporting it upstream.

@AladW
Copy link

AladW commented Apr 1, 2024

aurutils/aurutils#771

@rabidpug
Copy link

rabidpug commented Sep 1, 2024

Not sure if it's doing something undesirable that I haven't noticed.. but changing the below from aur-vercmp-devel:

# Note that valid PKGBUILDs cannot contain \n in pkgname.
get_latest_revision() {
    grep -Fxf - <(printf '%s\n' *) | xargs -r aur srcver
}

to

# Note that valid PKGBUILDs cannot contain \n in pkgname.
get_latest_revision() {
    grep -Fxf - <(printf '%s\n' *) | xargs -r aur srcver --no-prepare
}

seems to fix the issue?

@bbx0
Copy link

bbx0 commented Oct 20, 2024

Starting v0.14.0 the new sync-devel needs the --no-prepare patch.

$ sudo sed -i 's/aur srcver /aur srcver --no-prepare /' /usr/lib/aurto/sync-devel
diff --git a/lib/aurto/sync-devel b/lib/aurto/sync-devel
index 686591e..dfede7f 100644
--- a/lib/aurto/sync-devel
+++ b/lib/aurto/sync-devel
@@ -49,7 +49,7 @@ done <"$tmp"/fetch_results
 # Update `epoch:pkgver-pkgrel` for each target with `aur-srcver`.
 # This runs `makepkg`, cloning upstream to the latest revision. The
 # output is then compared with the contents of the local repository.
-aur vercmp -p <(aur srcver "${targets[@]}") <"$tmp"/db | awk '{print $1}' >"$tmp"/ood
+aur vercmp -p <(aur srcver --no-prepare "${targets[@]}") <"$tmp"/db | awk '{print $1}' >"$tmp"/ood
 
 if [[ -s $tmp/ood ]]; then
     aur build -a "$tmp"/ood "${build_args[@]}"

When doing this, it's worth to consider pinning the file and to scan for pacnew files in /usr after upgrades.

[options]
NoUpgrade = usr/lib/aurto/sync-devel
$ sudo DIFFSEARCHPATH=/usr pacdiff --find

@bbx0 bbx0 linked a pull request Oct 20, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants