Bug 4908 - mod-mono cannot build against Apache 2.4, needs porting to new API
Summary: mod-mono cannot build against Apache 2.4, needs porting to new API
Status: RESOLVED FIXED
Alias: None
Product: Runtime
Classification: Mono
Component: General ()
Version: unspecified
Hardware: PC Linux
: --- normal
Target Milestone: ---
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2012-05-06 09:14 UTC by Jo Shields
Modified: 2014-09-15 12:40 UTC (History)
5 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:


Attachments
Apache 2.4 PoC port (2.63 KB, patch)
2012-05-07 06:09 UTC, Jo Shields
Details


Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on GitHub or Developer Community with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED FIXED

Description Jo Shields 2012-05-06 09:14:15 UTC
This bug was originally reported at http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=666836

Apache 2.4 has helpfully changed its API in several places, in a backwards-incompatible way. Some of these changes can be resolved with a simple search-and-replace, however some are more invasive. A full build log is at http://bugs.debian.org/cgi-bin/bugreport.cgi?msg=10;filename=mod-mono_2.10-3-amd64-20120504-0404.gz;att=1;bug=666836

The issues, as reported in Debian:

error: 'conn_rec' has no member named 'remote_ip'

	These fields have been renamed in order to distinguish between
	the client IP address of the connection and the useragent IP
	address of the request. Porting is trivial, in most cases
	changing the pointer from conn_rec->remote_ip to
	request_rec->useragent_ip is enough

error: implicit declaration of function 'ap_requires'
error: implicit declaration of function 'ap_default_type'

	These functions were removed along the 2.2 authnz API. It needs
	a non-trivial API redesign.

error: implicit declaration of function 'ap_get_server_version'
	
	Use ap_get_server_banner()

error: format not a string literal and no format arguments [-Werror=format-security]

	Apache2 modules are being built with hardening build flags now
	in order to satisfy the "hardening release goal" [2]. A trivial
	fix comes over that problem.
Comment 1 Jo Shields 2012-05-07 06:09:19 UTC
Created attachment 1814 [details]
Apache 2.4 PoC port

The attached patch has been provided by Arno Töll as a "proof of concept" port to Apache 2.4
Comment 2 Miguel de Icaza [MSFT] 2012-09-02 13:24:31 UTC
The patch seems like a step in the right direction.

It would need to get support for the 

#if APACHEXXX

Which is currently lacking.   That means that we would break anyone with pre 2.4 installs.
Comment 3 Paul Schneider 2012-12-18 16:59:37 UTC
I forked a mod_mono, and, after 2 additional commits, I hope it won't break no support.
https://github.com/pazof/mod_mono/commit/2c7386122fbbccfe549d9028dd01dd612d90322b