httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Rainer Jung <>
Subject Re: [users@httpd] Question about configure not answered in documentation
Date Sat, 06 Apr 2019 07:59:46 GMT
Hi Jeff,

Am 06.04.2019 um 00:19 schrieb Jeff Cauhape:
> Well,
> That almost worked.
> I edited the config.layout file and copied <Layout Apache> to <Layout DETR>.
> In <Layout DETR> I made the following changes only:
> <Layout DETR>
>      prefix:        /usr/local/apache2
>      exec_prefix:   ${prefix}
>      bindir:        ${exec_prefix}/bin
>      sbindir:       ${exec_prefix}/bin
>      libdir:        ${exec_prefix}/lib
>      libexecdir:    ${exec_prefix}/modules
>      mandir:        ${prefix}/man
>      sysconfdir:    ${prefix}/conf
>      datadir:       ${prefix}
>      installbuilddir: ${datadir}/build
>      errordir:      ${datadir}/error
>      iconsdir:      ${datadir}/icons
>      htdocsdir:     /var/www/html             <- Changed
>      manualdir:     ${datadir}/manual
>      cgidir:        /var/www/cgi-bin		<- Changed
>      includedir:    ${prefix}/include
>      localstatedir: ${prefix}
>      runtimedir:    ${localstatedir}/logs
>      logfiledir:    ${localstatedir}/logs
>      proxycachedir: ${localstatedir}/proxy
> </Layout>
> I then ran config like this from a shell script:
> #!/bin/bash
> ./configure --with-pcre=/usr/local/bin/pcre-config \
>          --enable-layout=DETR \
>          --prefix=/apps/apache_2.4.39 \
>          --enable-proxy-html   \
>          --enable-socache-shmcb \
>          --enable-ssl
> What happened is that the /var/www/html and /var/www/cgi-bin directories
> got created, but in the httpd.conf file had this for the DocumentRoot and script locations:
> DocumentRoot "/apps/apache_2.4.39/htdocs"
> <Directory "/apps/apache_2.4.39/htdocs">
> ...
> and
>      ScriptAlias  /cgi-bin/   "/apps/apache_2.4.39/cgi-bin/"
> It looks like there is someplace where directives in config.layout are being ignored.
> n.b. After I reanthe config command, I ran a 'make clean' prior to the 'make' to build
> new server.

Thanks for giving it a try, I think you are already pretty close.

To check, whether the layout was successfully picked up you can do a

% grep cgidir config.log
% grep htdocsdir config.log

The file config.log is written during configure and should contain 
cgidir, exp_cgidir, rel_cgidir, htdocsdir, exp_htdocsdir and rel_htdocsdir.

The values shown by grep should match those given in the layout.

Since you wrote, that the new directories were created, I expect the 
grep commands to show the correct values, but it is a good first step 
for double-checking.

Next: the source config file docs/conf/ contains the right 
placeholders, e.g.

DocumentRoot "@exp_htdocsdir@"
<Directory "@exp_htdocsdir@">
     ScriptAlias /cgi-bin/ "@exp_cgidir@/"
# "@exp_cgidir@" should be changed to whatever your ScriptAliased
<Directory "@exp_cgidir@">

etc. so it must do replacements and you should get your configured values.

But: I vaguely remember, that "make install" will not overwrite config 
files previously installed to the same installation directory to prevent 
loosing older customization during updates (and "make clean" will not 
remove them). Could that be your problem? Is the file timestamp of 
conf/httpd.conf in the installation directory later than your layout 
changes or older? Does it work if you remove the whole old installation 
directory and run a new "make install"?



To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message