[Mono-list] Using MONO with MOD_HAYDN & Apache

Manuel Reyes Manuel.Reyes@e-mis.com
Fri, 27 Sep 2002 10:11:35 +0100


This may be getting away from the topic of the mailing list but by the same
token it is also relavent. I am attempting to get MONO to work with
MOD_HAYDN (http://haydn.sourceforge.net/) so that I can serve ASPX pages via
an Apache webserver.

Unfortunalty AFAIK this is something that isnt covered in the Mono
documentation (and in reality nor should it be) but the MOD_HAYDN
documentation is, shall we say, non-existant.

Does anybody have any experience of getting this up and running? if so how?

From what I can gleam from the limited docs, the haydn module needs to be
compiled into Apache, and this can be done via the make script supplied with
the module.  This process requires mod_so to be compiled into Apache :

mreyes@gandalf2:~$ /usr/sbin/apache -l
Compiled-in modules:
  http_core.c
  mod_so.c
  mod_macro.c
suexec: enabled; valid wrapper /usr/lib/apache/suexec
mreyes@gandalf2:~$

When attempting to run the make script for the module I get the following
output/error :

mreyes@gandalf2:~/mod_haydn/mod_haydn-1.3-0.0.6$ make
/usr/bin/apxs -c  -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include
-lmono -lgmodule-2.0 -ldl -lglib-2.0 -lm -lpthread -lgc src/mod_haydn.c
gcc -DLINUX=22 -DEAPI -DTARGET="apache" -DDB_DBM_HSEARCH=1
-DDEV_RANDOM=/dev/random -DUSE_HSREGEX -D_LARGEFILE_SOURCE
-D_FILE_OFFSET_BITS=64 -O1 -fPIC -DSHARED_MODULE -I/usr/include/apache-1.3
-I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include  -c src/mod_haydn.c
gcc -shared -o src/mod_haydn.so mod_haydn.o -lmono -lgmodule-2.0 -ldl
-lglib-2.0 -lm -lpthread -lgc -lc -lm -lcrypt -ldb -ldb -lexpat
/usr/bin/ld: cannot find -lgc
collect2: ld returned 1 exit status
apxs:Break: Command failed with rc=1
make: *** [mod_haydn.so] Error 1
mreyes@gandalf2:~/mod_haydn/mod_haydn-1.3-0.0.6$

Now this is where is gets weird, although apache is configured with mod_so
support the "apxs" untility hasnt appeared anywhere, so I have copied this
from another machine and place it in the /usr/bin/ directory.

M Reyes