Skip to content

Commit

Permalink
fix: update lrelease executable search paths for Qt5/Qt6 (#27)
Browse files Browse the repository at this point in the history
Add specific search paths for lrelease in Qt5 and Qt6 directories before falling back to default system path.

Log: update lrelease executable search paths for Qt5/Qt6
  • Loading branch information
wyu71 committed Feb 8, 2025
1 parent 7691e09 commit 93b1235
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/translate_generation.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,15 @@

ts_list=(`ls ../translations/*.ts`)

# 优先使用Qt6 lrelease工具
if [ -f "/usr/lib/qt6/bin/lrelease" ]; then
lrelease="/usr/lib/qt6/bin/lrelease"
elif [ -f "/usr/lib/qt5/bin/lrelease" ]; then
lrelease="/usr/lib/qt5/bin/lrelease"
else
lrelease="lrelease"
fi

for ts in "${ts_list[@]}"
do
printf "\nprocess ${ts}\n"
Expand Down

0 comments on commit 93b1235

Please sign in to comment.