diff options
author | Marius <mariausol@gmail.com> | 2013-02-13 19:20:32 +0200 |
---|---|---|
committer | Marius <mariausol@gmail.com> | 2013-02-13 19:20:32 +0200 |
commit | 13706211c6f53d83a620a845c9c0e5bb736345a3 (patch) | |
tree | 45c2d15d5a70813202748cea43832e2f8caba00f /tex/context/base/util-mrg.lua | |
parent | 298e57104a0c60ee6fbf14ff67b9515512a8b7cd (diff) | |
download | context-13706211c6f53d83a620a845c9c0e5bb736345a3.tar.gz |
beta 2013.02.13 18:06
Diffstat (limited to 'tex/context/base/util-mrg.lua')
-rw-r--r-- | tex/context/base/util-mrg.lua | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/tex/context/base/util-mrg.lua b/tex/context/base/util-mrg.lua index 276531d79..f8742151c 100644 --- a/tex/context/base/util-mrg.lua +++ b/tex/context/base/util-mrg.lua @@ -51,6 +51,8 @@ local m_report = [[ -- stripped bytes : %s ]] +local m_preloaded = [[package.loaded[%q] = package.loaded[%q] or true]] + local function self_fake() return m_faked end @@ -175,11 +177,13 @@ local function self_libs(libs,list) local fullname = foundpath .. "/" .. lib if lfs.isfile(fullname) then utilities.report("merge: using library %s",fullname) + local preloaded = file.nameonly(lib) local data = io.loaddata(fullname,true) original = original + #data local data, delta = self_compact(data) right[#right+1] = lib result[#result+1] = m_begin_closure + result[#result+1] = format(m_preloaded,preloaded,preloaded) result[#result+1] = data result[#result+1] = m_end_closure stripped = stripped + delta |