Lich:Software/Mac Installation: Difference between revisions

The official GemStone IV encyclopedia.
< Lich:Software
Jump to navigation Jump to search
mNo edit summary
mNo edit summary
Line 25: Line 25:
# Enter the following command to expand the package: <p><code>unzip OldSkoolBrew.zip</code></p>
# Enter the following command to expand the package: <p><code>unzip OldSkoolBrew.zip</code></p>
# Run the following command to copy the files to your Homebrew formulas folder: <p><code>cp ./OldSkoolBrew/* /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula/</code></p>
# Run the following command to copy the files to your Homebrew formulas folder: <p><code>cp ./OldSkoolBrew/* /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula/</code></p>
# Run the following command to install the first set of required formulas: <p><code>HOMEBREW_NO_AUTO_UPDATE=1 brew install cairo</code></p><p>Note, this may take 20-30 minutes to complete. You will see Homebrew performing a long list of installations. If the process completes successfully, you will return to a new Terminal prompt once all the packages are installed.</p>
# Run the following command to install the first set of required formulas: <p><code>HOMEBREW_NO_AUTO_UPDATE=1 brew install --build-from-source cairo</code></p><p>Note, this may take 20-30 minutes to complete. You will see Homebrew performing a long list of installations. If the process completes successfully, you will return to a new Terminal prompt once all the packages are installed.</p>
# Run the following command to make sure these new formulas do not update automatically: <p><code>brew pin cairo</code></p>
# Run the following command to make sure these new formulas do not update automatically: <p><code>brew pin cairo</code></p>
# Run the following command to install the second set of required formulas: <p><code>HOMEBREW_NO_AUTO_UPDATE=1 brew install gtk+</code></p><p>Note, this may take 20-30 minutes to complete. You will see Homebrew performing a long list of installations. If the process completes successfully, you will return to a new Terminal prompt once all the packages are installed.</p>
# Run the following command to install the second set of required formulas: <p><code>HOMEBREW_NO_AUTO_UPDATE=1 brew install --build-from-source pango gtk+</code></p><p>Note, this may take 20-30 minutes to complete. You will see Homebrew performing a long list of installations. If the process completes successfully, you will return to a new Terminal prompt once all the packages are installed.</p>
# Run the following command to make sure these new formulas do not update automatically: <p><code>brew pin pango gtk+</code></p>
# Run the following command to make sure these new formulas do not update automatically: <p><code>brew pin pango gtk+</code></p>
# Run the following command to update the system Ruby (this has been tested to work with 2.6.5 and 2.7.1): <p><code>HOMEBREW_NO_AUTO_UPDATE=1 brew install ruby@2.6</code></p>
# Run the following command to update the system Ruby (this has been tested to work with 2.6.5 and 2.7.1): <p><code>HOMEBREW_NO_AUTO_UPDATE=1 brew install ruby@2.6</code></p>

Revision as of 08:44, 14 June 2020

With Mac Mojave and Catalina, Ruby 2.6 and 2.7, and changes to various gems used to support the game, the old script does not work.

To install Lich on newer versions of Mac OS, you will need to install formulas using Homebrew that recreate the way older technologies worked. You will need a bit of familiarity with the Mac Terminal application to get this done. Some familiarity with Homebrew will help, although you should be able to follow the steps below without any prior knowledge of Homebrew.

This guide will attempt to install Lich for the Avalon Front End only. The entire process will take 60-90 minutes to complete, but the time required will depend on how many prerequisites you need to install and how many errors you encounter. If you get stuck, or for information about other front ends, please contact Doug (doug@play.net or Doug#6198 on Discord) for help.

Please note that this guide will involve changing settings on your device for the technologies involved. You will need to decide whether it’s safe for you to customize these tools to work with Lich. If you have no idea what any of these technologies are, then you probably aren’t using them for any other purpose, but proceed at your own risk.

This guide has only been tested under a limited number of system conditions. Systems with different initial states or versions of these tools installed will behave differently and errors will occur. Your mileage may vary, but these steps should provide hints to what may be going wrong and accelerate any debugging of the issues.

Before You Start

You will need to install a few things.

  1. Install the Avalon Front End from the play.net site.
  2. Install the DMG file from the Xquartz site.
  3. After you've installed the Xquartz DMG, this is the best time to log out and log back in on your Mac. You will be required to do so before everything will work, but right now is the best time. So log out, then log back in.
  4. Install Homebrew by following the instructions at the Homebrew site.


The Process

  1. Open the Terminal application and move to a folder where you would like to install this project. The following steps will all be run in the Terminal.
  2. Enter the following command to fetch Doug's ‘Old Skool Brew’ package:

    curl -OL https://github.com/OSXLich-Doug/OSXLich-Install/raw/master/OldSkoolBrew.zip

  3. Enter the following command to expand the package:

    unzip OldSkoolBrew.zip

  4. Run the following command to copy the files to your Homebrew formulas folder:

    cp ./OldSkoolBrew/* /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula/

  5. Run the following command to install the first set of required formulas:

    HOMEBREW_NO_AUTO_UPDATE=1 brew install --build-from-source cairo

    Note, this may take 20-30 minutes to complete. You will see Homebrew performing a long list of installations. If the process completes successfully, you will return to a new Terminal prompt once all the packages are installed.

  6. Run the following command to make sure these new formulas do not update automatically:

    brew pin cairo

  7. Run the following command to install the second set of required formulas:

    HOMEBREW_NO_AUTO_UPDATE=1 brew install --build-from-source pango gtk+

    Note, this may take 20-30 minutes to complete. You will see Homebrew performing a long list of installations. If the process completes successfully, you will return to a new Terminal prompt once all the packages are installed.

  8. Run the following command to make sure these new formulas do not update automatically:

    brew pin pango gtk+

  9. Run the following command to update the system Ruby (this has been tested to work with 2.6.5 and 2.7.1):

    HOMEBREW_NO_AUTO_UPDATE=1 brew install ruby@2.6

  10. Next, link the installed ruby into the right place to be used:

    HOMEBREW_NO_AUTO_UPDATE=1 brew link --force ruby@2.6

  11. Now you will need to check if you are running Bash or the Z shell. Enter the following command to check your shell:

    echo $SHELL

    1. If the Terminal displays /bin/bash, run the following commands:

      echo 'export PATH=/usr/local/opt/ruby/bin:$PATH' >> ~/.bash_profile

      source ~/.bash_profile

    2. If the Terminal displays /bin/zsh, run the following commands:

      echo 'export PATH=/usr/local/opt/ruby/bin:$PATH' >> ~/.zshrc

      source ~/.zshrc

  12. We have two required Ruby gems to install. Run the following command to install the first gem:

    gem install sqlite3 --no-document

  13. Run the following command to install the second gem:

    gem install gtk2 --no-document

  14. Now run a quick test to see if things work:
    1. Run the following command to start the Ruby shell (you will see the command prompt change):

      Irb

    2. Run this command to test if the first gem is working:

      require 'sqlite3'

      The system should respond true

    3. Run this command to test if the second gem is working:

      require 'gtk2'

      This should start Xquartz in the background and respond true in the Terminal. It might take a few seconds!

  15. Nearly there! Now get the Lich files:
    1. Download the Lich files (Windows/Mac all run the same files).
    2. Put the file in a location you know the path to (for example, your desktop or a folder for this project).
    3. Unzip it.
  16. Run the following command in the Terminal (note, you must enter the correct path to the folder where you put Lich):

    ruby ~/[PATH TO LICH]/lich/lich.rbw

    (From now on, you must use this command to start the game, rather than opening the Front End directly.)

  17. After a couple seconds, this will open the Lich login window.
    1. Give it your login information, and click connect.
    2. Select your character, select the Avalon Front End, and click Play. (Don’t bother to save, that doesn’t work.)
    3. The game will start! You will see some new Lich-related text in the scroll, including a repository error (normal).
  18. Get started by installing the maps database with the following command (in game): ;repo download-mapdb
  19. Good luck and have fun! For more instructions on Lich, look for guides elsewhere.

Lich for Other Front Ends

No guides are available at this time, please email doug@play.net for help.

Resources

Third-Party Software - edit
Lich Installation: Lich
Downloadable Lich Scripts: Go2 | Map | Repository | Popular Scripts