From 7b7dfa26bc6158f391ad0ed2ae2f084b05715178 Mon Sep 17 00:00:00 2001 From: mikee47 Date: Fri, 21 Jun 2024 09:23:06 +0100 Subject: [PATCH] Update getting-started docs. --- docs/source/getting-started/macos/index.rst | 86 ++++++++------------- 1 file changed, 32 insertions(+), 54 deletions(-) diff --git a/docs/source/getting-started/macos/index.rst b/docs/source/getting-started/macos/index.rst index 44acdf25a2..adfd53ca2c 100644 --- a/docs/source/getting-started/macos/index.rst +++ b/docs/source/getting-started/macos/index.rst @@ -3,90 +3,68 @@ Mac-OS Installation .. highlight:: bash -Pre-requisites --------------- -*(You might already have it)* +Quick Install +------------- -Xcode command line tools -~~~~~~~~~~~~~~~~~~~~~~~~ - -:: +1. Install command-line development tools:: xcode-select --install -Homebrew -~~~~~~~~ +2. Check if ``homebrew`` is installed:: -:: + brew - ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" + If not, install it:: -Eclipse -~~~~~~~ + /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" -*(Optional)*:: + Check https://brew.sh/ if there's any issues here. - brew install Caskroom/cask/eclipse-cpp +3. Prepare installation directory -Build tools ------------ + Let's use /opt as the main directory for tools and Sming. -Required for the makefile build system:: + Regular users may not have access to */opt*, so do this:: - brew install binutils coreutils automake wget gawk libtool gettext gperf grep - export PATH="/usr/local/opt/gnu-sed/libexec/gnubin:$PATH" + sudo chown $USER /opt -Install gnu-sed and make sure that it is the default ``sed`` command line application:: + (alternatively, use a different directory). - brew install gnu-sed --with-default-names +4. Fetch the Sming repository:: -If you have already installed ``gnu-sed`` but it is not the default one, -then make sure to uninstall it and install it again with the correct options:: + git clone https://github.com/SmingHub/Sming /opt/sming - brew uninstall gnu-sed - brew install gnu-sed --with-default-names + If using a directory other than ``/opt`` then you'll need to edit ``sming/Tools/export.sh`` before proceeding. -ESP8266 Toolchain ------------------ +5. Run the installer:: -We pull this in from the `SmingTools `__ repository:: + source /opt/sming/Tools/install.sh all - cd ~/ - export ESP_HOME=/opt/esp-quick-toolchain - curl -LO https://github.com/SmingHub/SmingTools/releases/download/1.0/x86_64-apple-darwin14.xtensa-lx106-elf-e6a192b.201211.tar.gz - sudo mkdir -p $ESP_HOME - sudo tar -zxf x86_64-apple-darwin14.xtensa-lx106-elf-e6a192b.201211.tar.gz -C $ESP_HOME - sudo chmod -R 775 $ESP_HOME + If you want to save disk space then you can select which tools to install. + Get a list of available options like this:: -You can also build it yourself -`with Homebrew `__ or -`with MacPorts `__. + /opt/sming/Tools/install.sh -Get Sming Core --------------- -Clone from the `Sming `__ repository:: +Vscode +------ - cd / - git clone https://github.com/SmingHub/Sming.git - cd Sming +See https://code.visualstudio.com/. -.. warning:: - Do NOT use the --recursive option for the command above. - Our build mechanism will take care to get the third-party sources and patch them, if needed. +Eclipse +------- + +*(Optional)*:: -You will get a copy of our `develop` branch which is intended for developers. -It is the one where all new cool (unstable) features are landing. + brew install Caskroom/cask/eclipse-cpp -If you want to use our stable branch then use the master branch:: - git checkout origin/master +.. note:: -Finally, set the :envvar:`SMING_HOME` environment variable to point to /Sming/Sming:: + The following information may be out of date. - export SMING_HOME=`pwd` Environment Variables --------------------- @@ -94,7 +72,7 @@ Environment Variables Open with a text editor the ``.profile`` file in your home directory, and add these lines:: export ESP_HOME=/opt/esp-quick-toolchain - export SMING_HOME=/Sming/Sming + export SMING_HOME=opt/Sming/Sming Make sure to replace ```` in the command above with the actual directory on your local disk.