#47283: Backslashes in file names in destroot cause activate to fail ---------------------+-------------------------------- Reporter: jpo@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: Component: base | Version: 2.3.3 Resolution: | Keywords: Port: | ---------------------+-------------------------------- Changes (by cal@…): * cc: cal@… (added) * keywords: backslash, activate => Old description:
Seems like a simple enough fix for anyone who is familiar with TCL and the base plumbing. I'm not unfortunately.
Consider the following: {{{ PortSystem 1.0 name backslash-test version 1 categories devel platforms darwin description tests backslashes in filenames for the activate target
fetch {} checksum {} use_configure no build {} destroot { touch "${destroot}${prefix}/share/back\\slash" } }}}
Which produces the following results {{{ $ sudo port destroot backslash-test ---> Fetching distfiles for backslash-test ---> Verifying checksums for backslash-test ---> Extracting backslash-test ---> Configuring backslash-test ---> Building backslash-test ---> Staging backslash-test into destroot $ find backslash-test -type f backslash-test/work/.macports.backslash-test.state backslash-test/work/destroot/opt/local/share/back\slash $ sudo port activate backslash-test $ sudo port install backslash-test ---> Activating backslash-test @1_0 Error: org.macports.activate for port backslash-test returned: Image error: Source file /opt/local/var/macports/software/backslash- test/mpextractFapBvhDF/opt/local/share/back lash does not appear to exist (cannot lstat it). Unable to activate port backslash-test. Please see the log file for port backslash-test for details: /opt/local/var/macports/logs /_Volumes_case_src_macports_devel_backslash-test/backslash-test/main.log To report a bug, follow the instructions in the guide: http://guide.macports.org/#project.tickets Error: Processing of port backslash-test failed }}}
I've attached a full log of an install of the above portfile from a clean state.
New description: Seems like a simple enough fix for anyone who is familiar with TCL and the base plumbing. I'm not unfortunately. Consider the following: {{{ PortSystem 1.0 name backslash-test version 1 categories devel platforms darwin description tests backslashes in filenames for the activate target fetch {} checksum {} use_configure no build {} destroot { touch "${destroot}${prefix}/share/back\\slash" } }}} Which produces the following results {{{ $ sudo port destroot backslash-test ---> Fetching distfiles for backslash-test ---> Verifying checksums for backslash-test ---> Extracting backslash-test ---> Configuring backslash-test ---> Building backslash-test ---> Staging backslash-test into destroot $ find backslash-test -type f backslash-test/work/.macports.backslash-test.state backslash-test/work/destroot/opt/local/share/back\slash $ sudo port install backslash-test ---> Activating backslash-test @1_0 Error: org.macports.activate for port backslash-test returned: Image error: Source file /opt/local/var/macports/software/backslash- test/mpextractFapBvhDF/opt/local/share/back lash does not appear to exist (cannot lstat it). Unable to activate port backslash-test. Please see the log file for port backslash-test for details: /opt/local/var/macports/logs /_Volumes_case_src_macports_devel_backslash-test/backslash-test/main.log To report a bug, follow the instructions in the guide: http://guide.macports.org/#project.tickets Error: Processing of port backslash-test failed }}} I've attached a full log of an install of the above portfile from a clean state. -- -- Ticket URL: <https://trac.macports.org/ticket/47283#comment:3> MacPorts <https://www.macports.org/> Ports system for OS X