Skip to content

Setting Up Environment

Package Installations

  1. Open your web browser and go to Akhilnarang Scripts.

  2. Clone the entire repository by running the following command in your terminal:

    git clone https://github.com/akhilnarang/scripts
    

  3. Navigate to the cloned repository by running the following command:

    cd scripts
    

  4. Depending on your Linux distribution, execute the appropriate command below to set up the necessary dependencies for your build environment:

  5. For Ubuntu and Debian-based distributions, run:

    bash setup/android_build_env.sh
    
    (This is the recommended option for beginners to avoid any potential issues.)

  6. For Arch-based distributions (e.g., Manjaro), run:

    bash setup/arch-manjaro.sh
    

  7. For Fedora, run:

    bash setup/fedora.sh
    

  8. For OpenSUSE, run:

    bash setup/opensuse.sh
    

  9. For Solus, run:

    bash setup/solus.sh
    

  10. Wait patiently while all the dependencies are being installed.

  11. Add it to PATH

  12. Open .bashrc

    nano .bashrc
    

  13. Scroll to the end of the file and type these lines:

# Export ~/bin
export PATH=~/bin:$PATH
  • Ctrl-O and enter to save, then Ctrl-X to exit nano. Now either logout and login again (or reboot), or source the file:
source .bashrc

Verification

Verify the installation of the build tools by checking their versions:

  • Git: Run git --version.
  • Make: Run make --version.
  • Zip: Run zip --version.
  • Curl: Run curl --version.
  • GCC (GNU Compiler Collection): Run gcc --version.
  • G++ (GNU C++ Compiler): Run g++ --version.

Congratulations! Your build environment is now fully set up and ready to use. Enjoy building!