aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDiego Nehab <diego@tecgraf.puc-rio.br>2006-04-20 04:16:23 +0000
committerDiego Nehab <diego@tecgraf.puc-rio.br>2006-04-20 04:16:23 +0000
commit75f51d5bc7367af6a52700db989499162e8525e8 (patch)
treec8b0c1b7c60130b6732ab3d5cabfb89d8566c7f9
parent316e205cd4dea804b68ed6ca14cf8b41acf6712f (diff)
downloadluasocket-75f51d5bc7367af6a52700db989499162e8525e8.tar.gz
luasocket-75f51d5bc7367af6a52700db989499162e8525e8.tar.bz2
luasocket-75f51d5bc7367af6a52700db989499162e8525e8.zip
Almost ready to release 2.0.1
-rw-r--r--config20
-rw-r--r--doc/index.html30
-rw-r--r--doc/installation.html32
-rw-r--r--etc/README6
-rw-r--r--src/makefile7
5 files changed, 59 insertions, 36 deletions
diff --git a/config b/config
index 6b779aa..b849b70 100644
--- a/config
+++ b/config
@@ -15,8 +15,8 @@ UNIX_SO=unix.$(EXT)
15#------ 15#------
16# Lua includes and libraries 16# Lua includes and libraries
17# 17#
18LUAINC=-Ilua-5.0.2/include 18LUAINC=-I/usr/local/include/lua50
19LUALIB=-Llua-5.0.2/lib 19#LUAINC=-I/usr/local/include/lua5.1
20 20
21#------ 21#------
22# Compat-5.1 directory 22# Compat-5.1 directory
@@ -27,8 +27,10 @@ COMPAT=compat-5.1r5
27# Top of your Lua installation 27# Top of your Lua installation
28# Relative paths will be inside the src tree 28# Relative paths will be inside the src tree
29# 29#
30INSTALL_TOP_SHARE=share 30INSTALL_TOP_SHARE=/usr/local/share/lua/5.0
31INSTALL_TOP_LIB=lib 31INSTALL_TOP_LIB=/usr/local/lib/lua/5.0
32#INSTALL_TOP_SHARE=/usr/local/share/lua/5.1
33#INSTALL_TOP_LIB=/usr/local/lib/lua/5.1
32 34
33INSTALL_DATA=cp 35INSTALL_DATA=cp
34INSTALL_EXEC=cp 36INSTALL_EXEC=cp
@@ -46,11 +48,11 @@ INSTALL_EXEC=cp
46#------ 48#------
47# Compiler and linker settings 49# Compiler and linker settings
48# for Linux 50# for Linux
49CC=gcc 51#CC=gcc
50DEF=-DLUASOCKET_DEBUG 52#DEF=-DLUASOCKET_DEBUG
51CFLAGS= $(LUAINC) -I$(COMPAT) $(DEF) -pedantic -Wall -O2 -fpic 53#CFLAGS= $(LUAINC) -I$(COMPAT) $(DEF) -pedantic -Wall -O2 -fpic
52LDFLAGS=-O -shared -fpic 54#LDFLAGS=-O -shared -fpic
53LD=gcc 55#LD=gcc
54 56
55#------ 57#------
56# End of makefile configuration 58# End of makefile configuration
diff --git a/doc/index.html b/doc/index.html
index 3c0bbce..387b874 100644
--- a/doc/index.html
+++ b/doc/index.html
@@ -88,8 +88,9 @@ Author: <A href="http://www.cs.princeton.edu/~diego">Diego Nehab</a>
88 88
89<p> 89<p>
90LuaSocket version 2.0.1 is now available for download! It is 90LuaSocket version 2.0.1 is now available for download! It is
91compatible with Lua&nbsp;5.0 and has been tested on 91compatible with Lua&nbsp;5.0 and Lua&nbsp;5.1, and has
92Windows&nbsp;XP, Linux, and Mac OS X. 92been tested on Windows&nbsp;XP, Linux, and Mac OS X. Chances
93are it works well on most UNIX systems.
93</p> 94</p>
94 95
95<p> 96<p>
@@ -103,13 +104,13 @@ contains several examples, this user's manual and basic test procedures.
103<p> 104<p>
104Danilo Tuler is maintaining Win32 binaries for LuaSocket, which are also 105Danilo Tuler is maintaining Win32 binaries for LuaSocket, which are also
105available from LuaForge. These are compatible with the 106available from LuaForge. These are compatible with the
106<a href=http://luaforge.net/projects/luabinaries>LuaBinaries</a> 107<a href=http://luaforge.net/projects/luabinaries>LuaBinaries</a>,
107available from LuaForge. 108also available from LuaForge.
108</p> 109</p>
109 110
110<p> 111<p>
111For those that want to give LuaSocket a quick try, download the 112If you are using Lua 5.0, and want to give LuaSocket a quick
112stand-alone archive and unpack everything into 113try, download the stand-alone archive and unpack everything into
113a directory, say <tt>c:\luasocket</tt>. Then set <tt>LUA_INIT</tt> to load 114a directory, say <tt>c:\luasocket</tt>. Then set <tt>LUA_INIT</tt> to load
114the <tt>compat-5.1.lua</tt> and set <tt>LUA_PATH</tt> and 115the <tt>compat-5.1.lua</tt> and set <tt>LUA_PATH</tt> and
115<tt>LUA_CPATH</tt> to look for files in the current directory: 116<tt>LUA_CPATH</tt> to look for files in the current directory:
@@ -135,6 +136,23 @@ Lua 5.0.2 Copyright (C) 1994-2004 Tecgraf, PUC-Rio
135--&gt; the source to this web page gets dumped to terminal 136--&gt; the source to this web page gets dumped to terminal
136</pre> 137</pre>
137 138
139<p>
140If you are using Lua 5.1, you shouldn't use
141<tt>compat-5.1.lua</tt>. Just unpack the standalone
142directory, set <tt>LUA_CPATH</tt> and <tt>LUA_PATH</tt>, and
143you should be ready to run:
144<p>
145
146<pre class=example>
147c:\luasocket\&gt; set LUA_CPATH=?.dll
148c:\luasocket\&gt; set LUA_PATH=?.lua
149c:\luasocket\&gt; lua5.1
150Lua 5.1 Copyright (C) 1994-2006 Lua.org, PUC-Rio
151&gt; http = require"socket.http"
152&gt; print(http.request"http://www.cs.princeton.edu/~diego/professional/luasocket/"
153--&gt; the source to this web page gets dumped to terminal
154</pre>
155
138<p> When you are done playing, take a look at the 156<p> When you are done playing, take a look at the
139<a href=installation.html>installation</a> section of the manual to find out 157<a href=installation.html>installation</a> section of the manual to find out
140how to properly install the library. </p> 158how to properly install the library. </p>
diff --git a/doc/installation.html b/doc/installation.html
index 725db42..dadfe72 100644
--- a/doc/installation.html
+++ b/doc/installation.html
@@ -39,27 +39,24 @@ Installation">
39 39
40<h2>Installation</h2> 40<h2>Installation</h2>
41 41
42<p> LuaSocket 2.0.1 uses the new package proposal for Lua 5.1. 42<p> LuaSocket 2.0.1 uses the new package system for Lua 5.1.
43All Lua library developers are encouraged to update their libraries so that 43All Lua library developers are encouraged to update their libraries so that
44all libraries can coexist peacefully and users can benefit from the 44all libraries can coexist peacefully and users can benefit from the
45standardization and flexibility of the standard. 45standardization and flexibility of the standard.
46</p> 46</p>
47 47
48<p> 48<p>
49The proposal was considered important enough by some of us to justify 49Those stuck with Lua 5.0 will need the
50early adoption, even before release of Lua 5.1.
51Thus, a compatibility module
52<a href=http://www.keplerproject.org/compat/>compat-5.1</a> 50<a href=http://www.keplerproject.org/compat/>compat-5.1</a>
53has been released in conjunction with Roberto Ierusalimschy and <a 51module. It is maintained by
54href=http://www.keplerproject.org/>The Kepler Project</a> team. 52<a href=http://www.keplerproject.org/>The Kepler
55It implements the Lua 5.1 package proposal on top of Lua 5.0. </p> 53Project</a>'s team, and implements the Lua 5.1 package proposal
56 54on top of Lua 5.0. </p>
57<p> As far as LuaSocket is concerned, this means that whoever is 55
58deploying a non-standard distribution of LuaSocket will probably 56<p> Here we will only describe the standard distribution.
59have no problems customizing it. Here we will only describe the standard distribution. If the standard doesn't meet your 57If the standard doesn't meet your needs, we refer you to the
60needs, we refer you to the Lua discussion list, where any question about 58Lua discussion list, where any question about the package
61the package scheme will likely already have been answered. 59scheme will likely already have been answered. </p>
62</p>
63 60
64<h3>Directory structure</h3> 61<h3>Directory structure</h3>
65 62
@@ -88,7 +85,7 @@ distribution directory structure:</p>
88</pre> 85</pre>
89 86
90<p> Naturally, on Unix systems, <tt>core.dll</tt> 87<p> Naturally, on Unix systems, <tt>core.dll</tt>
91would be replaced by <tt>core.so</tt>. 88would be replaced by <tt>core.so</tt>.
92</p> 89</p>
93 90
94<p> In order for the interpreter to find all LuaSocket components, three 91<p> In order for the interpreter to find all LuaSocket components, three
@@ -100,6 +97,11 @@ LUA_INIT=@&lt;LDIR&gt;/compat-5.1.lua
100</pre> 97</pre>
101 98
102<p> 99<p>
100This is only need for Lua&nbsp;5.0! Lua&nbsp;5.1 comes with
101the package system bult in, of course.
102</p>
103
104<p>
103The other two environment variables instruct the compatibility module to 105The other two environment variables instruct the compatibility module to
104look for dynamic libraries and extension modules in the appropriate 106look for dynamic libraries and extension modules in the appropriate
105directories and with the appropriate filename extensions. 107directories and with the appropriate filename extensions.
diff --git a/etc/README b/etc/README
index 5a919cd..cfd3e37 100644
--- a/etc/README
+++ b/etc/README
@@ -64,9 +64,9 @@ work. Just run
64 64
65 lua check-links.lua [-n] {<url>} > output 65 lua check-links.lua [-n] {<url>} > output
66 66
67and open the result to see a list of broken links. You can 67and open the result to see a list of broken links. Make sure
68also use the '-n' switch to run the same program in 68you check the '-n' switch. It runs in non-blocking mode,
69non-blocking mode to see how much faster things can get. 69using coroutines, and is MUCH faster!
70 70
71 forward.lua -- coroutine based forward server 71 forward.lua -- coroutine based forward server
72 72
diff --git a/src/makefile b/src/makefile
index 9a97dd3..a21a346 100644
--- a/src/makefile
+++ b/src/makefile
@@ -10,6 +10,7 @@ include ../config
10#------ 10#------
11# Modules belonging to socket-core 11# Modules belonging to socket-core
12# 12#
13
13SOCKET_OBJS:= \ 14SOCKET_OBJS:= \
14 $(COMPAT)/compat-5.1.o \ 15 $(COMPAT)/compat-5.1.o \
15 luasocket.o \ 16 luasocket.o \
@@ -48,13 +49,13 @@ UNIX_OBJS:=\
48all: $(SOCKET_SO) $(MIME_SO) 49all: $(SOCKET_SO) $(MIME_SO)
49 50
50$(SOCKET_SO): $(SOCKET_OBJS) 51$(SOCKET_SO): $(SOCKET_OBJS)
51 $(LD) $(LDFLAGS) -o $@ $^ 52 $(LD) $(LDFLAGS) -o $@ $(SOCKET_OBJS)
52 53
53$(MIME_SO): $(MIME_OBJS) 54$(MIME_SO): $(MIME_OBJS)
54 $(LD) $(LDFLAGS) -o $@ $^ 55 $(LD) $(LDFLAGS) -o $@ $(MIME_OBJS)
55 56
56$(UNIX_SO): $(UNIX_OBJS) 57$(UNIX_SO): $(UNIX_OBJS)
57 $(LD) $(LDFLAGS) -o $@ $^ 58 $(LD) $(LDFLAGS) -o $@ $(UNIX_OBJS)
58 59
59#------ 60#------
60# List of dependencies 61# List of dependencies