diff options
author | starkos <none@none> | 2008-12-22 23:26:18 +0300 |
---|---|---|
committer | starkos <none@none> | 2008-12-22 23:26:18 +0300 |
commit | 783a10c6280decd92db3538f018800f162fee625 (patch) | |
tree | 3a2f21cd4c07a54a62d9ba8b5fa3ed69f00ab50b | |
parent | 4c6e2abbd2bfb31804ea8f3e7403cc20f6d47a79 (diff) |
Add search of /etc/ld.so.conf to os.findlib()
-rw-r--r-- | src/base/os.lua | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/base/os.lua b/src/base/os.lua index aec9158..bdebdc4 100644 --- a/src/base/os.lua +++ b/src/base/os.lua @@ -23,6 +23,14 @@ else formats = { "lib%s.so", "%s.so" } path = os.getenv("LD_LIBRARY_PATH") + + local f = io.open("/etc/ld.so.conf", "r") + if f then + for line in f:lines() do + path = path .. ":" .. line + end + f:close() + end end table.insert(formats, "%s") |