Skip to content

Commit

Permalink
Fixed Mac Bundle setup script and its permissions
Browse files Browse the repository at this point in the history
  • Loading branch information
xythobuz committed Mar 12, 2014
1 parent 2e9c185 commit cc9bb0d
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 13 deletions.
13 changes: 2 additions & 11 deletions cmake/setup_mac.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,16 +17,7 @@ if [ ! -d "${HOME}/.OpenRaider" ]; then
fi
if [[ ! -n `find "${HOME}/.OpenRaider/paks" -type f -exec echo Found {} \;` ]]; then
echo "Missing level files!"
osascript -e 'tell app "System Events" to display alert "No level files stored in ~/.OpenRaider/paks\n\nPlace level files there and edit ~/.OpenRaider/OpenRaider.init"'
osascript -e 'tell app "System Events" to display alert "No level files stored in ~/.OpenRaider/paks\n\nPlace original Tomb Raider level files there!"'
else
if [[ ! `diff "${HOME}/.OpenRaider/OpenRaider.init" "../Resources/defaults/OpenRaider.init"` ]]; then
if [[ ! `diff "${HOME}/.OpenRaider/custom.cfg" "../Resources/defaults/custom.cfg"` ]]; then
echo "Unconfigured user!"
osascript -e 'tell app "System Events" to display alert "Please edit ~/.OpenRaider/OpenRaider.init or ~/.OpenRaider/custom.cfg"'
else
./OpenRaider
fi
else
./OpenRaider
fi
./OpenRaider
fi
1 change: 1 addition & 0 deletions src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ if (APPLE)
add_custom_command (TARGET OpenRaider POST_BUILD
COMMAND echo "Injecting setup script..."
COMMAND cp "${PROJECT_SOURCE_DIR}/cmake/setup_mac.sh" "${PROJECT_BINARY_DIR}/src/OpenRaider.app/Contents/MacOS/OpenRaider.sh"
COMMAND chmod "a+x" "${PROJECT_BINARY_DIR}/src/OpenRaider.app/Contents/MacOS/OpenRaider.sh"
)

# Fix executable name, so setup script will be called
Expand Down
3 changes: 1 addition & 2 deletions src/OpenRaider.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -485,7 +485,7 @@ void OpenRaider::handleConsoleKeyPressEvent(unsigned int key,unsigned int mod)
buffer[2] = 0;
break;
default:
// Workaround until proper SDL2 text input is used
//! \fixme Workaround until proper SDL2 text input is used
if ((key >= 1073742049) && (key <= 1073742051))
break;

Expand Down Expand Up @@ -2698,7 +2698,6 @@ void OpenRaider::processRoom(int index)
//fflush(stdout);
}

//! \fixme Use rc_get_bool consistently!
void OpenRaider::consoleCommand(char *cmd)
{
bool b = false;
Expand Down

0 comments on commit cc9bb0d

Please sign in to comment.