put all the configuration stuff into a single file in SYSCONFDIR and
some tiny tweaks with help from and ok pedro@
This commit is contained in:
parent
178b98f095
commit
3b418d86b0
@ -1,8 +1,8 @@
|
||||
# $OpenBSD: Makefile,v 1.6 2005/12/01 20:17:05 pedro Exp $
|
||||
# $OpenBSD: Makefile,v 1.7 2005/12/02 01:12:08 jolan Exp $
|
||||
|
||||
COMMENT= "lua web server with cgi support"
|
||||
DISTNAME= xavante-1.1
|
||||
PKGNAME= ${DISTNAME}p3
|
||||
PKGNAME= ${DISTNAME}p4
|
||||
CATEGORIES= www
|
||||
MASTER_SITES= http://luaforge.net/frs/download.php/958/
|
||||
|
||||
@ -25,31 +25,34 @@ RUN_DEPENDS= ${BUILD_DEPENDS}
|
||||
post-extract:
|
||||
@sed -e "s:@xavantepath@:${PREFIX}/lua/xavante/?.lua:g" \
|
||||
-e "s:@sajaxpath@:${PREFIX}/lua/sajax/?.lua:g" \
|
||||
-e "s:@sysconfdir@:${SYSCONFDIR}/?.lua:g" \
|
||||
${FILESDIR}/init.lua > ${WRKSRC}/init.lua
|
||||
|
||||
post-patch:
|
||||
@perl -pi -e 's:\@xavanteweb@:${PREFIX}/share/examples/xavante/:g;' \
|
||||
${WRKSRC}/src/t_xavante_start.lua
|
||||
@perl -pi -e 's:\@xavanteweb@:${PREFIX}/share/examples/xavante/htdocs/:g;' \
|
||||
${WRKSRC}/src/xavante/config.lua
|
||||
@perl -pi -e 's:\@localbase@:${LOCALBASE}:g;' \
|
||||
${WRKSRC}/src/t_xavante_start.lua
|
||||
|
||||
do-install:
|
||||
${INSTALL_DATA_DIR} ${PREFIX}/lua/xavante
|
||||
${INSTALL_DATA_DIR} ${PREFIX}/lua/sajax
|
||||
${INSTALL_DATA} ${WRKSRC}/src/sajax/sajax.lua ${PREFIX}/lua/sajax
|
||||
${INSTALL_DATA_DIR} ${PREFIX}/lua/xavante
|
||||
${INSTALL_DATA_DIR} ${PREFIX}/lua/xavante/xavante
|
||||
${INSTALL_DATA} ${WRKSRC}/init.lua ${PREFIX}/lua/xavante
|
||||
${INSTALL_DATA} ${WRKSRC}/src/xavante/*.lua \
|
||||
${INSTALL_DATA} ${WRKSRC}/src/xavante/{cgiluahandler,davFileProps,davFileRepository,davhandler,filehandler,httpd,mime,redirecthandler,server}.lua \
|
||||
${PREFIX}/lua/xavante/xavante
|
||||
${INSTALL_DATA} ${WRKSRC}/src/coxpcall/coxpcall.lua \
|
||||
${PREFIX}/lua/xavante/xavante/coxpcall.lua
|
||||
${INSTALL_PROGRAM} ${WRKSRC}/src/t_xavante_start.lua \
|
||||
${PREFIX}/bin/xavante
|
||||
${INSTALL_DATA_DIR} ${PREFIX}/share/examples/xavante
|
||||
${INSTALL_DATA} ${WRKSRC}/src/sajax/sajax.lua ${PREFIX}/lua/sajax
|
||||
${INSTALL_DATA} ${WRKSRC}/web/*.lp ${PREFIX}/share/examples/xavante
|
||||
${INSTALL_DATA_DIR} ${PREFIX}/share/examples/xavante/img
|
||||
${INSTALL_DATA_DIR} ${PREFIX}/share/examples/xavante/htdocs/img
|
||||
${INSTALL_DATA} ${WRKSRC}/src/xavante/config.lua \
|
||||
${PREFIX}/share/examples/xavante
|
||||
${INSTALL_DATA} ${WRKSRC}/web/*.lp \
|
||||
${PREFIX}/share/examples/xavante/htdocs
|
||||
${INSTALL_DATA} ${WRKSRC}/web/img/*.{gif,jpg} \
|
||||
${PREFIX}/share/examples/xavante/img
|
||||
${PREFIX}/share/examples/xavante/htdocs/img
|
||||
${INSTALL_DATA_DIR} ${PREFIX}/share/doc/xavante
|
||||
${INSTALL_DATA} ${WRKSRC}/doc/us/* ${PREFIX}/share/doc/xavante
|
||||
|
||||
|
@ -1,4 +1,5 @@
|
||||
-- $OpenBSD: init.lua,v 1.2 2005/12/01 20:17:05 pedro Exp $
|
||||
-- $OpenBSD: init.lua,v 1.3 2005/12/02 01:12:08 jolan Exp $
|
||||
-- xavante's initialization steps
|
||||
lua_addpath("@xavantepath@")
|
||||
lua_addpath("@sajaxpath@")
|
||||
lua_addpath("@sysconfdir@")
|
||||
|
@ -1,13 +1,13 @@
|
||||
$OpenBSD: patch-src_t_xavante_start_lua,v 1.2 2005/09/06 16:51:44 pedro Exp $
|
||||
--- src/t_xavante_start.lua.orig Mon Jul 4 15:37:44 2005
|
||||
+++ src/t_xavante_start.lua Thu Aug 18 13:57:10 2005
|
||||
$OpenBSD: patch-src_t_xavante_start_lua,v 1.3 2005/12/02 01:12:08 jolan Exp $
|
||||
--- src/t_xavante_start.lua.orig Mon Jul 4 13:37:44 2005
|
||||
+++ src/t_xavante_start.lua Thu Dec 1 18:27:06 2005
|
||||
@@ -1,4 +1,4 @@
|
||||
-#!/usr/local/bin/lua50
|
||||
+#!@localbase@/bin/lua
|
||||
-------------------------------------------------------------------------------
|
||||
-- Starts the Xavante Web server.
|
||||
--
|
||||
@@ -8,18 +8,10 @@
|
||||
@@ -8,18 +8,8 @@
|
||||
-- Copyright (c) 2004-2005 Kepler Project
|
||||
-------------------------------------------------------------------------------
|
||||
|
||||
@ -21,9 +21,8 @@ $OpenBSD: patch-src_t_xavante_start_lua,v 1.2 2005/09/06 16:51:44 pedro Exp $
|
||||
-end
|
||||
|
||||
require "xavante.server"
|
||||
|
||||
-
|
||||
-xavante.setwebdir([[XAVANTE_WEB]])
|
||||
+xavante.setwebdir([[@xavanteweb@]])
|
||||
|
||||
-------------------------------------------------------------------------------
|
||||
-- Loads the configuration file and starts Xavante
|
||||
|
19
www/xavante/patches/patch-src_xavante_config_lua
Normal file
19
www/xavante/patches/patch-src_xavante_config_lua
Normal file
@ -0,0 +1,19 @@
|
||||
$OpenBSD: patch-src_xavante_config_lua,v 1.1 2005/12/02 01:12:08 jolan Exp $
|
||||
--- src/xavante/config.lua.orig Tue Jun 7 10:43:02 2005
|
||||
+++ src/xavante/config.lua Thu Dec 1 18:28:56 2005
|
||||
@@ -19,6 +19,8 @@ require "xavante.filehandler"
|
||||
require "xavante.cgiluahandler"
|
||||
require "xavante.redirecthandler"
|
||||
|
||||
+xavante.setwebdir([[@xavanteweb@]])
|
||||
+
|
||||
local simplerules = {
|
||||
-- URL remapping example
|
||||
{match = "/", with = xavante.redirecthandler, params = {"index.lp"}},
|
||||
@@ -36,4 +38,4 @@ xavante.HTTP{
|
||||
defaultHost = {
|
||||
rules = simplerules
|
||||
},
|
||||
-}
|
||||
\ No newline at end of file
|
||||
+}
|
17
www/xavante/patches/patch-web_index_lp
Normal file
17
www/xavante/patches/patch-web_index_lp
Normal file
@ -0,0 +1,17 @@
|
||||
$OpenBSD: patch-web_index_lp,v 1.1 2005/12/02 01:12:08 jolan Exp $
|
||||
--- web/index.lp.orig Wed Mar 16 15:35:24 2005
|
||||
+++ web/index.lp Thu Dec 1 18:43:21 2005
|
||||
@@ -12,10 +12,10 @@
|
||||
If you are reading this page, <strong><%= cgilua.servervariable("SERVER_SOFTWARE") %></strong>
|
||||
has been successfully installed on your system.<br />
|
||||
<br />
|
||||
-From here you can browse the <a href="/doc/index.html">Xavante documentation</a>
|
||||
+From here you can browse the <a href="http://www.keplerproject.org/xavante/">Xavante documentation</a>
|
||||
or run some <a href="test.lp">Xavante tests</a>. <br />
|
||||
<br />
|
||||
Copyright 2004-2005 - <a href="http://www.keplerproject.org">Kepler Project</a><br />
|
||||
</center>
|
||||
</body>
|
||||
-</html>
|
||||
\ No newline at end of file
|
||||
+</html>
|
@ -1,4 +1,4 @@
|
||||
@comment $OpenBSD: PLIST,v 1.6 2005/12/01 20:17:05 pedro Exp $
|
||||
@comment $OpenBSD: PLIST,v 1.7 2005/12/02 01:12:08 jolan Exp $
|
||||
@newgroup _xavante:552
|
||||
@newuser _xavante:552:552:daemon:Xavante WWW Server:/var/empty:/sbin/nologin
|
||||
@unexec lua ${SYSCONFDIR}/lua/luapkg.lua del xavante
|
||||
@ -9,7 +9,6 @@ lua/xavante/
|
||||
lua/xavante/init.lua
|
||||
lua/xavante/xavante/
|
||||
lua/xavante/xavante/cgiluahandler.lua
|
||||
lua/xavante/xavante/config.lua
|
||||
lua/xavante/xavante/coxpcall.lua
|
||||
lua/xavante/xavante/davFileProps.lua
|
||||
lua/xavante/xavante/davFileRepository.lua
|
||||
@ -27,10 +26,14 @@ share/doc/xavante/manual.html
|
||||
share/doc/xavante/sajax.html
|
||||
share/doc/xavante/xavante.gif
|
||||
share/examples/xavante/
|
||||
share/examples/xavante/calculator.lp
|
||||
share/examples/xavante/img/
|
||||
share/examples/xavante/img/test.jpg
|
||||
share/examples/xavante/img/xavante.gif
|
||||
share/examples/xavante/index.lp
|
||||
share/examples/xavante/loop.lp
|
||||
share/examples/xavante/test.lp
|
||||
@sample ${SYSCONFDIR}/xavante/
|
||||
share/examples/xavante/config.lua
|
||||
@sample ${SYSCONFDIR}/xavante/config.lua
|
||||
share/examples/xavante/htdocs/
|
||||
share/examples/xavante/htdocs/calculator.lp
|
||||
share/examples/xavante/htdocs/img/
|
||||
share/examples/xavante/htdocs/img/test.jpg
|
||||
share/examples/xavante/htdocs/img/xavante.gif
|
||||
share/examples/xavante/htdocs/index.lp
|
||||
share/examples/xavante/htdocs/loop.lp
|
||||
share/examples/xavante/htdocs/test.lp
|
||||
|
Loading…
Reference in New Issue
Block a user