Opened 16 years ago

Closed 16 years ago

Last modified 16 years ago

#18270 closed defect (fixed)

port distfiles shouldn't require root

Reported by: ryandesign (Ryan Carsten Schmidt) Owned by: macports-tickets@…
Priority: Normal Milestone: MacPorts 1.8.0
Component: base Version: 1.7.0
Keywords: Cc:
Port:

Description

port distfiles shouldn't require root access to run, since it's only displaying information:

$ port distfiles apache2
Error: Unable to execute port: /opt/local/var/macports/build/_Users_rschmidt_macports_dports_www_apache2/work/.macports.apache2.state is not writable - check permission on port directory
$

Attachments (1)

macports-diststate.diff (615 bytes) - added by afb@… 16 years ago.
macports-diststate.diff

Download all attachments as: .zip

Change History (6)

comment:1 Changed 16 years ago by danielluke (Daniel J. Luke)

It looks like it just wants root to write the statefile (which it probably shouldn't need to do), so if you've been building things as non-root, it wouldn't need root.

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

Right, but does it really need to write a statefile? port lint and port livecheck were recently enhanced to not require root; I figured a similar change could be made to port distfiles.

Changed 16 years ago by afb@…

Attachment: macports-diststate.diff added

macports-diststate.diff

comment:3 Changed 16 years ago by afb@…

Same goes for port distcheck, it uses an (outdated) hard-coded list of targets rather than checking target_state

comment:4 Changed 16 years ago by raimue (Rainer Müller)

Resolution: fixed
Status: newclosed

Fixed in r48483.

dlist_search is maybe not the fastest option to implement this, I copied this from eval_targets.

comment:5 Changed 16 years ago by raimue (Rainer Müller)

Milestone: MacPorts FutureMacPorts 1.8.0
Note: See TracTickets for help on using tickets.