In Linux there are standard locations for shared binary libraries like /usr/local/lib and /usr/lib and a standard mechanism that allows linker to locate libraries placed there without full path specified.
I'm looking for a similar mechanism for shell libraries (i.e., shell scripts that are called from another shell scripts) that allows shell to locate a library even if its path isn't specified.
I know that I can find out the caller's path and calculate the path to a library from that but I don't think that's a good approach. First of all, because there's no reliable way to determine the location of a shell script.
So, does Linux provide a mechanism to locate shell libraries?
zshcomes close with itsfpathto indicate directories in which autoloaded functions can be found. - chepner