Opened 4 years ago

Closed 4 years ago

#61491 closed defect (fixed)

supertux @0.6.2: No such file or directory: "/Applications/MacPorts/SuperTux.app/Contents/Resources/SuperTux.app/Contents/Resources/data"

Reported by: kencu (Ken) Owned by: kencu (Ken)
Priority: Normal Milestone:
Component: ports Version:
Keywords: Cc:
Port: supertux

Description (last modified by kencu (Ken))

Darn.

I saw this once or twice during testing, but I thought I had scrubbed it out of the build in the end, and ran it many times locally here. But the builds are showing this again.

% /Applications/MacPorts/SuperTux.app/Contents/MacOS/supertux2
[FATAL] /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_games_supertux/supertux/work/SuperTux-v0.6.2-Source/src/supertux/main.cpp:610 Unexpected exception: boost::filesystem::canonical: No such file or directory: "/Applications/MacPorts/SuperTux.app/Contents/Resources/SuperTux.app/Contents/Resources/data"

I'll have to patch main.cpp I guess, or otherwise sort this out.

Apologies -- thought I had it.

Change History (3)

comment:1 Changed 4 years ago by kencu (Ken)

This launches it:

 % SUPERTUX2_DATA_DIR=/Applications/MacPorts/SuperTux.app/Contents/Resources/data /Applications/MacPorts/SuperTux.app/Contents/MacOS/supertux2

The upstream MacOS application bundle uses a launch script that sets something like this, but this appeared to be working for me, so I didn't think I'd need it.

Worst case scenario, I guess I can write a script for it like they do.

comment:2 Changed 4 years ago by kencu (Ken)

Description: modified (diff)

comment:3 Changed 4 years ago by kencu (Ken)

Resolution: fixed
Status: assignedclosed

In baf8d75c50d11c8dd4e84abd1bf79b0658f5f5ac/macports-ports (master):

supertux: use launch script

this app requires assistance to locate it's
datadir. We use a launch script to launch
it therefore, setting an env var to the
location of the data directory.

Initially it seemed to work properly as it
will reference files in it's original build
directory if they exist.

closes: #61491

Note: See TracTickets for help on using tickets.