diff options
author | Vadim Misbakh-Soloviov <mva@mva.name> | 2013-06-14 15:15:05 +0700 |
---|---|---|
committer | Vadim Misbakh-Soloviov <mva@mva.name> | 2013-06-14 15:15:05 +0700 |
commit | 5554e154375101f958abf6747537cb4110eac82d (patch) | |
tree | 2c5526c4c1e0a57a8324fe349d571e83fcc868ca /tools/xep227toprosody.lua | |
parent | eb2837ec6dda62615b65af213847abaf859d752a (diff) | |
download | prosody-5554e154375101f958abf6747537cb4110eac82d.tar.gz prosody-5554e154375101f958abf6747537cb4110eac82d.zip |
package{,c}path fixes for migration tools
Diffstat (limited to 'tools/xep227toprosody.lua')
-rwxr-xr-x | tools/xep227toprosody.lua | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tools/xep227toprosody.lua b/tools/xep227toprosody.lua index b5156f45..0862b0c1 100755 --- a/tools/xep227toprosody.lua +++ b/tools/xep227toprosody.lua @@ -25,6 +25,12 @@ package.path = package.path..";../?.lua"; package.cpath = package.cpath..";../?.so"; -- needed for util.pposix used in datamanager +local my_name = arg[0]; +if my_name:match("[/\\]") then + package.path = package.path..";"..my_name:gsub("[^/\\]+$", "../?.lua"); + package.cpath = package.cpath..";"..my_name:gsub("[^/\\]+$", "../?.so"); +end + -- ugly workaround for getting datamanager to work outside of prosody :( prosody = { }; prosody.platform = "unknown"; |