patch for mod_lua (correct lua_open_hook )

2011-03-27 Thread zhiguo zhao
Hi, nice people.

Please patch to head trunk.

Add ap_lua_run_lua_open to run lua_open hooks provider by other modules.


Index: mod_lua.c
===
--- mod_lua.c   (版本 1085879)
+++ mod_lua.c   (工作副本)
@@ -59,11 +59,11 @@
 ap_lua_load_apache2_lmodule(L);
 ap_lua_load_request_lmodule(L, p);
 ap_lua_load_config_lmodule(L);
+ap_lua_run_lua_open(L, p);
 }

 static int lua_open_hook(lua_State *L, apr_pool_t *p)
 {
-lua_open_callback(L, p, NULL);
 return OK;
 }


mod_lua.diff
Description: Binary data


[PATCH] default_rel_runtimedir everywhere (Windows, NetWare)

2011-03-27 Thread Jeff Trawick
For autoconf-based builds, DEFAULT_REL_RUNTIMEDIR is defined by the
layout machinery, which creates ap_config_layout.h.

For non-autoconf-based builds, there is no equivalent to
ap_config_layout.h.  Windows and NetWare MPMs define
DEFAULT_REL_RUNTIMEDIR in mpm_layout.h, but that is local to the MPM.
So no definition is visible to modules and other source files.  As a
work-around, several common source files have created their own
defaults when DEFAULT_REL_RUNTIMEDIR is not defined.

The attached patch creates a new os_layout.h for non-autoconf-based
builds (just Windows and NetWare) which defines
DEFAULT_REL_RUNTIMEDIR.  The workarounds from the several common
source files are removed.  Third-party modules can also depend on
DEFAULT_REL_RUNTIMEDIR again.

Concerns (such as better name for the new file)?

No, I didn't test it :)  My Visual C++ Express setup for httpd is not
workable at present.

I will try to test the docgen stuff before I commit.


Re: mod_fcgid in httpd tarball?

2011-03-27 Thread Jim Jagielski

On Mar 23, 2011, at 7:49 AM, Jeff Trawick wrote:

 On Wed, Mar 23, 2011 at 7:43 AM, Mark Montague m...@catseye.org wrote:
  On March 23, 2011 7:37 , Graham Leggett minf...@sharp.fm  wrote:
 
 Do we want to introduce mod_fcgid now into httpd 2.3.x for the next beta?
 
 How do we reconcile mod_fcgid with mod_proxy_fcgid?
 
 Do they need to be reconciled?  Each currently has strengths the other
 lacks.
 
 That's how they are reconciled ;)
 
 * mod_proxy_fcgi ONLY routes to separately managed application processes.
 * mod_fcgid ONLY routes to application processes it manages.
 

Yeppers. mod_proxy_fcgi simply adds the FCGI protocol to mod_proxy
(and mod_proxy_balancer). mod_fcgid is an FastCGI application
manager.

Plan for next beta

2011-03-27 Thread Jim Jagielski
With APR 1.4.3 and APU 1.3.11 coming soonish, as well as the
number of changes in httpd-land itself, I think I will start
planning the next beta release (2.3.12-beta).

I also think the general consensus is to bundle mod_fcgid
with 2.4 as well, and might as well do this now. The question
is do we just bundle it with trunk or do we actually move/merge
the repo into trunk. My pref would be the latter...


Re: [PATCH] default_rel_runtimedir everywhere (Windows, NetWare)

2011-03-27 Thread NormW

On 28/03/2011 1:30 AM, Jeff Trawick wrote:

For autoconf-based builds, DEFAULT_REL_RUNTIMEDIR is defined by the
layout machinery, which creates ap_config_layout.h.

For non-autoconf-based builds, there is no equivalent to
ap_config_layout.h.  Windows and NetWare MPMs define
DEFAULT_REL_RUNTIMEDIR in mpm_layout.h, but that is local to the MPM.
So no definition is visible to modules and other source files.  As a
work-around, several common source files have created their own
defaults when DEFAULT_REL_RUNTIMEDIR is not defined.

The attached patch creates a new os_layout.h for non-autoconf-based
builds (just Windows and NetWare) which defines
DEFAULT_REL_RUNTIMEDIR.  The workarounds from the several common
source files are removed.  Third-party modules can also depend on
DEFAULT_REL_RUNTIMEDIR again.

Concerns (such as better name for the new file)?

No, I didn't test it :)  My Visual C++ Express setup for httpd is not
workable at present.

I will try to test the docgen stuff before I commit.

Seems like the paperclip failed.
Norm



Re: [PATCH] default_rel_runtimedir everywhere (Windows, NetWare)

2011-03-27 Thread Jeff Trawick
On Sun, Mar 27, 2011 at 3:26 PM, NormW no...@gknw.net wrote:
 On 28/03/2011 1:30 AM, Jeff Trawick wrote:

 For autoconf-based builds, DEFAULT_REL_RUNTIMEDIR is defined by the
 layout machinery, which creates ap_config_layout.h.

 For non-autoconf-based builds, there is no equivalent to
 ap_config_layout.h.  Windows and NetWare MPMs define
 DEFAULT_REL_RUNTIMEDIR in mpm_layout.h, but that is local to the MPM.
 So no definition is visible to modules and other source files.  As a
 work-around, several common source files have created their own
 defaults when DEFAULT_REL_RUNTIMEDIR is not defined.

 The attached patch creates a new os_layout.h for non-autoconf-based
 builds (just Windows and NetWare) which defines
 DEFAULT_REL_RUNTIMEDIR.  The workarounds from the several common
 source files are removed.  Third-party modules can also depend on
 DEFAULT_REL_RUNTIMEDIR again.

 Concerns (such as better name for the new file)?

 No, I didn't test it :)  My Visual C++ Express setup for httpd is not
 workable at present.

 I will try to test the docgen stuff before I commit.

 Seems like the paperclip failed.

(blush)

now attached
Index: os/win32/os_layout.h
===
--- os/win32/os_layout.h(revision 0)
+++ os/win32/os_layout.h(revision 0)
@@ -0,0 +1,35 @@
+/* Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the License); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/**
+ * @file win32/os_layout.h
+ * @brief This provides layout definitions for non-autoconf-based Windows
+ * builds.
+ *
+ * @defgroup APACHE_OS_LAYOUT_WIN32 win32
+ * @ingroup  APACHE_OS_LAYOUT
+ * @{
+ */
+
+#ifndef AP_OS_LAYOUT_H
+#define AP_OS_LAYOUT_H
+
+/* Check for definition of DEFAULT_REL_RUNTIMEDIR */
+#ifndef DEFAULT_REL_RUNTIMEDIR
+#define DEFAULT_REL_RUNTIMEDIR logs
+#endif
+
+#endif /* AP_OS_LAYOUT_H */
Index: os/netware/os_layout.h
===
--- os/netware/os_layout.h  (revision 0)
+++ os/netware/os_layout.h  (revision 0)
@@ -0,0 +1,35 @@
+/* Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the License); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/**
+ * @file netware/os_layout.h
+ * @brief This provides layout definitions for non-autoconf-based NetWare
+ * builds.
+ *
+ * @defgroup APACHE_OS_LAYOUT_NETWARE netware
+ * @ingroup  APACHE_OS_LAYOUT
+ * @{
+ */
+
+#ifndef AP_OS_LAYOUT_H
+#define AP_OS_LAYOUT_H
+
+/* Check for definition of DEFAULT_REL_RUNTIMEDIR */
+#ifndef DEFAULT_REL_RUNTIMEDIR
+#define DEFAULT_REL_RUNTIMEDIR logs
+#endif
+
+#endif /* AP_OS_LAYOUT_H */
Index: server/util_mutex.c
===
--- server/util_mutex.c (revision 1085954)
+++ server/util_mutex.c (working copy)
@@ -154,11 +154,7 @@
 /* initialize default mutex configuration */
 def = apr_pcalloc(p, sizeof *def);
 def-mech = APR_LOCK_DEFAULT;
-#ifdef DEFAULT_REL_RUNTIMEDIR
 def-dir = DEFAULT_REL_RUNTIMEDIR;
-#else
-def-dir = logs;
-#endif
 apr_hash_set(mxcfg_by_type, default, APR_HASH_KEY_STRING, def);
 }
 
Index: server/mpm/winnt/mpm_default.h
===
--- server/mpm/winnt/mpm_default.h  (revision 1085954)
+++ server/mpm/winnt/mpm_default.h  (working copy)
@@ -55,11 +55,6 @@
  */
 #define HARD_SERVER_LIMIT 1
 
-/* Check for definition of DEFAULT_REL_RUNTIMEDIR */
-#ifndef DEFAULT_REL_RUNTIMEDIR
-#define DEFAULT_REL_RUNTIMEDIR logs
-#endif
-
 /* Where the main/parent process's pid is logged */
 

Re: [PATCH] default_rel_runtimedir everywhere (Windows, NetWare)

2011-03-27 Thread NormW

On 28/03/2011 6:08 AM, Jeff Trawick wrote:

On Sun, Mar 27, 2011 at 3:26 PM, NormWno...@gknw.net  wrote:

On 28/03/2011 1:30 AM, Jeff Trawick wrote:


For autoconf-based builds, DEFAULT_REL_RUNTIMEDIR is defined by the
layout machinery, which creates ap_config_layout.h.

For non-autoconf-based builds, there is no equivalent to
ap_config_layout.h.  Windows and NetWare MPMs define
DEFAULT_REL_RUNTIMEDIR in mpm_layout.h, but that is local to the MPM.
So no definition is visible to modules and other source files.  As a
work-around, several common source files have created their own
defaults when DEFAULT_REL_RUNTIMEDIR is not defined.

The attached patch creates a new os_layout.h for non-autoconf-based
builds (just Windows and NetWare) which defines
DEFAULT_REL_RUNTIMEDIR.  The workarounds from the several common
source files are removed.  Third-party modules can also depend on
DEFAULT_REL_RUNTIMEDIR again.

Concerns (such as better name for the new file)?

No, I didn't test it :)  My Visual C++ Express setup for httpd is not
workable at present.

I will try to test the docgen stuff before I commit.


Seems like the paperclip failed.


(blush)

now attached

Hi,
Patch applies without issue, compiles for NetWare without issue, loads 
on server without issue, socachedbm creates its files in .\logs as 
previous and server can deliver Apache manual with no problems; bottom 
line is 'change looks fine for NetWare'.

Norm



Re: Bug report for Apache httpd-2 [2011/03/27]

2011-03-27 Thread William A. Rowe Jr.
Note the absence of an httpd-1.3 report (at last).  I'll go ahead and request
a read only lock on the httpd-1.3 bug history now that all of the old incidents
against that version are closed.



Re: Plan for next beta

2011-03-27 Thread William A. Rowe Jr.
On 3/27/2011 10:52 AM, Jim Jagielski wrote:
 With APR 1.4.3 and APU 1.3.11 coming soonish, as well as the
 number of changes in httpd-land itself, I think I will start
 planning the next beta release (2.3.12-beta).
 
 I also think the general consensus is to bundle mod_fcgid
 with 2.4 as well, and might as well do this now. The question
 is do we just bundle it with trunk or do we actually move/merge
 the repo into trunk. My pref would be the latter...

move/merge doesn't address our 2.2 users.

I'm happy to make the appropriate svn cp's (not all files are needed),
and will attack this as soon as my commitments to apr project are done.
I know Jeff is equally familiar and could do this if he has free cycles,
but I'm not offering him up :)  That's his call.


Re: [PATCH] default_rel_runtimedir everywhere (Windows, NetWare)

2011-03-27 Thread William A. Rowe Jr.
On 3/27/2011 10:30 AM, Jeff Trawick wrote:
 
 Concerns (such as better name for the new file)?

Only one... please don't add #include logic, let Gunter and I wire up
the auto-copy to ap_config_layout.h and we will truly be consistent.

You can update the patch to assume that file always exists.  Let's keep
the main .c code as absolutely consistent as possible with fewer per-arch
variations.


Re: [PATCH] default_rel_runtimedir everywhere (Windows, NetWare)

2011-03-27 Thread Jeff Trawick
On Sun, Mar 27, 2011 at 6:09 PM, William A. Rowe Jr.
wr...@rowe-clan.net wrote:
 On 3/27/2011 10:30 AM, Jeff Trawick wrote:

 Concerns (such as better name for the new file)?

 Only one... please don't add #include logic, let Gunter and I wire up
 the auto-copy to ap_config_layout.h and we will truly be consistent.

 You can update the patch to assume that file always exists.  Let's keep
 the main .c code as absolutely consistent as possible with fewer per-arch
 variations.

ap_config.h now unconditionally includes ap_config_layout.h.

I renamed the two OS-specific, non-autoconf-build versions to
{win32,netware}_config_layout.h to make it obvious to lurkers that
they should not include this file as present in the os directory.


Re: svn commit: r1086073 - in /httpd/httpd/trunk: ./ include/ modules/cache/ os/netware/ os/win32/ server/ server/mpm/netware/ server/mpm/winnt/

2011-03-27 Thread Jeff Trawick
On Sun, Mar 27, 2011 at 7:51 PM,  traw...@apache.org wrote:
 Author: trawick
 Date: Sun Mar 27 23:51:18 2011
 New Revision: 1086073

 URL: http://svn.apache.org/viewvc?rev=1086073view=rev
 Log:
 enable DEFAULT_REL_RUNTIMEDIR on NetWare and Windows

 this commit is missing the Windows and NetWare build
 logic to copy the appropriate file to include/ap_config_layout.h

just so the info isn't trapped inside another thread:

Windows: a change is needed (perhaps to libhttpd.dsp) to copy
os/win32/win32_config_layout.h to include/ap_config_layout.h
NetWare: something similar


Re: svn commit: r1086073 - in /httpd/httpd/trunk: ./ include/ modules/cache/ os/netware/ os/win32/ server/ server/mpm/netware/ server/mpm/winnt/

2011-03-27 Thread Guenter Knauf

Am 28.03.2011 01:57, schrieb Jeff Trawick:

On Sun, Mar 27, 2011 at 7:51 PM,traw...@apache.org  wrote:

Author: trawick
Date: Sun Mar 27 23:51:18 2011
New Revision: 1086073

URL: http://svn.apache.org/viewvc?rev=1086073view=rev
Log:
enable DEFAULT_REL_RUNTIMEDIR on NetWare and Windows

this commit is missing the Windows and NetWare build
logic to copy the appropriate file to include/ap_config_layout.h


just so the info isn't trapped inside another thread:

Windows: a change is needed (perhaps to libhttpd.dsp) to copy
os/win32/win32_config_layout.h to include/ap_config_layout.h
NetWare: something similar
with other headers we do usually just append w|nw to the extensision, 
and have these files in same directory as where the target should live, 
f.e.:

include/ap_config_layout.h   (target)
include/ap_config_layout.hw  (windows)
include/ap_config_layout.hnw (netware)

then at least for NetWare where we use GNU make a simple generic rule:
%.h : %.hnw
copy $ $@

does the job (we use this already with APR/APU too) ...

I dont say that the copy with those files you commited is of any 
problem, just wanted to mention what existing logic we currently have 
already with other headers ...

awaiting Bill's comment on that ...

Gün.




Re: [PATCH] default_rel_runtimedir everywhere (Windows, NetWare)

2011-03-27 Thread NormW

On 28/03/2011 9:54 AM, Jeff Trawick wrote:

On Sun, Mar 27, 2011 at 6:09 PM, William A. Rowe Jr.
wr...@rowe-clan.net  wrote:

On 3/27/2011 10:30 AM, Jeff Trawick wrote:


Concerns (such as better name for the new file)?


Only one... please don't add #include logic, let Gunter and I wire up
the auto-copy to ap_config_layout.h and we will truly be consistent.

You can update the patch to assume that file always exists.  Let's keep
the main .c code as absolutely consistent as possible with fewer per-arch
variations.


ap_config.h now unconditionally includes ap_config_layout.h.

I renamed the two OS-specific, non-autoconf-build versions to
{win32,netware}_config_layout.h to make it obvious to lurkers that
they should not include this file as present in the os directory.


Hi,
AFAICT renaming os_layout.h - netware_config_layout.h requires a tweak 
in ap_config.h now, plus a tweak of svn eol properties for added pieces.


Norm



NetWare autobuild httpd-HEAD / apr-HEAD failed

2011-03-27 Thread fuankg
Complete buildlog: 
http://svwe20.itex.at/autobuilds/asf/httpd/201103280410-netware-httpd.txt.gz
=
Exporting httpd-trunk ...
Path: trunk
URL: http://svn.apache.org/repos/asf/httpd/httpd/trunk
Repository Root: http://svn.apache.org/repos/asf
Repository UUID: 13f79535-47bb-0310-9956-ffa450edef68
Revision: 1086114
Node Kind: directory
Last Changed Author: trawick
Last Changed Rev: 1086073
Last Changed Date: 2011-03-28 01:51:18 +0200 (Mon, 28 Mar 2011)

Exporting apr-trunk ...
Path: trunk
URL: http://svn.apache.org/repos/asf/apr/apr/trunk
Repository Root: http://svn.apache.org/repos/asf
Repository UUID: 13f79535-47bb-0310-9956-ffa450edef68
Revision: 1086114
Node Kind: directory
Last Changed Author: fuankg
Last Changed Rev: 1085985
Last Changed Date: 2011-03-27 18:50:30 +0200 (Sun, 27 Mar 2011)

=
### /home/prg/nlm/cwcmdl40/mwccnlm.exe Compiler:
#  In: ..\include\ap_config.h
#From: nw_export.inc
# --
# 236: #include ap_config_layout.h
#   Error: ^
#   the file 'ap_config_layout.h' cannot be opened
=


Re: svn commit: r1086073 - in /httpd/httpd/trunk: ./ include/ modules/cache/ os/netware/ os/win32/ server/ server/mpm/netware/ server/mpm/winnt/

2011-03-27 Thread William A. Rowe Jr.
On 3/27/2011 7:39 PM, Guenter Knauf wrote:
 Am 28.03.2011 01:57, schrieb Jeff Trawick:
 On Sun, Mar 27, 2011 at 7:51 PM,traw...@apache.org  wrote:
 Author: trawick
 Date: Sun Mar 27 23:51:18 2011
 New Revision: 1086073

 URL: http://svn.apache.org/viewvc?rev=1086073view=rev
 Log:
 enable DEFAULT_REL_RUNTIMEDIR on NetWare and Windows

 this commit is missing the Windows and NetWare build
 logic to copy the appropriate file to include/ap_config_layout.h

 just so the info isn't trapped inside another thread:

 Windows: a change is needed (perhaps to libhttpd.dsp) to copy
 os/win32/win32_config_layout.h to include/ap_config_layout.h
 NetWare: something similar
 with other headers we do usually just append w|nw to the extensision, and 
 have these files
 in same directory as where the target should live, f.e.:
 include/ap_config_layout.h   (target)
 include/ap_config_layout.hw  (windows)
 include/ap_config_layout.hnw (netware)
 
 then at least for NetWare where we use GNU make a simple generic rule:
 %.h : %.hnw
 copy $ $@
 
 does the job (we use this already with APR/APU too) ...
 
 I dont say that the copy with those files you commited is of any problem, 
 just wanted to
 mention what existing logic we currently have already with other headers ...
 awaiting Bill's comment on that ...

+/-0, I'm happy either way, I'll commit the build update in the morning whether
the source file is named os_layout.h or ap_config_layout.hw :)


Re: NetWare autobuild httpd-HEAD / apr-HEAD failed

2011-03-27 Thread NormW

Same problem I am seeing.
Norm
On 28/03/2011 2:13 PM, fua...@apache.org wrote:

Complete buildlog: 
http://svwe20.itex.at/autobuilds/asf/httpd/201103280410-netware-httpd.txt.gz
=
Exporting httpd-trunk ...
Path: trunk
URL: http://svn.apache.org/repos/asf/httpd/httpd/trunk
Repository Root: http://svn.apache.org/repos/asf
Repository UUID: 13f79535-47bb-0310-9956-ffa450edef68
Revision: 1086114
Node Kind: directory
Last Changed Author: trawick
Last Changed Rev: 1086073
Last Changed Date: 2011-03-28 01:51:18 +0200 (Mon, 28 Mar 2011)

Exporting apr-trunk ...
Path: trunk
URL: http://svn.apache.org/repos/asf/apr/apr/trunk
Repository Root: http://svn.apache.org/repos/asf
Repository UUID: 13f79535-47bb-0310-9956-ffa450edef68
Revision: 1086114
Node Kind: directory
Last Changed Author: fuankg
Last Changed Rev: 1085985
Last Changed Date: 2011-03-27 18:50:30 +0200 (Sun, 27 Mar 2011)

=
### /home/prg/nlm/cwcmdl40/mwccnlm.exe Compiler:
#  In: ..\include\ap_config.h
#From: nw_export.inc
# --
# 236: #include ap_config_layout.h
#   Error: ^
#   the file 'ap_config_layout.h' cannot be opened
=





Re: [PATCH] default_rel_runtimedir everywhere (Windows, NetWare)

2011-03-27 Thread NormW

On 28/03/2011 10:41 AM, NormW wrote:

On 28/03/2011 9:54 AM, Jeff Trawick wrote:

On Sun, Mar 27, 2011 at 6:09 PM, William A. Rowe Jr.
wr...@rowe-clan.net wrote:

On 3/27/2011 10:30 AM, Jeff Trawick wrote:


Concerns (such as better name for the new file)?


Only one... please don't add #include logic, let Gunter and I wire up
the auto-copy to ap_config_layout.h and we will truly be consistent.

You can update the patch to assume that file always exists. Let's keep
the main .c code as absolutely consistent as possible with fewer
per-arch
variations.


ap_config.h now unconditionally includes ap_config_layout.h.

I renamed the two OS-specific, non-autoconf-build versions to
{win32,netware}_config_layout.h to make it obvious to lurkers that
they should not include this file as present in the os directory.

A patch to httpd-trunk similar to the following does the trick (on 
NetWare at least).


Index: include/ap_config.h
===
--- include/ap_config.h (revision 1086115)
+++ include/ap_config.h (working copy)
@@ -232,8 +232,12 @@
 #include os.h
 #if (!defined(WIN32)  !defined(NETWARE)) || defined(__MINGW32__)
 #include ap_config_auto.h
+#include ap_config_layout.h
+#elif defined(NETWARE)
+#include netware_config_layout.h
+#elif defined(WIN32)
+#include win32_config_layout.h
 #endif
-#include ap_config_layout.h

 #if defined(NETWARE)
 #define AP_NONBLOCK_WHEN_MULTI_LISTEN 1

Norm