You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by Rainer Jung <ra...@kippdata.de> on 2009/01/03 14:55:24 UTC

httpd build variables

Most build variables for httpd are used via APACHE_SUBST, which means 
they get added to build/config_vars.mk.

A) Where to define them?
========================

There are two places, were a lot of ariables are added via APACHE_SUBST:

1) Macro APACHE_GEN_CONFIG_VARS

Defined in acinclude.m4 and called in configure.in.
It contains 75 calls to APACHE_SUBST.

2) Directly in configure.in

It contains about 21 calls to APACHE_SUBST.

Is there any concept, whether APACHE_SUBST for a new variable should be 
put into APACHE_GEN_CONFIG_VARS or directly into configure.in?

I can see that the ones in the macro will be included last into 
config_vars.mk, but apart from that any rules?

B) Should they be installed?
============================

The script build/config_vars.sh deletes a lot of variables before 
installing build/config_vars.mk. Is there any concept, which variables 
should get installed, and which ones should be removed before installing 
the file?

Regards,

Rainer


Re: httpd build variables

Posted by Joe Orton <jo...@redhat.com>.
On Sat, Jan 03, 2009 at 02:55:24PM +0100, Rainer Jung wrote:
> Most build variables for httpd are used via APACHE_SUBST, which means  
> they get added to build/config_vars.mk.
>
> A) Where to define them?
> ========================
>
> There are two places, were a lot of ariables are added via APACHE_SUBST:
>
> 1) Macro APACHE_GEN_CONFIG_VARS
>
> Defined in acinclude.m4 and called in configure.in.
> It contains 75 calls to APACHE_SUBST.
>
> 2) Directly in configure.in
>
> It contains about 21 calls to APACHE_SUBST.
>
> Is there any concept, whether APACHE_SUBST for a new variable should be  
> put into APACHE_GEN_CONFIG_VARS or directly into configure.in?

Generally, I'd put new SUBST calls in configure.in, grouped near to the 
places where the new variables are being defined.

> I can see that the ones in the macro will be included last into  
> config_vars.mk, but apart from that any rules?

Not really, it's a bit random!

> B) Should they be installed?
> ============================
>
> The script build/config_vars.sh deletes a lot of variables before  
> installing build/config_vars.mk. Is there any concept, which variables  
> should get installed, and which ones should be removed before installing  
> the file?

It should be trimmed by config_vars.sh unless you have a good reason why 
an external module would need to use the new variable at build time.  
Generally, I'd say: try to export as little as possible in 
config_vars.mk because otherwise it becomes part of the API and some 
third-party module will depend on it.

Regards, Joe