[texworks] A request about lpeg

Christophe Devalland christophe.devalland at gmail.com
Mon Dec 29 14:57:36 CET 2014


2014-12-29 12:32 GMT+01:00 Stefan Löffler <st.loeffler at gmail.com>:

>  Interesting. Can you tell me which makefile and compiler/linker options
> you use? I cross-compile from Linux, so that may account for some size
> increase, but hopefully this can be improved.
>

Yes. I used a windows XP in virtualbox.

I installed mingw 32 bits with msys, gcc...

To compile lua 5.2 :

I copy sources of lua 5.2 in c:\mingw\lua 5.2

I open a dos command window with cmd.exe and I go to c:\mingw\lua 5.2

I write :

SET PATH=%PATH%;c:\mingw\msys\1.0\bin
make clean
make mingw


And I get exe and dll files in lua-5.2.0\src (lua52.dll is only 184KB)

To compile lpeg :

I copy source in lua-5.2.0\lpeg-0.12.1 and, in my dos command, I go to this
directory with :

cd lpeg-0.12.1

I compile without make :

gcc -O2 -shared -s -I c:\mingw\lua-5.2.0\src -L c:\mingw\lua-5.2.0\src -o
lpeg.dll lptree.c lpvm.c lpcap.c lpcode.c lpprint.c -llua52


And I get lpeg.dll in this directory.

Also, if you send me the dll, I can put it up on Google Drive. Still, for
> the future, it would be good to know if/how I can produce smaller libraries
> myself.
>

Here it is with lua52.dll. Probably compiling the whole texworks on mingw
windows would produce a smaller exe...
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://tug.org/pipermail/texworks/attachments/20141229/4ba025f4/attachment-0001.html>
-------------- next part --------------
FILE DELETED

Microsoft Forefront Protection for Exchange Server removed a file since it was found to match a filter.
File name: "lpeg.dll"
Filter name: "FILE FILTER= Blocked filetypes - headers: *"
-------------- next part --------------
FILE DELETED

Microsoft Forefront Protection for Exchange Server removed a file since it was found to match a filter.
File name: "lua52.dll"
Filter name: "FILE FILTER= Blocked filetypes - headers: *"


More information about the texworks mailing list