Patch mod_v8cgi and Apache 2.4

21 views
Skip to first unread message

ZenDark

unread,
Feb 26, 2012, 4:27:21 AM2/26/12
to v8cgi
I'm trying mod_v8cgi inside the new Apache 2.4, and since the API
changed I had to make some little changes to get it working.
I thought also of sharing:

*** src/mod_v8cgi.cc.original 2012-02-25 19:30:45.375866283
+0100
--- src/mod_v8cgi.cc 2012-02-26 11:21:25.144598660
+0100
***************
*** 29,34
****
--- 29,38
----

*/
extern "C" module AP_MODULE_DECLARE_DATA
v8cgi_module;

+ #ifdef
APLOG_USE_MODULE
+
APLOG_USE_MODULE(v8cgi);
+
#endif
+
class v8cgi_Module : public v8cgi_App
{

public:
request_rec *
request;
***************
*** 38,44
****
--- 42,52
----
}

void error(const char * data) {
+ #ifdef APLOG_USE_MODULE
+ ap_log_rerror(__FILE__, __LINE__, APLOG_MODULE_INDEX,
APLOG_ERR, 0, this->request, "%s", data);
+ #else
ap_log_rerror(__FILE__, __LINE__, APLOG_ERR, 0, this-
>request, "%s", data);
+ #endif
}

/**

Ondřej Žára

unread,
Feb 28, 2012, 2:08:14 AM2/28/12
to v8...@googlegroups.com
Hi,

thanks a lot for this path; I did not even know Apache 2.4 existed :-)

I presume these changes are not backwards compatible, right?


Sincerely,
Ondrej Zara


2012/2/26 ZenDark <zend...@gmail.com>:

> --
> You received this message because you are subscribed to the Google Groups "v8cgi" group.
> To post to this group, send email to v8...@googlegroups.com.
> To unsubscribe from this group, send email to v8cgi+un...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/v8cgi?hl=en.
>

ZenDark

unread,
Feb 29, 2012, 2:35:12 AM2/29/12
to v8cgi
Hi,

They are backwards compatible :)
With the same code you can compile a 2.2 module or a 2.4 module.
That's what the macro APLOG_USE_MODULE is doing.
So it won't break the 2.2 module and will give support for the 2.4.


On Feb 28, 8:08 am, Ondřej Žára <ondrej.z...@gmail.com> wrote:
> Hi,
>
> thanks a lot for this path; I did not even know Apache 2.4 existed :-)
>
> I presume these changes are not backwards compatible, right?
>
> Sincerely,
> Ondrej Zara
>
> 2012/2/26 ZenDark <zendar...@gmail.com>:

Ondřej Žára

unread,
Mar 1, 2012, 2:17:25 AM3/1/12
to v8...@googlegroups.com
> They are backwards compatible :)
> With the same code you can compile a 2.2 module or a 2.4 module.
> That's what the macro APLOG_USE_MODULE is doing.
> So it won't break the 2.2 module and will give support for the 2.4.

That is very nice! Would you please attach the patch as an attachment
(not inline, as in the first post) so I can extract it and apply
easily?

Thanks,
Ondrej

ZenDark

unread,
Mar 3, 2012, 1:07:19 PM3/3/12
to v8...@googlegroups.com
There you go!!

Great work

>> > To unsubscribe from this group, send email to v8cgi+unsubscribe@googlegroups.com.


>> > For more options, visit this group athttp://groups.google.com/group/v8cgi?hl=en.
>
> --
> You received this message because you are subscribed to the Google Groups "v8cgi" group.
> To post to this group, send email to v8...@googlegroups.com.

> To unsubscribe from this group, send email to v8cgi+unsubscribe@googlegroups.com.

mod_v8cgi.patch

Ondřej Žára

unread,
Mar 6, 2012, 8:56:09 AM3/6/12
to v8...@googlegroups.com
Thanks a lot! Commited in revision 1006.


O.

2012/3/3 ZenDark <zend...@gmail.com>:

>> >> > v8cgi+un...@googlegroups.com.


>> >> > For more options, visit this group
>> >> > athttp://groups.google.com/group/v8cgi?hl=en.
>> >
>> > --
>> > You received this message because you are subscribed to the Google
>> > Groups "v8cgi" group.
>> > To post to this group, send email to v8...@googlegroups.com.
>> > To unsubscribe from this group, send email to

>> > v8cgi+un...@googlegroups.com.


>> > For more options, visit this group at
>> > http://groups.google.com/group/v8cgi?hl=en.
>> >
>

> --
> You received this message because you are subscribed to the Google Groups
> "v8cgi" group.

> To view this discussion on the web visit
> https://groups.google.com/d/msg/v8cgi/-/I9ys0WzifgYJ.


>
> To post to this group, send email to v8...@googlegroups.com.
> To unsubscribe from this group, send email to

> v8cgi+un...@googlegroups.com.

Reply all
Reply to author
Forward
0 new messages