WSL/SLF GitLab Repository

Commit b97a8b7a authored by Mathias Bavay's avatar Mathias Bavay
Browse files

Fixed some PATH limitations on MacOS

parent fbcc765d
......@@ -183,7 +183,13 @@ QString getExtraPath(const QString& appname)
#if defined Q_OS_MAC
QString Appname( appname );
Appname[0] = Appname[0].toUpper();
const QString extra_path( ":" +home+"/bin:" + home+"/usr/bin:" + home+"/src/"+appname+"/bin:" + desktop+"/"+appname+"/bin:" + "/Applications/"+appname+".app/Contents/bin:" + "/Applications/"+Appname+".app/Contents/bin:" + "/Applications/"+appname+"/bin:" + "/Applications/"+Appname+"/bin:" + own_path);
const bool already_capitalized = (Appname[0]==appname[0]); //was the first letter of appname already capitalized?
const QString user_paths( home+"/bin:" + home+"/usr/bin:" + home+"/src/"+appname+"/bin:" + desktop+"/"+appname+"/bin" );
const QString system_paths = (already_capitalized)? "/Applications/"+appname+".app/Contents/bin:" + "/Applications/"+appname+"/bin" : "/Applications/"+appname+".app/Contents/bin:" + "/Applications/"+Appname+".app/Contents/bin:" + "/Applications/"+appname+"/bin:" + "/Applications/"+Appname+"/bin";
const QString extra_path( ":" +user_paths+ ":" +system_paths+ ":" + own_path + ":" + own_path+"/../../.."); //own_path + getting out of a .app
return extra_path;
#endif
#if !defined Q_OS_WIN && !defined Q_OS_MAC
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment