From 6c6e958ff739c09d8c991299517a3b3093c801c8 Mon Sep 17 00:00:00 2001 From: jason-c-dev Date: Tue, 1 Sep 2026 19:41:19 -0700 Subject: [PATCH] Detect newer GCC, and quiet a desktop-file-validate warning The compiler search stopped at g++-15, so a machine whose only versioned compiler is g++-16 fell through to the plain-g++ fallback -- and if the default g++ happened to be older than 11, the script died with a message pointing at the wrong problem. Walking down from 30 costs a few builtin lookups and does not need touching again. Separately, desktop-file-validate warns on Categories=Office;Utility; value "Office;Utility;" for key "Categories" ... contains more than one main category; application might appear more than once in the menu Office alone is the accurate one. --- granola-linux.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/granola-linux.sh b/granola-linux.sh index 9a768f8..14bebef 100755 --- a/granola-linux.sh +++ b/granola-linux.sh @@ -41,7 +41,10 @@ info "7zz: $SEVENZZ" CXX="" -for v in 15 14 13 12 11; do +# Newest first. A fixed list goes stale every time GCC ships a major release, +# and the failure is confusing: a box with only g++-16 installed under a +# versioned name gets told it needs "g++ 11 or newer". +for v in $(seq 30 -1 11); do if command -v "g++-$v" >/dev/null; then CXX="g++-$v"; CC="gcc-$v"; break; fi done if [[ -z "$CXX" ]] && command -v g++ >/dev/null; then @@ -161,7 +164,7 @@ Comment=AI Notepad for meetings Exec=$INSTALL_DIR/granola.sh %U Icon=$INSTALL_DIR/granola-icon.png Terminal=false -Categories=Office;Utility; +Categories=Office; StartupWMClass=granola MimeType=x-scheme-handler/granola; EOF