You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by "William A. Rowe, Jr." <wr...@lnd.com> on 2000/06/23 03:27:36 UTC

FW: general/5079: make install should not put include files into the "global namespace".

Apache 2.0 hackers...

This one has been sitting for a little while, and has a valid
suggestion.  I'm not sure, however, how it fits into our plan
for Apache 2.0, or if we are dedicated to never, ever naming
an include file as anything but ap_*.h or http*.h.

Worth consideration I suppose, so I kicked it to the list while
there is time to do something about it (without another god-awful
make file dependencies patch!)

Bill



Received: (qmail 6046 invoked by uid 2012); 29 Sep 1999 12:25:31 -0000
Message-Id: <19...@hyperreal.org>
Date: 29 Sep 1999 12:25:31 -0000
From: Peter Simons <si...@cys.de>
Reply-To: simons@cys.de
To: apbugs@hyperreal.org
Subject: make install should not put include files into the "global namespace".
X-Send-Pr-Version: 3.2

>Number:         5079
>Category:       general
>Synopsis:       make install should not put include files into the "global namespace".
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    apache
>State:          suspended
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   apache
>Arrival-Date:   Wed Sep 29 05:30:00 PDT 1999
>Closed-Date:
>Last-Modified:  Thu Jun 22 18:22:17 PDT 2000
>Originator:     simons@cys.de
>Release:        1.3.9
>Organization:
>Environment:
Not relevant.
>Description:

When doing "make install", apache copies a set of include files into the
directory $(PREFIX)/include. This is somewhat dangerous since you have
include files with very general names like "alloc.h", "compat.h", or "os.h".

On some systems this may overwrite system headers when Apache has been
compiled with --prefix=/usr --- what some people do, notably under Linux.

>How-To-Repeat:

>Fix:

IMHO it would be better to put the includes into a directory
$(PREFIX)/include/apache and to access them as <apache/alloc.h>, like X11
includes do, for example. This also had the advantage that linking from
/usr/include/apache (or some other place) to the real include directory
will enable programs to find the apache includes without needing additional
-I... statements at compile time.

>Release-Note:
>Audit-Trail:
Release-Changed-From-To: 1.3.x-1.3.9
Release-Changed-By: lars
Release-Changed-When: Wed Sep 29 05:40:27 PDT 1999
Comment-Added-By: wrowe
Comment-Added-When: Thu Jun 22 18:21:06 PDT 2000
Comment-Added:

I am forwarding your message to the list for consideration.
Note that we are in the process of adding a significant 
amount of namespace protection to the future Apache 2.0
release, and have made strides in eliminating the non-ap_
identifiers, including for header files.

I have observed reports of clashes over the alloc.h name,
which is renamed ap_alloc.h in the forthcoming release of
Apache 1.3.13 - but do you have any examples of actual
conflicts with the other header names you cite?

Thank you for your report and interest in the Apache
server project!