You are not logged in.

#1 2012-12-15 13:57:18

ebal
Member
From: Athens, Greece
Registered: 2009-05-26
Posts: 224
Website

[SOLVED] pacman and custom repo

I am not sure if this question is on the proper question.
Plz move it - if necessary.

I've made a custom repo and build a package from abs, changing first the version.

$ sudo pacman -Ss ntfs-3g

extra/ntfs-3g 2012.1.15-4
    Stable read and write NTFS driver

repo/ntfs-3g 2012.1.15-5
    Stable read and write NTFS driver

but when i am trying to install ntfs-3g, it chooses the smaller version


$ sudo pacman -S ntfs-3g

resolving dependencies...
looking for inter-conflicts...

Targets (1): ntfs-3g-2012.1.15-4

Total Download Size:    0,24 MiB
Total Installed Size:   0,87 MiB

Proceed with installation? [Y/n] n

What i am doing wrong ?

Last edited by ebal (2012-12-21 18:59:24)


https://balaskas.gr
Linux System Engineer - Registered Linux User #420129

Offline

#2 2012-12-15 14:10:30

Pierre
Developer
From: Bonn
Registered: 2004-07-05
Posts: 1,967
Website

Re: [SOLVED] pacman and custom repo

pacman will choose the package from the repo that is defined first in you pacman.conf.

Offline

#3 2012-12-15 14:11:54

ebal
Member
From: Athens, Greece
Registered: 2009-05-26
Posts: 224
Website

Re: [SOLVED] pacman and custom repo

why not choosing the package with the greater version ?
is that a bug ?


https://balaskas.gr
Linux System Engineer - Registered Linux User #420129

Offline

#4 2012-12-15 14:24:12

jjacky
Member
Registered: 2011-11-09
Posts: 347
Website

Re: [SOLVED] pacman and custom repo

Not a bug, as Pierre said pacman will go for the first repo the pakage was found in, using the order you defined. Or, you can also specify the repo to use, e.g: pacman -S repo/ntfs-3g

Offline

#5 2012-12-15 14:27:56

ebal
Member
From: Athens, Greece
Registered: 2009-05-26
Posts: 224
Website

Re: [SOLVED] pacman and custom repo

yes, i understand that - i've read pacman.conf already.
I just dont understand why from the repos pacman dont choose the greater version.

If the packages have the same version, it's clear that pacman should choose the package by order.
But with diferrent versions .... it should choose the greater version.


https://balaskas.gr
Linux System Engineer - Registered Linux User #420129

Offline

#6 2012-12-15 14:46:52

Xabre
Member
From: Serbia
Registered: 2009-03-19
Posts: 757

Re: [SOLVED] pacman and custom repo

....pacman should choose...

...is wrong. User should chose what computer will do, not the other way around. In your pacman.conf, you gave pacman the order of preference for your repositories, and now pacman follows and respects that order of prefference.
Are you saying that pacman is faulty cause it does exactly what you told him to do?

...why from the repos pacman dont choose the greater version...

Guess what, some people actually want pacman to choose lesser version, cause that lesser version might be explicit dependancy for a package from same repo (greater version won't work).
And, again, that's not pacman's fault. Sometimes you have to go with the flow, see the whole picture to understand it, instead of complaining right away.

Offline

#7 2012-12-17 13:08:05

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

Re: [SOLVED] pacman and custom repo

i'm pretty sure it's not the version that matters.

let's take pacman -S foo as example.
pacman searches for foo in the first configured repo, if foo is present there it STOPS searching and will install that version.
If foo is not found in the first repo, it searches the 2nd . if present foo will be installed, if not, onto 3rd repo etc .

In short , if you have the same package in multiple repos, pacman only sees the first one it finds.


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

#8 2012-12-17 13:11:45

ebal
Member
From: Athens, Greece
Registered: 2009-05-26
Posts: 224
Website

Re: [SOLVED] pacman and custom repo

pamcan -Ss

doesnt stop on the first repo, why pacman -S should ?

I dont have an actual problem - i am trying to understand the logic behind that.
In my opinion (and if i am the only one - i'll stop, it shouldnt stop at the first repo)


https://balaskas.gr
Linux System Engineer - Registered Linux User #420129

Offline

#9 2012-12-17 13:18:32

Allan
Pacman
From: Brisbane, AU
Registered: 2007-06-09
Posts: 11,672
Website

Re: [SOLVED] pacman and custom repo

Imagine you add a custom repo of the end of your pacman.conf.  Now that repo thinks they are awesome and adds a linux-9999-1 package.  With [core] above that repo in pacman.conf, you are safe and using the Arch Linux kernel package.

You can always explicitly install from a repo further down the list if needed.

Offline

#10 2012-12-17 13:40:54

ebal
Member
From: Athens, Greece
Registered: 2009-05-26
Posts: 224
Website

Re: [SOLVED] pacman and custom repo

(i am not sure) but isnt that the same with a custom build of linux-9999-1 package and use pacman -U linux.pkg.tar.xz ?

I think that if you are using a custom repo is to do exactly this. Build a package that you want to "upgrade/overwrite" from a "default" repo.
Move it above core repo ... is like breaking your own system and then blame ... you !


https://balaskas.gr
Linux System Engineer - Registered Linux User #420129

Offline

Board footer

Powered by FluxBB