Skip to content

Commit

Permalink
Fix GLFW3 library name during install on OSX
Browse files Browse the repository at this point in the history
The glfw library has been renamed on OSX from glfw3 to glfw.
  • Loading branch information
umar456 committed May 15, 2017
1 parent f129a08 commit d7552e3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
3 changes: 1 addition & 2 deletions CMakeModules/osx_install/InstallTool.cmake
Expand Up @@ -2,8 +2,7 @@
EXECUTE_PROCESS( COMMAND otool -L ${CMAKE_CURRENT_BINARY_DIR}/package/lib/libforge.dylib
COMMAND grep glfw
COMMAND cut -d\ -f1
COMMAND xargs -Jglfwlib install_name_tool -change glfwlib /usr/local/lib/libglfw3.dylib ${CMAKE_CURRENT_BINARY_DIR}/package/lib/libforge.dylib
COMMAND xargs -Jglfwlib install_name_tool -change glfwlib /usr/local/lib/libglfw.dylib ${CMAKE_CURRENT_BINARY_DIR}/package/lib/libforge.dylib
OUTPUT_FILE /tmp/af.out
ERROR_FILE /tmp/af.err
)

4 changes: 2 additions & 2 deletions CMakeModules/osx_install/forge_scripts/postinstall
Expand Up @@ -45,9 +45,9 @@ else
echo "Homebrew/Versions already present in brew tap." >> $err_file
fi

GLFW_INSTALLED=$(su $user -c "$brew ls --versions glfw3" | grep "glfw3") || true
GLFW_INSTALLED=$(su $user -c "$brew ls --versions glfw" | grep "glfw") || true
if [[ -z "${GLFW_INSTALLED}" ]]; then
echo "Installing GLFW3" >> $err_file
echo "Installing GLFW" >> $err_file
echo "-------------------" >> $err_file
su $user -c "$brew install glfw" >> $err_file 2>&1 || deps_err
echo "-------------------" >> $err_file
Expand Down

0 comments on commit d7552e3

Please sign in to comment.