Opened 14 years ago

Closed 14 years ago

#27367 closed defect (fixed)

MyPaint @0.9.0, Revision 2: build failure if MacPorts was installed with custom $PREFIX

Reported by: su-v Owned by: ryandesign (Ryan Carsten Schmidt)
Priority: Normal Milestone:
Component: ports Version: 1.9.2
Keywords: Cc:
Port: MyPaint

Description

The 'SConstruct' file of MyPaint has '/opt/local' hardcoded as default and appears to ignore a custom $PREFIX of MacPorts:

if sys.platform == "darwin":
    default_prefix = '/opt/local/'
else:
    default_prefix = '/usr/local/'

If MacPorts was configured with custom $PREFIX and to be used as normal user, build fails with

OSError: [Errno 13] Permission denied: '/opt'
  File "/Volumes/green/mp-inkscape/with-a-long-long-long-directory-name/var/macports/build/_Volumes_green_mp-inkscape_with-a-long-long-long-directory-name_var_macports_sources_rsync.macports.org_release_ports_graphics_MyPaint/work/mypaint-0.9.0/SConstruct", line 29:
    env = Environment(ENV=os.environ, options=opts)
  File "/Volumes/green/mp-inkscape/with-a-long-long-long-directory-name/Library/Frameworks/Python.framework/Versions/2.6/lib/scons-2.0.1/SCons/Environment.py", line 974:
    variables.Update(self)
  File "/Volumes/green/mp-inkscape/with-a-long-long-long-directory-name/Library/Frameworks/Python.framework/Versions/2.6/lib/scons-2.0.1/SCons/Variables/__init__.py", line 216:
    option.validator(option.key, env.subst('${%s}'%option.key), env)
  File "/Volumes/green/mp-inkscape/with-a-long-long-long-directory-name/Library/Frameworks/Python.framework/Versions/2.6/lib/scons-2.0.1/SCons/Variables/PathVariable.py", line 102:
    os.makedirs(val)
  File "/Volumes/green/mp-inkscape/with-a-long-long-long-directory-name/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/os.py", line 150:
    makedirs(head, mode)
  File "/Volumes/green/mp-inkscape/with-a-long-long-long-directory-name/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/os.py", line 157:
    mkdir(name, mode)

Tested workaround: 'port build mypaint' succeeds after replacing '/opt/local' in SConstruct with the expanded path of $PREFIX (and mypaint installs, activates and runs without further issues).

Mac OS X 10.5.8, MacPorts 1.9.2 (custom source installation)
scons @2.0.1, python26 selected

Attachments (1)

main.log (113.0 KB) - added by su-v 14 years ago.

Download all attachments as: .zip

Change History (5)

comment:1 Changed 14 years ago by jmroot (Joshua Root)

Cc: ryandesign@… removed
Owner: changed from macports-tickets@… to ryandesign@…
Port: MyPaint added; mypaint removed

Changed 14 years ago by su-v

Attachment: main.log added

comment:2 Changed 14 years ago by su-v

Attaching main.log (I thought I'd lost it when 'port install' succeeded, but it was still open in MacVim :) )

comment:3 Changed 14 years ago by ryandesign (Ryan Carsten Schmidt)

Status: newassigned

MyPaint begins to annoy me.

comment:4 Changed 14 years ago by ryandesign (Ryan Carsten Schmidt)

Resolution: fixed
Status: assignedclosed

Fixed in r73693.

Note: See TracTickets for help on using tickets.