2.4.3 / cgi scripts
Scott Raney
raney at metacard.com
Thu Jun 27 19:12:00 EDT 2002
On Fri, 21 Jun 2002 Yennie at aol.com wrote:
> I can't seem to figure out how to run a cgi script with 2.4.3.
> The following works with MC/Darwin as a cgi script with apache:
>
> #!mc
> # file: test.mt
> on startup
> ..
> end startup
>
> After installing the MetacardCarbon/Mach-O bundle in the same directory, I
> can do this from the command line:
>
> ./MetacardCarbon.app/Contents/MacOS/MetacardCarbon test.mt
>
> And the script will run.
> However, I can't seem to configure test.mt to run when called by cgi.
> The following does *not* work as a cgi:
>
> #!./MetacardCarbon.app/Contents/MacOS/MetacardCarbon
> # file: test.mt
> on startup
> ..
> end startup
>
> I've tried creating a symbolic link named "mc" to
> "./MetacardCarbon.app/Contents/MacOS/MetacardCarbon", but that doesn't work
> either (again, it works on the command line).
>
> Any ideas?
The problem is that one of the hacks we had to put in that engine to
deal with the fact that the Finder doesn't set up the environment
properly interferes with running it from the command line. For now,
you've got to supply the full path for both the executable and for the
script file to run on the command line. There will be a workaround
for this in the next build, but note that bundles are something that
UNIX doesn't understand and so you should treat the engine executable
like any other unix binary (i.e., you don't need any of that other
stuff in the .app bundle to run it).
Regards,
Scott
> Brian
********************************************************
Scott Raney raney at metacard.com http://www.metacard.com
MetaCard: You know, there's an easier way to do that...
More information about the metacard
mailing list