Bug 15155

Summary: Not able to install some of the packages
Product: [Yocto Project Subprojects] opkg Reporter: nish.saxena
Component: opkgAssignee: nish.saxena
Status: RESOLVED OBSOLETE QA Contact:
Severity: normal    
Priority: Undecided CC: alex.stewart, randy.macleod
Version: 0.4.1   
Target Milestone: ---   
Hardware: x86   
OS: x86_64   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: Don't know
Attachments:
Description Flags
Logs while downloading run-postinsts on opkg 0.4.1 none

Description nish.saxena 2023-06-27 06:18:13 UTC
Created attachment 4959 [details]
Logs while downloading run-postinsts on opkg 0.4.1

While using opkg-0.4.1 trying to install packages like "run-postinsts", "libgcc1_11.2.0-4_x86_64.ipk" are not working. At the same time, package "libstdcpp6_11.2.0-4_x86_64.ipk" works.

Also the not working packages (run-postinsts, libgcc1_11.2.0-4_x86_64.ipk) are working fine with opkg 0.6.1
Comment 1 Alex Stewart 2023-07-10 21:10:40 UTC
```
root@35fb0ca06573:/# opkg install -V4 run-postinsts_1.0-r9_all.ipk
...
Collected errors:

 * check_data_file_clashes: Package run-postinsts wants to install directory /lib/

	But that path is currently a file

 * opkg_solver_install: Cannot install package run-postinsts.
```

What opkg operations have you performed on this machine prior to that `install` call, if any?

Does the error that it give you (that `/lib` is a regular file) seem to be true?

Can you describe your image build setup?
Comment 3 nish.saxena 2023-07-25 07:05:38 UTC
1. we have configured artifactory to opkg in the conf file /etc/opkg/opkg.conf and uploaded the runinsts package to artifactory.

2. no, I don't think it is a valid error message

3. we are pulling debian latest image and configuring Opkg by running 

apt-get update && apt-get install -y make sudo wget gcc libtool autoconf pkg-config libarchive13 libarchive-dev libcurl4 libcurl4-gnutls-dev libssl-dev libgpgme11-dev ,

wget http://downloads.yoctoproject.org/releases/opkg -O versions.txt , 

(grep -oP \"opkg-\\d+.\\d+.\\d+.tar.gz\" versions.txt | tail -1) >> latest.txt , 

wget http://downloads.yoctoproject.org/releases/opkg/\$(cat latest.txt) -O ${packageFullName}.tar.gz , 

apt-get install -y acl-dev liblzma-dev liblzo2-dev libbz2-dev libxml2-dev nettle-dev libzstd-dev liblz4-dev libz-dev
Comment 4 Alex Stewart 2023-08-01 18:01:59 UTC
Thanks for the context. Still, it will be a little difficult to reproduce this error without the exact packages that you're using. But rather than providing those, I would suggest that you git-bisect the opkg code between v0.4.1 and v0.6.1 to determine what commits fixed the issue.

I would suggest focusing your investigation into this patchset [1], that went into the 0.6.1 release. If that seems to fix it, then you can backport that set to your 0.4.1 build.

[1] https://groups.google.com/g/opkg-devel/c/tUlw8yW9tVU


Since it sounds like this isn't a bug in the mainline opkg code, I'm going to close this bug item. If you still need help, we can continue the discussion on the opkg-devel mailing list. And if your investigation turns up an issue with the mainline code, we can re-open this bug or file a new one as appropriate.