Opened 6 years ago

Closed 6 years ago

#57981 closed defect (worksforme)

boost @1.66.0_3: fails to deactivate

Reported by: petrrr Owned by: ryandesign (Ryan Carsten Schmidt)
Priority: Normal Milestone:
Component: ports Version: 2.5.4
Keywords: Cc: michaelld@…
Port: boost

Description

I have installed the following boost variants:

The following ports are currently installed:  
boost @1.66.0_3+no_single+no_static+python27 (active)
  boost @1.66.0_3+no_single+no_static+python27+universal
  boost @1.66.0_3+no_single+no_static+python37

Build works fine. However the currently active port fails to deactivate. Might be a problem with base, but I feel not competent enough to judge.

I found this in the respective log.]:

version:1
:debug:sysinfo OS X 10.10 (darwin/14.5.0) arch i386
:debug:sysinfo MacPorts 2.5.4
:debug:sysinfo Xcode 6.4
:debug:sysinfo SDK 10.10
:debug:sysinfo MACOSX_DEPLOYMENT_TARGET: 10.10
:debug:main Executing org.macports.main (boost)
:debug:deactivate deactivate phase started at Tue Jan 29 19:02:03 CET 2019
:debug:deactivate Executing org.macports.deactivate (boost)
:msg:deactivate --->  Deactivating boost @1.66.0_3+no_single+no_static+python27
:error:deactivate Failed to deactivate boost: this entry does not own the given file
:debug:deactivate Error code: registry::invalid
:debug:deactivate Backtrace: this entry does not own the given file
:debug:deactivate     while executing
:debug:deactivate "$port deactivate $imagefiles"
:debug:deactivate     invoked from within
:debug:deactivate "registry::write {
:debug:deactivate                 $port deactivate $imagefiles
:debug:deactivate                 foreach file $files {
:debug:deactivate                     _deactivate_file $file
:debug:deactivate       ..."
:debug:deactivate     invoked from within
:debug:deactivate "try {
:debug:deactivate         # Block the TERM and INT signals to avoid being interrupted. Note that
:debug:deactivate         # they might already be block at this point because
:debug:deactivate      ..."
:debug:deactivate     (procedure "_deactivate_contents" line 39)
:debug:deactivate     invoked from within
:debug:deactivate "_deactivate_contents $requested [$requested files] $force"
:debug:deactivate     (procedure "portimage::deactivate" line 57)
:debug:deactivate     invoked from within
:debug:deactivate "registry_deactivate $subport $version $revision $portvariants [array get user_options]"
:debug:deactivate     (procedure "portdeactivate::deactivate_main" line 10)
:debug:deactivate     invoked from within
:debug:deactivate "$procedure $targetname"
:error:deactivate See /opt/local/var/macports/logs/_opt_local_var_macports_registry_portfiles_boost-1.66.0_3_c94250e89f7373c5edaa865ff13c9785876a56fe95faf7ea08247f131e3da1c5-15164/boost/main.log for details.

Change History (15)

comment:1 Changed 6 years ago by michaelld (Michael Dickens)

"Failed to deactivate boost: this entry does not own the given file" --> I wonder what file? --> Maybe try "sudo port -f deactivate boost"? force it regardless of file ownership?

comment:2 Changed 6 years ago by michaelld (Michael Dickens)

I go between versions of Boost regularly, activating and deactivating them. Never had an issue. Not sure what might have gotten into your install, but hopefully forcing it can resolve the issue!

comment:3 Changed 6 years ago by petrrr

Negative! Forcing has not worked neither and I just rechecked.

Actually this occurred first when upgrading, and I think this while upgrading deactivation is forced anyway.

comment:4 Changed 6 years ago by michaelld (Michael Dickens)

Interesting & strange. I'd expect force deactivation / activation to work. Hmmm ... not sure what to do if the file in question isn't listed somewhere ... maybe someone else has a bright idea on how to help you here!

comment:5 Changed 6 years ago by michaelld (Michael Dickens)

Is "port" (base) up to date? "sudo port selfupdate" ... or maybe try the latest GIT master HEAD of macports/base?

comment:6 Changed 6 years ago by petrrr

I am on the latest release as specified in the description.

comment:7 Changed 6 years ago by petrrr

I just checked the tarball of the packages contains a +PORTFILE file and it looks like a reasonable Portfile.

What else I could check?

comment:8 Changed 6 years ago by michaelld (Michael Dickens)

Can you do the following:

sudo rm /opt/local/var/macports/logs/_opt_local_var_macports_registry_portfiles_boost-1.66.0_3_c94250e89f7373c5edaa865ff13c9785876a56fe95faf7ea08247f131e3da1c5-15164/boost/main.log
sudo port -f deactivate boost

and, then when it errors out post the whole logfile here (maybe compress it first)? It might not be any more useful than the snippet you provide in the description ... but it's worth a try!

Last edited 6 years ago by michaelld (Michael Dickens) (previous) (diff)

comment:9 Changed 6 years ago by michaelld (Michael Dickens)

Might be that you could just jump right to sudo port -f activate boost @.... to get that version in place, then you might be able to deactivate it. Could be worth a try if nothing else is working ...

comment:10 Changed 6 years ago by petrrr

I already tried that, but port would just skip the activation step:

DEBUG: Skipping activate (boost @1.66.0_3+no_single+no_static+python27) since this port is already active

comment:11 Changed 6 years ago by petrrr

I also tried sudo port -v upgrade --force boost @1.66.0_3+no_single+no_static+python27, but at the end it boils down to the same result.

There must be some mess in my registry. I am just not very good in debugging that piece of Macports.

Any possibility to delete an port entry from the registry? I then would just reactivate the port and see if this fixes the issue.

comment:12 Changed 6 years ago by michaelld (Michael Dickens)

Try activating a non-active version of Boost & see if that works. use force (-f) if required.

Yes it sounds like the registry has some issues. Happens sometimes. I'm not the correct person to ask about messing with it!

comment:13 Changed 6 years ago by petrrr

To activate a different boost variant, goes first through a forced deactivation. So we are back to this issue.

Actually this is the beginning of all this story. A different port requested the +universal variant, but the activation fails because of this.

comment:14 Changed 6 years ago by petrrr

I just wanted to inform that this issue disappeared at some point.

However, I have no good explanation on the cause of this issue, why this problem disappeared, or when exactly this happened. I just was able to upgrade recently without this issue reappearing. Today, I also changed the variant without any issue.

So the problem was probably not directly related to the port and I'd assume this can be closed.

  • invalid?
  • worksforme?

comment:15 Changed 6 years ago by michaelld (Michael Dickens)

Resolution: worksforme
Status: assignedclosed

Thanks for reporting back. Stuff happens& sometimes it's for the better!

Note: See TracTickets for help on using tickets.