Received: by taz.hyperreal.com (8.6.12/8.6.5) id JAA28575; Fri, 26 Apr 1996 09:01:14 -0700 Received: from dicsmss1.jrc.it by taz.hyperreal.com (8.6.12/8.6.5) with SMTP id JAA28566; Fri, 26 Apr 1996 09:01:06 -0700 Received: from jrc.it (elect6.jrc.it) by dicsmss1.jrc.it (4.1/EB-950131-C) id AA28210; Fri, 26 Apr 96 18:04:39 +0200 Received: by jrc.it (5.x/EB-950213-L) id AA28970; Fri, 26 Apr 1996 18:00:13 +0200 Date: Fri, 26 Apr 1996 18:00:13 +0200 From: "Dirk.vanGulik" Message-Id: <9604261600.AA28970@ jrc.it> To: new-httpd@hyperreal.com Subject: Re: ScriptAlias-like extensions for perl etc X-Sun-Charset: US-ASCII Sender: owner-new-httpd@apache.org Precedence: bulk Reply-To: new-httpd@hyperreal.com > thoughts? How about atacking this on mime-type level, spotting the .pl and specifying an optional binary as the third argument on the line ? Dw. > All my CGI is written in perl. As an experiment I changed > mod_cgi.c to call the perl binary directly instead of leaving > it to sh (I think that's what gets called to determine that perl > needs to be called because of the "#!" first line.) > > I guess there must be an existing directive that could be reused to > mark script extensions or entire directories to be passed to a binary > instead of to sh. The change to mod_cgi.c is trivial.. > > execle(r->filename, argv0, NULL, env); > becomes > execle("/usr/local/bin/perl", argv0, r->filename, NULL, env); > > > Speedups are not at all dramatic (running perl is a bigger overhead), but > I can detect speedup by hammering on a CGI script and then looking at > mod_status to compare the numbers. > > What'd be nice would be things like, > > CGIBinary /usr/local/bin/perl pl > DefaultBinary /usr/local/bin/perl > > or something along those lines. > > > > rob >