Skip to content

makerbot/Toolchain-Release

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This repo contains scripts for building and packaging our software, as well as manipulating groups of code repositories (toolchains).

Key scripts

  • update-repos.py: Pulls down a toolchain or updates it.
  • build-repos.py: Tries to compile a toolchain.
  • jenkins-build.py: Builds the toolchain in 'install mode' and builds the platform-specific installer package
  • repositories_settings.py: Modifies the function of the above scripts. More info can be found in doc/repositories_settings.md

Setup and Building

Setting all dependencies to build a toolchain locally is toolchain and OS dependent

Toolpather/MB Print Setup

Firmware Setup

Other firmware development links

Ubuntu setup

  • Install some basic utilities
sudo apt-get install build-essential cmake-curses-gui
sudo apt-get install git python python-setuptools python-software-properties python-pip
sudo apt-get install openssh-server lsb-release devscripts cdbs debhelper libudev-dev libjpeg-dev genext2fs libusb-1.0-0-dev
  • If you are using Ubuntu Precise (12.04), get a new computer

  • If you are using Ubuntu Xenial (16.04):

Manually install Python3.4:

mkdir python-build && cd python-build
wget https://www.python.org/ftp/python/3.4.5/Python-3.4.5.tgz
tar xf Python-3.4.5.tgz
cd Python-3.4.5
./configure --prefix=/usr --enable-shared  # this is important for firmware builds especially
make
sudo make altinstall  # this will install Python3.4 alongside 3.5 instead of overwriting it

Alternatively, you can install Python3.4 from the deadsnakes repo:

sudo add-apt-repository ppa:deadsnakes/ppa
sudo apt-get update
sudo apt-get install python3.4 python3.4-dev python3-pip

If you are going to build firmware:

  • Install 32-bit libc:
    sudo apt-get install libc6-i386 libssl-dev
  • Install Qt:

    Recommended that you do not use apt-get to install Qt. Goto https://www.qt.io/download-open-source/ to download the Qt Open Source Installer. Select Qt version 5.10.1 when performing install. You will need to make symbolic links for the qmake, lrelease, and lupdate binaries.

    sudo ln -s /path/to/Qt/5.10.1/gcc_64/bin/qmake /usr/local/bin/qmake
    sudo ln -s /path/to/Qt/5.10.1/gcc_64/bin/lrelease /usr/local/bin/lrelease
    sudo ln -s /path/to/Qt/5.10.1/gcc_64/bin/lupdate /usr/local/bin/lupdate

Install yajl and boost:

sudo apt-get install libyajl-dev
sudo apt-get install libboost1.58-all-dev
sudo apt-get install mercurial  # only necessary if you want to do full build-root builds

Pip install some additional dependencies:

    sudo pip install protobuf
  • Use git to download our main repository
    git clone [email protected]:makerbot/Toolchain-Release.git
    cd Toolchain-Release/
  • Add our internal master repository
  • Use double quotes ("), not single quotes(')
  • This command will automatically add the correct distribution
sudo apt-add-repository "http://sid.soft.makerbot.net/apt/develop"
sudo apt-get update
  • In the root of the Toolchain-Release repository there is a file called ./ubuntusetup.sh If you run it it will install all of the build dependencies for you (if it doesn't go bug Ryan)

  • Either make sure you do not have qt4 installed, or add the following to your environment: export QT_SELECT=qt5

  • You also need python3.4 with pip and some extra python packages:

pip3 install wheel jsonschema aiohttp netifaces appdirs lockfile watchdog
sudo pip3 install artifactory
  • From the Toolchain-Release directory invoke the following command: ./update-repos.py --toolchain=desktop This will pull down either the source or artifacts of each of our other repositories depending default settings
  • After downloading all of the sources run ./build-repos.py

If there are any errors related to missing packages please bother Ryan to update the ubuntusetup script(or do it yourself)

This command will take a long time to finish. It will download the source package tarballs for all of our projects, extract them, then for each one it will install the build dependencies and compile the project.

Mac-specific Tools Setup

Setup instructions for 10.10. These instructions are up to date as of August 2016, and are probably still more correct than anything else even for different OSX versions.

Once setup is done you should be able to run any of the following, depending on what you want to build:

./update-repos.py --toolchain=penguin  # dependencies for makerbot print
./update-repos.py --toolchain=sliceconfig
./update-repos.py --toolchain=toolpathviz2

and then run ./build-repos.py to actually build. You may even be able to build the desktop toolchain (i.e. makerbot desktop 3.x), although in all likelihood there is still something missing from the setup instructions.

Windows-specific Tools Setup.

The following instructions assume you're doing a 64 bit build, substitute the 32 bit versions of any of the following:

  • Install latest version of Python 2. At the time of writing, 2.7.18 was the latest version.

  • Install Boost(again ask for an updated version, 1.61 at time of writing) 64bit: https://sourceforge.net/projects/boost/files/boost-binaries/1.61.0/boost_1_61_0-msvc-14.0-64.exe/download

  • Now we need to set up the environment and install some python modules from pip

    • Run pip install requests urllib3
    • Run pip install http://y.soft.makerbot.net/files/artifactory-0.1.11-py2-none-any.whl. It installs our custom artifactory python 2 module to your system. Functions like get_dependencies.py use it to communicate with our artifactory server
  • Install nvm: https://github.com/coreybutler/nvm-windows

  • Install node (right now we're using 14.15.3)

    • Run nvm install 14.15.3
  • Open a command prompt, create a directory called Toolchain and cd into it. Run git clone [email protected]:third-party-win.git. Enter the password when prompted. If you don't know the password, ask your team lead or authorized personnel.

  • While in Toolchain directory run git clone [email protected]:makerbot/Toolchain-Release.git to download Toolchain-Release repo

  • cd into Toolchain/third-party-win and run ./setup_devtools.bat then close and re-open command prompt to make the changes take

  • (Optional) Install NSIS so you can build the installer http://nsis.sourceforge.net/Download

Getting our sources & building

  • At the root of the Toolchain-Release repo run update-repos.py. This will run a bunch of git commands to pull down additional repositories and their submodules into the "Toolchain" subdirectory. It also installs a set of git-hooks that do style checking and other things. You can run this again at any time to pull down the latest updates for everything. You can specify various parameters such as toolchain, platform etc. Run python ./update-repos.py -h for help and more details. A typical command will look something like this:
  python ./update-repos.py --toolchain=toolpather
  • Run "build-repos.py" to compile everything. This part will probably take a while, since you'll likely run into a lot of issues involving missing/misconfigured dependencies that aren't well documented. Please document them. A typical command will look something like this:
python ./build-repos.py