package.path and package.cpath in the code obsolete.
Signed-off-by: Gordon Hecker <gh@emlix.com>
Conflicts:
global/e2-install-e2.lua.in
along with this program. If not, see <http://www.gnu.org/licenses/>.
]]
-package.path="@LIBDIR@/?.lc;@LIBDIR@/?.lua"
-package.cpath="@LIBDIR@/?.so"
-
require("e2global")
e2lib.init()
along with this program. If not, see <http://www.gnu.org/licenses/>.
]]
-e2_install_e2 = "@LIBEXECDIR@/e2-lua-@LUA_VERSION@ @TOOLDIR@/e2-install-e2"
-
-package.path="@LIBDIR@/?.lc;@LIBDIR@/?.lua"
-package.cpath="@LIBDIR@/?.so"
-
require("e2global")
+
e2lib.init()
local e = new_error("fetching project failed")
local doc = [[
end
-- call e2-install-e2
+e2_install_e2 = string.format("'%s' '%s/e2-install-e2'",
+ getinstallpath("LUA"), getinstallpath("TOOLDIR"))
rc, re = e2lib.callcmd_log(e2_install_e2)
if not rc then
e:append("installing local e2 failed")
along with this program. If not, see <http://www.gnu.org/licenses/>.
]]
-package.path = "@LIBDIR@/?.lc;@LIBDIR@/?.lua"
-package.cpath = "@LIBDIR@/?.so"
-
-local install_prefix = "@E2_PREFIX@"
-
require("e2global")
e2lib.init()
if e2util.stat(e2call.globaltool) then
e2call.tool = e2call.globaltool
- cmd = "@LIBEXECDIR@/e2-lua-@LUA_VERSION@ " .. e2call.tool .. " " .. e2call.arg_string
+ env = "LUA_PATH='@LIBDIR@/?.lc;@LIBDIR@/?.lua'" ..
+ "LUA_CPATH='@LIBDIR@/?.so'"
+ lua = "@LIBEXECDIR@/e2-lua-@LUA_VERSION@"
+ cmd = string.format("%s %s %s %s", env, lua, e2call.tool, e2call.arg_string)
elseif not root then
e2lib.abort(e2call.toolname ..
" is not a global tool and we're not in a project environment")
install [ "LIBDIR" ] = "@LIBDIR@"
install [ "LIBEXECDIR" ] = "@LIBEXECDIR@"
install [ "TOOLDIR" ] = "@TOOLDIR@"
-
+install [ "LUA" ] = "@LIBEXECDIR@/e2-lua-@LUA_VERSION@"
-- getinstallpath(var)
--