Opened 12 years ago

Closed 12 years ago

#35048 closed defect (fixed)

rpm tries to access files in destroot in activate phase

Reported by: ryandesign (Ryan Carsten Schmidt) Owned by: afb@…
Priority: Normal Milestone:
Component: ports Version: 2.1.1
Keywords: Cc: wim.deblauwe@…, n3npq@…
Port: rpm

Description

rpm tries to access files in the destroot in the activate phase. The destroot does not necessarily exist at activation time. For example, if a port it installed, activated, deactivated, then activated again. Or if a port is installed from a pre-compiled binary from the packages server. This was reported by Wim Deblauwe on the users mailing list and on stack exchange.

The workaround is to install from source:

sudo port -f uninstall rpm
sudo port clean rpm
sudo port -s install rpm

The fix is to move files that are part of the destroot in the destroot phase, not the activate phase.

Change History (3)

comment:1 Changed 12 years ago by afb@…

Resolution: fixed
Status: newclosed

Fixed, r94835.

No, the solution is not to move the ugly workaround to bug #34403 to the destroot phase where it would be worthless but to avoid copy/pasting a ${destroot} to it. The real solution would be to actually upgrade something (whether it is python to 2.6 or rpm to something beyond 4.4), but that requires some more decisive action. Also, there are no packages for rpm due to the epidemic system-wide issues with openssl (OpenSSL) and readline (GPL-3+).

comment:2 Changed 12 years ago by ryandesign (Ryan Carsten Schmidt)

Resolution: fixed
Status: closedreopened

I hadn't looked at the code closely and was just guessing at what the solution might be. Unfortunately the change in r94835 doesn't appear to work:

--->  Fetching distfiles for rpm
--->  Verifying checksum(s) for rpm
--->  Extracting rpm
--->  Applying patches to rpm
--->  Configuring rpm
--->  Building rpm
--->  Staging rpm into destroot
Warning: reinplace slibtooliz;glibtoolize; didn't change anything in /opt/local/var/macports/build/_Users_rschmidt_macports_dports_sysutils_rpm/rpm/work/destroot/opt/local/lib/rpm/macros
--->  Installing rpm @4.4.9_14
Error: org.macports.activate for port rpm returned: error renaming "/opt/local/lib/python2.5/site-packages/rpm": no such file or directory
Please see the log file for port rpm for details:
    /opt/local/var/macports/logs/_Users_rschmidt_macports_dports_sysutils_rpm/rpm/main.log
To report a bug, follow the instructions in the guide:
    http://guide.macports.org/#project.tickets
Error: Processing of port rpm failed

comment:3 Changed 12 years ago by afb@…

Resolution: fixed
Status: reopenedclosed

Fixed, r94877.

Note: See TracTickets for help on using tickets.