From 8189d9ad4ea5885e52271055c4bf976042f1c2cc Mon Sep 17 00:00:00 2001 From: Menno van Leeuwen Date: Tue, 20 May 2025 20:20:34 +0200 Subject: [PATCH] feat: add GCC 13 configuration for Pop!_OS in .bashrc --- .bashrc | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/.bashrc b/.bashrc index 64b533b..59d1b58 100644 --- a/.bashrc +++ b/.bashrc @@ -9,6 +9,22 @@ if [ "$(hostname)" = "mennos-desktop" ]; then export MESA_VK_DEVICE_SELECT=1002:744c fi +if [ -f /etc/os-release ]; then + distro=$(awk -F= '/^NAME/{print $ssss2}' /etc/os-release | tr -d '"') + if [[ "$distro" == *"Pop!_OS"* ]]; then + # Set GCC 13 as default compiler + export CC=/usr/bin/gcc-13 + export CXX=/usr/bin/g++-13 + + # Point to GCC 13 headers (fixed path) + export CPLUS_INCLUDE_PATH="/usr/include/c++/13:/usr/include/x86_64-linux-gnu/c++/13" + + # Add library paths (recommended) + export LIBRARY_PATH="/usr/lib/gcc/x86_64-linux-gnu/13:$LIBRARY_PATH" + export LD_LIBRARY_PATH="/usr/lib/gcc/x86_64-linux-gnu/13:$LD_LIBRARY_PATH" + fi +fi + # Docker Compose Alias (Mostly for old shell scripts) alias docker-compose='docker compose'