You are viewing a plain text version of this content. The canonical link for it is here.
Posted to apache-bugdb@apache.org by Huub Stoffers <hs...@nki.nl> on 1999/07/30 17:05:15 UTC

config/4802: .configure generates Makefile which fails to find suexec.c source file

>Number:         4802
>Category:       config
>Synopsis:       .configure generates Makefile which fails to find suexec.c source file
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    apache
>State:          open
>Class:          sw-bug
>Submitter-Id:   apache
>Arrival-Date:   Fri Jul 30 08:10:01 PDT 1999
>Last-Modified:
>Originator:     hs@nki.nl
>Organization:
apache
>Release:        1.3.6
>Environment:
OS: Solaris 7 (SunOS 5.7)
make: Solaris bundled make (/usr/ccs/bin/make)
shell; Solaris bundled Bourne shell (/usr/bin/sh)
Compiler: gcc 2.8.1

uname -a output:
SunOS Hephaistos.nki.nl 5.7 Generic_106541-04 sun4m sparc SUNW,SPARCstation-5
>Description:
I generated the Makefile with the following "autoconfig" command
line:
	CC="gcc" OPTIM="-O2" \
	./configure     --prefix=/usr/local/apache \
        	        --datadir=/export/home/httpd \
                	--runtimedir=/var/log/apache \
                	--logfiledir=/var/log/apache \
                	--mandir=/usr/local/man \
                	--enable-module=expires \
                	--enable-module=info \
                	--enable-suexec \
                	--suexec-caller=httpd \
                	--suexec-uidmin=1000 \
                	--suexec-gidmin=1000

This generated a Makefile that worked just fine,
except for the conditional make of the suexec stuff, which is
under the build-support target. The build-support target in the
Makefile generated by the above cited configure command
looks like this:

(...)
#   build the additional support stuff
build-support:
        @echo "===> $(SRC)/support"; \
        cd $(TOP)/$(SRC)/support; $(MAKE) $(MFLAGS) all; \
        if [ ".$(suexec)" = .1 ]; then \
            $(MAKE) $(MFLAGS) \
                EXTRA_CFLAGS='\
                        -DHTTPD_USER=\"$(suexec_caller)\" \
                        -DUID_MIN=$(suexec_uidmin) \
                        -DGID_MIN=$(suexec_gidmin) \
                        -DUSERDIR_SUFFIX=\"$(suexec_userdir)\" \
                        -DLOG_EXEC=\"$(suexec_logexec)\" \
                        -DDOC_ROOT=\"$(suexec_docroot)\" \
                        -DSAFE_PATH=\"$(suexec_safepath)\" \
                ' \
                suexec; \
        fi; \
        echo "<=== $(SRC)/support"

## ------------------------------------------------------------------
(...)

Using the make on Solaris 2.7 (/usr/ccs/bin/make) and gcc, this leads
to the following error:

	gcc:  suexec.c No such file or directory

Note that there are TWO spaces between the colon and suexec.c! It
seems that there is one backslash too many, and that gcc fails because it
is in fact looking for a file called ' suexec.c', rather than 'suexec.c'.
>How-To-Repeat:
See Full Description. Repeat the configure command and run make.
>Fix:
I fixed it 'by hand', by removing the line continuation backslash after the
last EXTRA_CFLAGS item, as follows:

(...)
#   build the additional support stuff
build-support:
        @echo "===> $(SRC)/support"; \
        cd $(TOP)/$(SRC)/support; $(MAKE) $(MFLAGS) all; \
        if [ ".$(suexec)" = .1 ]; then \
            $(MAKE) $(MFLAGS) \
                EXTRA_CFLAGS='\
                        -DHTTPD_USER=\"$(suexec_caller)\" \
                        -DUID_MIN=$(suexec_uidmin) \
                        -DGID_MIN=$(suexec_gidmin) \
                        -DUSERDIR_SUFFIX=\"$(suexec_userdir)\" \
                        -DLOG_EXEC=\"$(suexec_logexec)\" \
                        -DDOC_ROOT=\"$(suexec_docroot)\" \
                        -DSAFE_PATH=\"$(suexec_safepath)\" ' \
                suexec; \
        fi; \
        echo "<=== $(SRC)/support"

## ------------------------------------------------------------------
(...)

>Audit-Trail:
>Unformatted:
[In order for any reply to be added to the PR database, you need]
[to include <ap...@Apache.Org> in the Cc line and make sure the]
[subject line starts with the report component and number, with ]
[or without any 'Re:' prefixes (such as "general/1098:" or      ]
["Re: general/1098:").  If the subject doesn't match this       ]
[pattern, your message will be misfiled and ignored.  The       ]
["apbugs" address is not added to the Cc line of messages from  ]
[the database automatically because of the potential for mail   ]
[loops.  If you do not include this Cc, your reply may be ig-   ]
[nored unless you are responding to an explicit request from a  ]
[developer.  Reply only with text; DO NOT SEND ATTACHMENTS!     ]