Opened 10 years ago

Closed 10 years ago

Last modified 10 years ago

#25246 closed defect (fixed)

MacPorts can't extract distfiles whose names contain spaces

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

Description

Once you get past the problem that MacPorts can't fetch distfiles whose names contain spaces, it can't extract them either:

$ sudo port -d extract bbcolors
[snip]
--->  Extracting Bell Dark.bbcolors.zip
DEBUG: setting option extract.args to {/mp/var/macports/distfiles/bbcolors/Bell Dark.bbcolors.zip}
DEBUG: Environment: CPATH='/mp/include' CC_PRINT_OPTIONS_FILE='/mp/var/macports/build/_Volumes_data_macports_ports_sysutils_bbcolors/work/.CC_PRINT_OPTIONS' LIBRARY_PATH='/mp/lib' CC_PRINT_OPTIONS='YES' MACOSX_DEPLOYMENT_TARGET='10.5'
DEBUG: Assembled command: 'cd "/mp/var/macports/build/_Volumes_data_macports_ports_sysutils_bbcolors/work/bbcolors_1.0.1" && /usr/bin/unzip -q /mp/var/macports/distfiles/bbcolors/Bell Dark.bbcolors.zip -d /mp/var/macports/build/_Volumes_data_macports_ports_sysutils_bbcolors/work/bbcolors_1.0.1'
unzip:  cannot find or open /mp/var/macports/distfiles/bbcolors/Bell, /mp/var/macports/distfiles/bbcolors/Bell.zip or /mp/var/macports/distfiles/bbcolors/Bell.ZIP.
shell command " cd "/mp/var/macports/build/_Volumes_data_macports_ports_sysutils_bbcolors/work/bbcolors_1.0.1" && /usr/bin/unzip -q /mp/var/macports/distfiles/bbcolors/Bell Dark.bbcolors.zip -d /mp/var/macports/build/_Volumes_data_macports_ports_sysutils_bbcolors/work/bbcolors_1.0.1 " returned error 9
Error: Target org.macports.extract returned: shell command failed

The attached patch seems to fix this (using the same strategy Rainer employed to fix #23456). I'll test it in my MacPorts installations for awhile before committing.

Attachments (1)

portextract.tcl.distfiles-with-spaces.diff (1.1 KB) - added by ryandesign (Ryan Schmidt) 10 years ago.
proposed patch

Download all attachments as: .zip

Change History (4)

Changed 10 years ago by ryandesign (Ryan Schmidt)

proposed patch

comment:1 Changed 10 years ago by ryandesign (Ryan Schmidt)

Keywords: haspatch added

comment:2 Changed 10 years ago by jmroot (Joshua Root)

Resolution: fixed
Status: newclosed

comment:3 Changed 10 years ago by jmroot (Joshua Root)

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