This guide provides instructions for compiling BambuStudio on Linux systems, specifically for Ubuntu, Fedora, and Solus distributions. BambuStudio is the official slicing software for Bambu Lab 3D printers.
Reference: BambuStudio GitHub Repository
Install the following tools before building:
sudo apt-get install cmake clang git g++ build-essential libgl1-mesa-dev m4 libwayland-dev libxkbcommon-dev wayland-protocols extra-cmake-modules pkgconf libglu1-mesa-dev libcairo2-dev libgtk-3-dev libsoup2.4-dev libwebkit2gtk-4.0-dev libgstreamer1.0-dev libgstreamer-plugins-good1.0-dev libgstreamer-plugins-base1.0-dev gstreamer1.0-plugins-bad libosmesa6-dev nasm yasm libx264-devNote: gstreamer1.0-plugins-bad provides the h264 decoder in gstreamer for liveview functionality.
Install the following tools before building:
sudo dnf install -y https://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm
sudo dnf install gcc gcc-c++ cmake
sudo dnf install mesa-libGL-devel mesa-libGLU-devel
sudo dnf install m4
sudo dnf install perl
sudo dnf install extra-cmake-modules
sudo dnf install wayland-devel wayland-protocols-devel libxkbcommon-devel
sudo dnf install gtk3-devel webkit2gtk3-devel
sudo dnf install gstreamer1-devel gstreamer1-plugins-base-devel
sudo dnf install gstreamer1-plugin-openh264 #for linux liveview decoder requirement
sudo dnf install mesa-libOSMesa-devel
sudo dnf install nasm yasm x264-devel #for ffmpegInstall the following tools before building:
sudo eopkg it -c system.devel
sudo eopkg it git llvm-clang libglvnd-devel wayland-devel libxkbcommon-devel wayland-protocols-devel extra-cmake-modules libcairo-devel libgtk-3-devel libsoup-devel libwebkit-gtk-devel gstreamer-1.0-devel gstreamer-1.0-plugins-base-devel gstreamer-1.0-plugins-good gstreamer-1.0-plugins-bad gstreamer-1.0-plugins-bad-devel mesalib-devel libx11-devel glew-devel curl-develYou need to build the dependencies of BambuStudio first. (Only needed for the first time)
Setup Instructions:
- Suppose you download the codes into
/home/username/work/projects/BambuStudio - Create a directory to store the dependencies:
/home/username/work/projects/BambuStudio_dep(Please make sure to replaceusernamewith the one on your computer)
cd BambuStudio/deps
mkdir build
cd build
cmake ../ -DDESTDIR="/home/username/work/projects/BambuStudio_dep" -DCMAKE_BUILD_TYPE=Release -DDEP_WX_GTK3=1
make -jN # N can be a number between 1 and the max cpu numberNote: This will use libjpeg with version 80 by default. If your system's gstreamer has a different jpeg version, try to add -DJPEG_VERSION=N (N=6 or 7 or 8).
For example, if your gstreamer uses libjpeg version 6:
cmake ../ -DDESTDIR="/home/username/work/projects/BambuStudio_dep" -DCMAKE_BUILD_TYPE=Release -DDEP_WX_GTK3=1 -DJPEG_VERSION=6How to check the libjpeg version used by gstreamer:
- Go to your gstreamer library directory (e.g., Fedora at
/lib64/gstreamer-1.0, Ubuntu at/lib/x86_64-linux-gnu/gstreamer-1.0/) - Execute
ldd libgstjpeg.soand find thelibjpeg.so.xused - If x is 62, then set
JPEG_VERSIONto 6 - If x is 7, then set
JPEG_VERSIONto 7 - If x is 8, then set
JPEG_VERSIONto 8 or not set
Note: This flag only affects the liveview of P1P. If you don't care about this function, just skip it.
Create a directory to store the installed files:
cd BambuStudio
mkdir install_dir
mkdir build
cd build
cmake .. -DSLIC3R_STATIC=ON -DSLIC3R_GTK=3 -DBBL_RELEASE_TO_PUBLIC=1 -DCMAKE_PREFIX_PATH="/home/username/work/projects/BambuStudio_dep/usr/local" -DCMAKE_INSTALL_PREFIX="../install_dir" -DCMAKE_BUILD_TYPE=Release
cmake --build . --target install --config Release -jN # N can be a number between 1 and the max cpu numberCurrently, we support building using scripts under Ubuntu and Fedora:
cd BambuStudio
./BuildLinux.sh -u # install dependency packages
./BuildLinux.sh -dsi # build and create appimageThe binary and AppImage will be generated.
These steps have been verified on Ubuntu and Fedora.
For more Linux platforms or script building, you can find details or help at BambuStudio build for Linux (Thanks to all the contributors).
BambuStudio includes the following key features:
- Basic slicing features & GCode viewer
- Multiple plates management
- Remote control & monitoring
- Auto-arrange objects
- Auto-orient objects
- Hybrid/Tree/Normal support types, Customized support
- Multi-material printing and rich painting tools
- Multi-platform (Win/Mac/Linux) support
- Global/Object/Part level slicing parameters
BambuStudio is licensed under the GNU Affero General Public License, version 3. BambuStudio is based on PrusaSlicer by PrusaResearch.
- GitHub Repository: https://github.com/bambulab/BambuStudio
- Issues: Report issues on the GitHub tracker if they aren't already present
- Documentation: See the wiki and documentation directory for more information
Last Updated: 2024 For AIS Construction Lab, McGill University