Skip to content

Instantly share code, notes, and snippets.

@mephir
Created July 27, 2025 12:09
Show Gist options
  • Select an option

  • Save mephir/132b59a7a28c34b258a947a3fc4d4580 to your computer and use it in GitHub Desktop.

Select an option

Save mephir/132b59a7a28c34b258a947a3fc4d4580 to your computer and use it in GitHub Desktop.
OrcaSlicer Gentoo distribution script
FOUND_GTK3=$(emerge -p x11-libs/gtk+:3 > /dev/null 2>&1 && echo "1" || echo '')
export REQUIRED_DEV_PACKAGES=(
dev-build/cmake
net-misc/curl
sys-apps/dbus
gui-libs/eglexternalplatform
kde-frameworks/extra-cmake-modules
sys-devel/gettext
dev-vcs/git
dev-libs/openssl
media-libs/glew
media-libs/gstreamer
dev-libs/libmspack
app-crypt/libsecret
dev-libs/libspnav
dev-build/libtool
virtual/libudev
dev-build/ninja
sys-apps/texinfo
net-misc/wget
net-libs/webkit-gtk
dev-libs/wayland-protocols
)
if [[ -n "$UPDATE_LIB" ]]
then
echo -n -e "Updating dependencies ...\n"
NEEDED_PKGS=""
NEEDED_USE_WXGTK=""
for PKG in ${REQUIRED_DEV_PACKAGES[@]}; do
emerge -p x11-libs/gtk+:3 > /dev/null 2>&1 || NEEDED_PKGS+=" ${PKG}"
done
if [ -n "${NEEDED_PKGS}" ]; then
sudo emerge -v ${NEEDED_PKGS}
fi
# Check x11-libs/wxGTK with webkit USE flag
if ! emerge -pv x11-libs/wxGTK 2>&1 | grep -qE '^-webkit'
then
echo -e "x11-libs/wxGTK not installed or missing required USE flag webkit\n"
sudo USE="webkit" emerge -v x11-libs/wxGTK
fi
echo -e "done\n"
exit 0
fi
FOUND_GTK3_DEV=${FOUND_GTK3}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment