美文网首页
Mac 安装 Glew 与 GLFW

Mac 安装 Glew 与 GLFW

作者: 猫爪 | 来源:发表于2021-10-26 16:01 被阅读0次

    其实很简单就2 句

    brew install glew
    brew install glfw3
    

    But , The problem is brew, 阿西吧, brew 要更新,终端一直 超时 time out

    brew update -verbose
    Error:
      homebrew-core is a shallow clone.
      homebrew-cask is a shallow clone.
    To `brew update`, first run:
      git -C /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core fetch --unshallow
      git -C /usr/local/Homebrew/Library/Taps/homebrew/homebrew-cask fetch --unshallow
    
    

    更改了 更新的相关镜像就可以了

    • 步骤1.替换Homebrew源.

      $ cd "$(brew --repo)"
      $ git remote set-url origin https://mirrors.ustc.edu.cn/brew.git
      
      
      • "$(brew --repo)"是用来自动指向Homebrew的目录的.
    • 步骤2.替换homebrew-core源.

      $ cd "$(brew --repo)/Library/Taps/homebrew/homebrew-core"
      $ git remote set-url origin https://mirrors.ustc.edu.cn/homebrew-core.git
      
      
    • 步骤3.替换homebrew-cask源.

      $ cd "$(brew --repo)"/Library/Taps/homebrew/homebrew-cask
      $ git remote set-url origin https://mirrors.ustc.edu.cn/homebrew-cask.git
      
      
    • 参考链接 link.

    Done.

    相关文章

      网友评论

          本文标题:Mac 安装 Glew 与 GLFW

          本文链接:https://www.haomeiwen.com/subject/qmcyaltx.html