Opened 9 years ago

Closed 7 years ago

#50923 closed defect (worksforme)

htcondor: unregistered files installed on user systems

Reported by: ryandesign (Ryan Carsten Schmidt) Owned by: lpsinger (Leo Singer)
Priority: Normal Milestone:
Component: ports Version: 2.3.4
Keywords: Cc:
Port: htcondor

Description

These unexpected files are present on the buildbot workers:

$ ls -l /opt/local/{bosco_install,condor_configure,condor_install}
lrwxr-xr-x  1 root  admin  20 Jun  9  2013 /opt/local/bosco_install -> ./sbin/bosco_install
lrwxr-xr-x  1 root  admin  23 Apr 15  2013 /opt/local/condor_configure -> ./sbin/condor_configure
lrwxr-xr-x  1 root  admin  21 Apr 15  2013 /opt/local/condor_install -> ./sbin/condor_install

These files are not registered to a port:

$ port provides /opt/local/{bosco_install,condor_configure,condor_install}
/opt/local/bosco_install is not provided by a MacPorts port.
/opt/local/condor_configure is not provided by a MacPorts port.
/opt/local/condor_install is not provided by a MacPorts port.

They were probably installed there by an old version of htcondor. (I have not checked if the current version 8.4.3 still puts them there.)

Since these files appear on the buildbot worker, I expect them to also be on systems of users who installed the port from source.

The port should have a pre-activate (or post-activate; doesn't much matter in this case) block that checks if these files exist and are unregistered, and if so removes them. Note that because these are symlinks, you cannot use file exists because that will test for the existence of the file the symlink points to, not the existence of the symlink itself. In these situations I use file type inside a catch. The code I added to nedi in r143403 is a good example to follow. Something like:

pre-activate {
    # Remove symlinks htcondor installed directly, bypassing the destroot.
    # Can be removed after April 2017.
    foreach f "${prefix}/bosco_install ${prefix}/condor_configure ${prefix}/condor_install" {
        if {![catch {file type ${f}}] && [registry_file_registered ${f}] == "0"} {
            if {[catch {delete ${f}}]} {
                ui_warn "Cannot delete ${f}; please remove it manually"
            }
        }
    }
}

If the current version of htcondor still installs these files, it should also be patched not to do so.

Change History (2)

comment:1 Changed 9 years ago by lpsinger (Leo Singer)

Why the April 2017 date?

comment:2 Changed 7 years ago by lpsinger (Leo Singer)

Resolution: worksforme
Status: newclosed

Looks like the bosco files are no longer being installed.

Note: See TracTickets for help on using tickets.