You are not logged in.

#1 2022-04-20 01:59:22

shoelesshunter
Member
Registered: 2014-05-18
Posts: 199

swapping package dependencies

I want to install the package ffmpeg-full from the AUR. however, this conflicts with ffmpeg. I can't uninstall ffmpeg as a lot of my packages depend on it.

is there a trick to just swap two packages when the existing one is a dependency?

thanks.

Offline

#2 2022-04-20 02:24:19

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 26,706
Website

Re: swapping package dependencies

ffmpeg-full provides ffmpeg.  So you just install it - pacman will prompt you to remove the other which it will do in the same transaction, so all dependent packages will be fine.

Last edited by Trilby (2022-04-20 02:25:06)


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Online

#3 2022-04-20 04:47:45

shoelesshunter
Member
Registered: 2014-05-18
Posts: 199

Re: swapping package dependencies

as I install the dependencies for ffmpeg-full, this happens:

libopenmpt-svn and libopenmpt are in conflict. Remove libopenmpt? [y/N] y
error: failed to prepare transaction (could not satisfy dependencies)
:: removing libopenmpt breaks dependency 'libopenmpt.so=0-64' required by mpd
 -> exit status 1

without uninstalling mpd and the many clients that depend on it, is there a way to proceed?

thanks.

Offline

#4 2022-04-20 06:33:30

WorMzy
Forum Moderator
From: Scotland
Registered: 2010-06-16
Posts: 10,711
Website

Re: swapping package dependencies

Build packages in a clean chroot.

https://wiki.archlinux.org/title/Develo … ean_chroot

Mod note: moving to AUR Issues


Sakura:-
Mobo: MSI MEG B550 UNIFY // Processor: AMD Ryzen 9 5950X @4.9GHz // GFX: AMD Radeon RX 5700 XT // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 6x 1TB SSD, 2x 120GB SSD, 1x 275GB M2 SSD

Making lemonade from lemons since 2015.

Offline

#5 2022-04-20 12:24:13

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 26,706
Website

Re: swapping package dependencies

A chroot build will not really help here.  Mpd apparently has a versioned dependency which is the actual problem.  If mpd only dependended on libopenmpt you would not get this error as libopenmpt-svn provides libopenmpt - it just doesn't provided the specific version that mpd requires.

Depending on a specific version of a dependency (i.e, using = rather than just >=) is fairly rare, and I'd question if it is strictly necessary for mpd.  But as long as the mpd package has that requirement, you will not be able to install ffmpeg-full and mpd at the same time - even if you are able to build in a chroot.  You'll either need a build of mpd that can use the version of libopenmpt provided by libopenmpt-svn, or you'll need to remove mpd.  I doubt any other packages would have such a versioned dependency issue.

Last edited by Trilby (2022-04-20 12:27:52)


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Online

#6 2022-04-20 14:03:39

stanczew
Member
Registered: 2021-03-02
Posts: 25

Re: swapping package dependencies

MPD doesn't depend on a specific version of libopenmpt, but rather on libopenmpt.so. The version is added during build, and is not specified in PKGBUILD:
https://github.com/archlinux/svntogit-p … GBUILD#L73
https://wiki.archlinux.org/title/PKGBUILD#Dependencies

If the dependency name appears to be a library, e.g. depends=('libfoobar.so'), makepkg will try to find a binary that depends on the library in the built package and append the soname version needed by the binary.

It works with default libopenmpt package, because it specifies libopenmpt.so in provides:
https://github.com/archlinux/svntogit-p … GBUILD#L23

libopenmpt-svn on the other hand doesn't have the .so in provides:
https://aur.archlinux.org/cgit/aur.git/ … penmpt-svn

Adding libopenmpt.so to provides in libopenmpt-svn PKGBUILD should do the trick.

Edit:
This will work only if both packages produce the same version of the library; see the post below.

Last edited by stanczew (2022-04-20 16:56:16)

Offline

#7 2022-04-20 14:53:08

loqs
Member
Registered: 2014-03-06
Posts: 14,705

Re: swapping package dependencies

pacman -Qip libopenmpt-svn-0.7.r17267-1-x86_64.pkg.tar.zst
Name            : libopenmpt-svn
Version         : 0.7.r17267-1
Description     : Library to decode tracked music files (modules) into a raw PCM audio stream (svn version)
Architecture    : x86_64
URL             : https://lib.openmpt.org/libopenmpt/
Licenses        : BSD
Groups          : None
Provides        : libopenmpt.so=4-64  libopenmpt  openmpt123  openmpt123-svn
Depends On      : libvorbis  mpg123  zlib
Optional Deps   : flac: for openmpt123 player
                  libpulse: for openmpt123 player
                  libsndfile: for openmpt123 player
                  portaudio: for openmpt123 player
                  sdl2: for openmpt123 player
Conflicts With  : libopenmpt  openmpt123
Replaces        : None
Compressed Size : 797.90 KiB
Installed Size  : 2271.03 KiB
Packager        : Unknown Packager
Build Date      : Wed 20 Apr 2022 14:49:05 UTC
Install Script  : No
Validated By    : None
Signatures      : None

The so version has changed to libopenmpt.so=4-64 in the current libopenmpt-svn so mpd will still need to be rebuilt for the soname bump.
Edit:
Alternate approach,  replace libopenmpt-svn with libopenmpt in the ffmpeg-full PKGBUILD and see what happens.

Last edited by loqs (2022-04-20 15:02:45)

Offline

#8 2022-04-21 04:56:59

shoelesshunter
Member
Registered: 2014-05-18
Posts: 199

Re: swapping package dependencies

I tried the advice and this happens

error: unresolvable package conflicts detected
error: failed to prepare transaction (conflicting dependencies)
:: ffmpeg-full and ffmpeg are in conflict

Offline

#9 2022-04-21 08:18:57

loqs
Member
Registered: 2014-03-06
Posts: 14,705

Re: swapping package dependencies

shoelesshunter wrote:

I tried the advice and this happens

error: unresolvable package conflicts detected
error: failed to prepare transaction (conflicting dependencies)
:: ffmpeg-full and ffmpeg are in conflict

https://bbs.archlinux.org/viewtopic.php?id=57855
What was the command?  Were you not intending to replace ffmpeg with ffmpeg-full?  What was the rest of the output?

Last edited by loqs (2022-04-21 12:10:08)

Offline

#10 2022-04-21 13:47:21

shoelesshunter
Member
Registered: 2014-05-18
Posts: 199

Re: swapping package dependencies

the command was

 yay -S ffmpeg-full

when I try, and say "y" when asked to replace ffmpeg with ffmpeg-full,  I am told I can not because ffmpeg
is required by other packages.

I want to swap ffmpeg with ffmpeg-full.

Last edited by shoelesshunter (2022-04-21 13:48:25)

Offline

#11 2022-04-21 13:57:34

Alad
Wiki Admin/IRC Op
From: Bagelstan
Registered: 2014-05-04
Posts: 2,309
Website

Re: swapping package dependencies

ffmpeg-full provides ffmpeg. Don't use AUR helpers, use makepkg and post the complete output instead of paraphrasing.

Last edited by Alad (2022-04-21 13:57:49)


Mods are just community members who have the occasionally necessary option to move threads around and edit posts. -- Trilby

Offline

Board footer

Powered by FluxBB