@matheusbsbs / matheus-bagliano / commits / 2b5d2d8792
Fork 0

git-instaweb: some Apache have mod_cgi builtin

So test for it, and do not always try to load mod_cgi.o. Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>

Johannes Schindelin committed Jul 26, 2006 at 16:33 UTC 2b5d2d8792c861913d48bcfe02d8a6049c3911f5
1 file changed +3 -1
git-instaweb.sh
+3 -1
@@ -183,8 +183,10 @@ PerlPassEnv GIT_EXEC_DIR
183 EOF
184 else
185 # plain-old CGI
186 + list_mods=`echo "$httpd" | sed "s/-f$/-l/"`
187 + $list_mods | grep 'mod_cgi\.c' >/dev/null || \
188 + echo "LoadModule cgi_module $module_path/mod_cgi.so" >> "$conf"
189 cat >> "$conf" <<EOF
187 -LoadModule cgi_module $module_path/mod_cgi.so
190 AddHandler cgi-script .cgi
191 <Location /gitweb.cgi>
192 Options +ExecCGI