You are not logged in.

#1 2019-10-28 10:55:54

M5Hc6UsQ
Member
Registered: 2018-02-26
Posts: 33

pacman, exclude specific version of package

Hi,

is it possible to exclude a specific version of a package from updating? I've found the '--ignore' flag, but the manual doesn't mentions how to specify a version number. I'd like to exclude a package version without missing further updates. Current example is 'mpv 0.30' which has some bugs and requires a downgrade to 0.29, at least when used with smplayer.

Offline

#2 2019-10-28 11:28:52

schard
Forum Moderator
From: Hannover
Registered: 2016-05-06
Posts: 2,711
Website

Re: pacman, exclude specific version of package

There are no native means of doing this. IgnorePkg from pacman.conf does not consider package versions.
Your best option would be to re-package 0.29 as 0.30 and install it.

Last edited by schard (2019-10-28 11:29:27)


Inofficial first vice president of the Rust Evangelism Strike Force

Offline

#3 2019-10-28 13:00:24

progandy
Member
Registered: 2012-05-17
Posts: 5,321

Re: pacman, exclude specific version of package

pacman prints a warning when an update is ignored. This warning includes the new version number, so when you notice a fixed version you can remove the ignore entry again.

Anyways, with mpv/smplayer the fix will probably be in the smplayer package, so there will be no new fixed release of the mpv package and this version-specific ignore wouldn't solve your issue. https://app.assembla.com/spaces/smplaye … mmits/9232

Last edited by progandy (2019-10-28 13:07:53)


| alias CUTF='LANG=en_XX.UTF-8@POSIX ' | alias ENGLISH='LANG=C.UTF-8 ' |

Offline

#4 2019-10-28 15:12:55

M5Hc6UsQ
Member
Registered: 2018-02-26
Posts: 33

Re: pacman, exclude specific version of package

schard wrote:

Your best option would be to re-package 0.29 as 0.30 and install it.

Is it possible to just change the version number without re-building the whole package?

progandy wrote:

pacman prints a warning when an update is ignored. This warning includes the new version number, so when you notice a fixed version you can remove the ignore entry again.

Yes that's what I currently do. The issue I have with this is that I always have to remember or look up the version I want to ignore because the warning is shown everytime I upgrade and not only if there is a new version in the database.

progandy wrote:

Anyways, with mpv/smplayer the fix will probably be in the smplayer package, so there will be no new fixed release of the mpv package and this version-specific ignore wouldn't solve your issue. https://app.assembla.com/spaces/smplaye … mmits/9232

Thanks for the info!

Last edited by M5Hc6UsQ (2019-10-28 15:14:29)

Offline

#5 2019-10-28 16:22:24

loqs
Member
Registered: 2014-03-06
Posts: 19,098

Re: pacman, exclude specific version of package

Would it not be better to apply the fix?

git clone git://git.archlinux.org/svntogit/community.git --single-branch --branch "packages/smplayer" #clone PKGBUILD
cd community trunk
svn diff -r 9231:9232 https://subversion.assembla.com/svn/smplayer/smplayer/trunk > 9232.patch #obtain patch

diff of changes to PKGBUILD to apply patch

diff --git a/trunk/PKGBUILD b/trunk/PKGBUILD
index 485049d..474d9db 100644
--- a/trunk/PKGBUILD
+++ b/trunk/PKGBUILD
@@ -18,14 +18,18 @@ optdepends=('smplayer-themes: icon themes collection'
             'smtube: browse and play youtube videos'
             'youtube-dl: youtube videos and streaming'
             'mplayer: alternative multimedia engine')
-source=(https://downloads.sourceforge.net/${pkgname}/${pkgname}-${pkgver}.tar.bz2)
-sha256sums=('b5cb2b37fc9a225bb7287bf26a0a499f7b46bff688161b8e5eae0d96d74daaf5')
-sha512sums=('ee19186b3f4eac94b06a1e389e42edb8c2b22f8182b679bdc40e3ae1569a6c69f168260abfee3b2827b71b10eb353e7a3821805798f37aae2600af3b73d25ca1')
+source=(https://downloads.sourceforge.net/${pkgname}/${pkgname}-${pkgver}.tar.bz2
+        9232.patch)
+sha256sums=('b5cb2b37fc9a225bb7287bf26a0a499f7b46bff688161b8e5eae0d96d74daaf5'
+            'cc230766a833f51d1e1b9ef11938c86a27db6a4e1cc4489f91040e40fca212c0')
+sha512sums=('ee19186b3f4eac94b06a1e389e42edb8c2b22f8182b679bdc40e3ae1569a6c69f168260abfee3b2827b71b10eb353e7a3821805798f37aae2600af3b73d25ca1'
+            '2312190dfd4b859a81581972048de4b80b708f47d69effb9145e95c4730d766e0837e49d4a175a73875b6a0b63462837c3ad2e0f0457d1c37901eb6e72c37dda')
 
 prepare() {
   cd ${pkgname}-${pkgver}
   # make build reproducible, we compress ourselves
   sed '/gzip -9/d' -i Makefile
+  patch -p0 -i ../9232.patch
 }
 
 build() {
makepkg -rsi #to install package

Offline

#6 2019-10-31 14:02:18

M5Hc6UsQ
Member
Registered: 2018-02-26
Posts: 33

Re: pacman, exclude specific version of package

@loqs Yes that solves the issue with smplayer/mpv, but doesn't answers my question. The issue with the mpv package was just the latest example.

Offline

#7 2019-10-31 17:42:54

loqs
Member
Registered: 2014-03-06
Posts: 19,098

Re: pacman, exclude specific version of package

Looking at the questions you asked the only one I have not seen answered is:

M5Hc6UsQ wrote:

Is it possible to just change the version number without re-building the whole package?

Which I have never attempted.

Offline

#8 2019-11-01 11:22:15

Lone_Wolf
Administrator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 15,477

Re: pacman, exclude specific version of package

Maybe ayekat' tool remakepkg can do that https://bbs.archlinux.org/viewtopic.php?id=234936


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.

clean chroot building not flexible enough ?
Try clean chroot manager by graysky

Offline

#9 2019-11-01 12:24:16

WorMzy
Administrator
From: Scotland
Registered: 2010-06-16
Posts: 13,678
Website

Re: pacman, exclude specific version of package

Pacman's db is just text files and directories, you can modify/forge entries with mv and a text editor, but this is not something you should be doing routinely just to avoid an update.


Sakura:-
Mobo: MSI MAG X570S TORPEDO MAX // 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

Board footer

Powered by FluxBB