Spyhawk/pacaur — Issue #58: aur pkgs versioning fails when installing provider pkg
Author: Spyhawk
Created: 2012-01-10 14:21:30+00:00
State: open
Labels: bug

AUR pkgs versioning check fails when installing provider pkg.
Note: I am currently not sure if that is a pacaur bug or the normal behavior of pacman.

Real life example:

pacaur depends of "cower>3.0.5", install "cower-git" that provides "cower":

```
pacaur -S cower-git
:: Package(s) cower-git not found in repositories, trying AUR...
:: cower-git and cower are in conflict. Remove cower? [y/N] y

AUR Targets (1): cower-git

Proceed with installation? [Y/n] y
:: Edit cower-git PKGBUILD? [Y/n] n
Password:
:: Building cower-git package...
==> Determining latest git revision...
-> Version found: 20120110
==> Making package: cower-git 20120110-1 (Tue Jan 10 15:13:11 CET 2012)
==> Checking runtime dependencies...
==> Checking buildtime dependencies...
==> Retrieving Sources...
==> Extracting Sources...
==> Starting build()...
==> Connecting to GIT server....
Cloning into 'cower'...
remote: Counting objects: 3001, done.
remote: Compressing objects: 100% (1018/1018), done.
remote: Total 3001 (delta 2036), reused 2942 (delta 1979)
Receiving objects: 100% (3001/3001), 504.10 KiB | 470 KiB/s, done.
Resolving deltas: 100% (2036/2036), done.
==> GIT checkout done or server timeout
==> Starting make...
cc -std=c99 -g -pedantic -Wall -Wextra -pthread -march=i686 -mtune=generic -O2 -pipe -fstack-protector --param=ssp-buffer-size=4 -D_FORTIFY_SOURCE=2 -DCOWER_VERSION=\"3.0.9-10-g6196ec2\" -c -o cower.o cower.c
pod2man --section=1 --center="Cower Manual" --name="COWER" --release="cower 3.0.9-10-g6196ec2" README.pod > cower.1
cc -o cower cower.o -lcurl -lalpm -lyajl -larchive -lcrypto -pthread -Wl,-O1,--sort-common,--as-needed,-z,relro,--hash-style=gnu
==> Entering fakeroot environment...
==> Starting package()...
install -D -m755 cower /home/remy/aur/build/cower-git/pkg/usr/bin/cower
install -D -m644 cower.1 /home/remy/aur/build/cower-git/pkg/usr/share/man/man1/cower.1
install -D -m644 bash_completion /home/remy/aur/build/cower-git/pkg/etc/bash_completion.d/cower
install -D -m644 zsh_completion /home/remy/aur/build/cower-git/pkg/usr/share/zsh/site-functions/_cower
install -D -m644 config /home/remy/aur/build/cower-git/pkg/usr/share/cower/config
==> Tidying install...
-> Purging unwanted files...
-> Compressing man and info pages...
-> Stripping unneeded symbols from binaries and libraries...
==> Creating package...
-> Generating .PKGINFO file...
-> Compressing package...
==> Leaving fakeroot environment.
==> Finished making: cower-git 20120110-1 (Tue Jan 10 15:13:19 CET 2012)
==> Installing package cower-git with pacman-color -U...
loading packages...
resolving dependencies...
looking for inter-conflicts...
:: cower-git and cower are in conflict. Remove cower? [y/N] error: failed to prepare transaction (could not satisfy dependencies)
:: pacaur: requires cower>3.0.5
==> WARNING: Failed to install built package(s).
:: Build directory cleaned
```

pacaur depends of "cower" (w/o versioning), install "cower-git" that provides "cower":

```
pacaur -S cower-git
:: Package(s) cower-git not found in repositories, trying AUR...
:: cower-git and cower are in conflict. Remove cower? [y/N] y

AUR Targets (1): cower-git

Proceed with installation? [Y/n] y
:: Edit cower-git PKGBUILD? [Y/n] n
:: Building cower-git package...
==> Determining latest git revision...
-> Version found: 20120110
==> Making package: cower-git 20120110-1 (Tue Jan 10 15:16:33 CET 2012)
==> Checking runtime dependencies...
==> Checking buildtime dependencies...
==> Retrieving Sources...
==> Extracting Sources...
==> Starting build()...
==> Connecting to GIT server....
Cloning into 'cower'...
remote: Counting objects: 3001, done.
remote: Compressing objects: 100% (1018/1018), done.
remote: Total 3001 (delta 2036), reused 2942 (delta 1979)
Receiving objects: 100% (3001/3001), 504.10 KiB | 484 KiB/s, done.
Resolving deltas: 100% (2036/2036), done.
==> GIT checkout done or server timeout
==> Starting make...
cc -std=c99 -g -pedantic -Wall -Wextra -pthread -march=i686 -mtune=generic -O2 -pipe -fstack-protector --param=ssp-buffer-size=4 -D_FORTIFY_SOURCE=2 -DCOWER_VERSION=\"3.0.9-10-g6196ec2\" -c -o cower.o cower.c
pod2man --section=1 --center="Cower Manual" --name="COWER" --release="cower 3.0.9-10-g6196ec2" README.pod > cower.1
cc -o cower cower.o -lcurl -lalpm -lyajl -larchive -lcrypto -pthread -Wl,-O1,--sort-common,--as-needed,-z,relro,--hash-style=gnu
==> Entering fakeroot environment...
==> Starting package()...
install -D -m755 cower /home/remy/aur/build/cower-git/pkg/usr/bin/cower
install -D -m644 cower.1 /home/remy/aur/build/cower-git/pkg/usr/share/man/man1/cower.1
install -D -m644 bash_completion /home/remy/aur/build/cower-git/pkg/etc/bash_completion.d/cower
install -D -m644 zsh_completion /home/remy/aur/build/cower-git/pkg/usr/share/zsh/site-functions/_cower
install -D -m644 config /home/remy/aur/build/cower-git/pkg/usr/share/cower/config
==> Tidying install...
-> Purging unwanted files...
-> Compressing man and info pages...
-> Stripping unneeded symbols from binaries and libraries...
==> Creating package...
-> Generating .PKGINFO file...
-> Compressing package...
==> Leaving fakeroot environment.
==> Finished making: cower-git 20120110-1 (Tue Jan 10 15:16:38 CET 2012)
==> Installing package cower-git with pacman-color -U...
loading packages...
resolving dependencies...
looking for inter-conflicts...
:: cower-git and cower are in conflict. Remove cower? [y/N]
Targets (2): cower-3.0.9-1 cower-git-20120110-1

Total Installed Size: 0.10 MiB
Net Upgrade Size: 0.00 MiB

Proceed with installation? [Y/n] (0/1) checking package integrity [-----------------------(1/1) checking package integrity [##################################################] 100%
(1/1) loading package files [##################################################] 100%
(1/1) checking for file conflicts [##################################################] 100%
(2/2) checking available disk space [##################################################] 100%
(1/1) removing cower [##################################################] 100%
(1/1) installing cower-git [##################################################] 100%
:: Build directory cleaned
```

Check if that is a pacaur bug, and if yes, find an elegant way to fix it.