Bug 8341 - Allow installation of a specified version of a package (old issue #76)
Summary: Allow installation of a specified version of a package (old issue #76)
Status: RESOLVED FIXED
Alias: None
Product: opkg
Classification: Yocto Project Subprojects
Component: opkg (show other bugs)
Version: unspecified
Hardware: x86 Multiple
: Undecided enhancement
Target Milestone: 0.3.2
Assignee: Alejandro del Castillo
QA Contact:
URL:
Whiteboard:
Depends on:
Blocks:
 
Reported: 2015-09-20 22:32 UTC by Alejandro del Castillo
Modified: 2016-05-23 15:04 UTC (History)
0 users

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: Don't know


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alejandro del Castillo 2015-09-20 22:32:35 UTC
I would like to switch between released versions of a disto. I install
a version call it Release-1, then switch feeds to point to Release-2 

What steps will reproduce the problem?


>opkg list-upgradable


 and it looks like it is working.


Now when I try it the other way around, Install Release-2 and switch
the feeds to Release-1,

opkg list-upgradable

Lists nothing! yet lsof has changed.

root@TBC:/usr/bin/cctm# opkg list-installed lsof
lsof - 4.83-r2.5

root@TBC:/usr/bin/cctm# opkg list lsof
lsof - 4.83-r1.5 - Lsof is a Unix-specific diagnostic tool. Its name
stands for LiSt Open Files, and it does just that.
lsof - 4.83-r2.5

root@TBC:/usr/bin/cctm# opkg install  lsof
Package lsof (4.83-r2.5) installed in root is up to date. # As
expected

root@TBC:/usr/bin/cctm# opkg install  lsof --force-downgrade
Package lsof (4.83-r2.5) installed in root is up to date. # I had
assumed the --force-downgrade would install

Then

root@TBC:/var/lib/opkg# opkg remove lsof*  --force-depends
Removing package lsof from root...
root@TBC:/var/lib/opkg#
root@TBC:/var/lib/opkg# opkg list-installed lsof
# lsof not installed

Now

root@TBC:/var/lib/opkg# opkg list lsof
lsof - 4.83-r1.5 - Lsof is a Unix-specific diagnostic tool. Its name
stands for LiSt Open Files, and it does just that.

# OK now we have r1.5 of lsof

root@TBC:/var/lib/opkg# opkg install lsof
Installing lsof (4.83-r1.5) to root...
Downloading http://172.25.113.12:8080/feeds/build.r1/armv5te/lsof_4.83-r1.5_armv5te.ipk
Configuring lsof.

# Great this works.
What is the expected output? What do you see instead?


What version of the product are you using? On what operating system?

svn version 609 built with arm-custom-gnueabi-gcc V 4.3.3


Originally reported by Robert.Melchers, Apr 5, 2011
-----------------------------------------------------------------------------
#1 paul.betafive (Sep 28, 2013)
I don't think "opkg install  lsof --force-downgrade" should automatically perform the downgrade as two versions are available (1.5 from the feed, 2.5 already installed) and there could in theory be more. There should however be a way to specify the desired version on the command line. I'm not sure if there is one, I'll have to investigate.

#2 paul.betafive (Oct 11, 2014)
 Issue 146  has been merged into this issue.

#3 paul.betafive (Oct 11, 2014)
opkg doesn't currently allow a desired version to be given on the command line when installing a package. This would be a very useful feature though, especially for package downgrades. This feature will be added after the v0.3.0 release.
Comment 1 Alejandro del Castillo 2016-05-23 15:04:14 UTC
Added feature on commit: 9da784d5508157cb327d53eb9abcf54e9926a5a5