[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: RE: /usr/bin/env and the Lua bytecode format
- From: Philippe Lhoste <PhiLho@...>
- Date: Mon, 6 Aug 2001 12:26:21 +0200 (MEST)
Back after a long week-end, I will try and answer some of the 66 new
messages found in this list... Only one message, to avoid clutering the list, and
mostly because this Web interface is clumsy...
Luiz Henrique de Figueiredo wrote:
> >What is the file extension people normally use for Lua bytecode files?
> How about .lua? :-) After all, it's transparent whether a file contains
> source or precompiled code... (Of course, I understand the need
> for different
That's a bad idea, at least from the user point of view. In the old CGILua,
there are some .lua files, but most of them are binary, which is quite
frustating when you open them with an editor to see some Lua code...
I have seen .luc, .lpc, why not .luac? Except in MS-Dos, I don't see why we
should limit ourselves to 3 letters extensions. Unless there is an issue I am
not aware, I am not a Unix guru :-) (or MacOS, or BeOS, etc.)
Another issue, at least with the current state of Lua: if you want to have
"standard" scripts (running with the official Lua interpreter), and special
ones (using an interpreter with specific libraries, like NTLua), you probably
need distincts extensions (in Windows), unless we make a small router reading
the first line of the script, and calling the right interpreter... Here we
are again with this issue!
Of course, would Lua officially support dynamic loading of libraries, this
would be come less difficult.
I can't reach the link you gave for Lash, actually, when trying to reach the
root domain, I have a generic page stating there isn't an index file yet...
It seems to be an interesting project.
John Belmonte wrote:
> Julian Squires wrote:
> > Isn't binfmt a Linux-only thing? I might be wrong here, but
> > I feel the #! system is really the more portable way of
> > doing it (although the binfmt approach would be good for
> > interim measures on a Linux system where someone didn't
> > want to modify the lua interpreter).
> Don't all OS's have to deal with the issue of identifying binary files so
> the correct viewer or interpreter can be called?
Of course, MS Windows does it the wrong way, since it rely only on file
extensions to identify a file. Well, I suppose it checks whether a .exe file has
a correct header, but try to rename a .exe to a .run and execute it without
tweaking the registry...
Oops, it works. So much for me, Windows is smarter than I though... But you
loose the icon (in Explorer).
Of course, running pre-compiled Lua scripts of various extensions is another
> On a more general note, I acknowledge that there are two Lua camps... both
> valid. One treats standalone Lua (which is just a snapshot of Lua...
> remember the standard libraries can be completely changed while still
> calling the result "Lua") as if it were Perl or Python. The other treats
> Lua as something to link to their app and extend at will. To
> someone in the
> second camp like me, doing things like implementing Lua on the Java VM or
> making a Debian package that actually installs an executable is going to
> look strange. (For example the main reason I use Lua as opposed to
> something on the Java VM is because those don't fit on my target system.)
> Anyway my point is that we should be aware that these different
> camps exist
> when we post to the list.
Currently, I am on the first camp, but I am planning to be on the second too
:-) This is a valid categorization (because it shows different needs), but
of course people are not requiered to stand only in one.
Antonio Scuri wrote:
> >You can find information and a (Early Alpha) executable here:
> Very nice.
> I have 2 projects that may have some reusable code for lash: NtLua and
> LuaCmd. Check at:
> Have you tried these?
I forgot about these... I will take a look at the source. I am not overly
interested by NT administration in general, but I was thinking about creating a
Windows library for file, windows and registry processing, among other
things. Actually, I would like to copy most of the functionnalities of AutoIt
(http://www.hiddensoft.com/AutoIt/index.html) to use with a real programming
Using your code can save me some time... You seems to use the 3.2 API, but
adapting it to 4.0 should be doable.
BTW, you should end your URLs with a slash if they refer to the default
index file. This is a general recommendation to avoid two requests per URL: one
that fails with the last directory checked as file, another searching for the
default index file.
Luiz Henrique de Figueiredo wrote:
> I reproduce below a posting from comp.lang.misc.
> Perhaps some of you in lua-l are interested in contributing Lua
> I'm not familiar with the contents of the "Perl Cookbook" and so
> cannot say
> offhand whether the problems considered in it may have good Lua solutions,
> but perhaps it's worth trying?
Funny, I was thinking about creating a similar page, but for implementing a
maze algorithm in several programming languages. I will post here a link when
(if?) I have something to show. Unlike the other similar pages, I am
planning to accept several different implementations for a given language.
BTW, I have found a mirror for the 99 beers page:
http://internet.ls-la.net/mirrors/99bottles/ If somebody wants to update the PLEAC mainteners...
The PLEAC seems quite ambitious, judging from the TOC...
Philippe Lhoste (Paris -- France)
Professional programmer and amateur artist
Sent through GMX FreeMail - http://www.gmx.net