projects
/
prosody.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge 0.9->trunk
[prosody.git]
/
tools
/
xep227toprosody.lua
diff --git
a/tools/xep227toprosody.lua
b/tools/xep227toprosody.lua
index b5156f45f8193085b4ff5334ea747c1d18e4e510..e95a9d5953a5eed91a7de30d7fd4eea0d489dc97 100755
(executable)
--- a/
tools/xep227toprosody.lua
+++ b/
tools/xep227toprosody.lua
@@
-3,7
+3,7
@@
-- Copyright (C) 2008-2009 Matthew Wild
-- Copyright (C) 2008-2009 Waqas Hussain
-- Copyright (C) 2010 Stefan Gehn
-- Copyright (C) 2008-2009 Matthew Wild
-- Copyright (C) 2008-2009 Waqas Hussain
-- Copyright (C) 2010 Stefan Gehn
---
+--
-- This project is MIT/X11 licensed. Please see the
-- COPYING file in the source package for more information.
--
-- This project is MIT/X11 licensed. Please see the
-- COPYING file in the source package for more information.
--
@@
-25,6
+25,12
@@
package.path = package.path..";../?.lua";
package.cpath = package.cpath..";../?.so"; -- needed for util.pposix used in datamanager
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";
-- ugly workaround for getting datamanager to work outside of prosody :(
prosody = { };
prosody.platform = "unknown";