modcaml
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Modcaml] mod_caml/cocanwiki OCaml linking issues


From: Jesse Guardiani
Subject: Re: [Modcaml] mod_caml/cocanwiki OCaml linking issues
Date: Mon, 01 Aug 2005 13:40:30 -0400
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.10) Gecko/20050716 Thunderbird/1.0.6 Mnenhy/0.7.2.0

Jesse Guardiani wrote:

OK,

I'm getting a bit closer to my goal now. mod_caml is installed, and
I submitted a Gentoo ebuild for it last night. Now I've
cocanwiki built and installed on my server. However,
I'm now getting OCaml linking errors when I try to
start apache:

# /etc/init.d/apache2 restart
* Stopping apache2...
Syntax error on line 69 of /usr/lib/apache2/conf/vhosts/vhosts.conf:
Failure("error while linking /var/www/localhost/htdocs/cocan/html/_bin/cocanwiki.cma.\nReference to undefined global `ExtString'") [ ok ]
* Apache2 has detected a syntax error in your configuration files:
Syntax error on line 69 of /usr/lib/apache2/conf/vhosts/vhosts.conf:
Failure("error while linking /var/www/localhost/htdocs/cocan/html/_bin/cocanwiki.cma.\nReference to undefined global `ExtString'")

I think I understand what is happening here. The problem is that
I'm not sure how to fix it. Hopefully someone here can
help me out.

Here are the minor changes I made to get cocanwiki compiled:

---------------------------------------------------------------------------------------- diff -ru cocanwiki-1.3.12/Makefile.config cocanwiki-1.3.12.orig/Makefile.config --- cocanwiki-1.3.12/Makefile.config 2005-08-01 11:39:45.000000000 -0400 +++ cocanwiki-1.3.12.orig/Makefile.config 2005-04-02 12:31:10.000000000 -0500
@@ -8,6 +8,6 @@
# following directories.  This really only applies for packagers
# building the Debian package.

-APACHECONFDIR := /etc/apache/conf
+APACHECONFDIR := /etc/apache

WIKIINSTALLDIR := /usr/share/cocanwiki
diff -ru cocanwiki-1.3.12/scripts/Makefile cocanwiki-1.3.12.orig/scripts/Makefile --- cocanwiki-1.3.12/scripts/Makefile 2005-08-01 12:10:32.000000000 -0400 +++ cocanwiki-1.3.12.orig/scripts/Makefile 2005-04-02 12:30:54.000000000 -0500
@@ -3,9 +3,9 @@

include ../Makefile.config

-OCAMLC := ocamlfind ocamlc
+OCAMLC := ocamlc
OCAMLCFLAGS := -w s \
- -I +apache -package pcre -I +dbi -package extlib -package netstring -package calendar \ + -I +apache -I +pcre -I +dbi -I +extlib -I +netstring -I +calendar \
       -I lib
CPP := cpp
----------------------------------------------------------------------------------------

I'm used to using ocamlfind, so I didn't understand why cocanwiki was trying to build using directories relative to the ocaml base. It wouldn't compile that way, because findlib defaults to putting new pacakges in a different directory from the ocaml base.
So I changed it, and it built.

But now I'm getting these module loading errors. Any ideas?


I added -linkpkg to my `ocamlfind` string in scripts/Makefile, hoping it would solve the
linking problem by compiling the interfaces in, but now I get this:

# make all install
make -C scripts all
make[1]: Entering directory `/usr/local/src/ocaml/cocanwiki-1.3.12/scripts'
ocamlfind ocamlc -w s -I +apache -package pcre -I +dbi -package extlib -package netstring -package calendar -I lib -linkpkg -c lib/cocanwiki_date.ml ocamlfind ocamlc -w s -I +apache -package pcre -I +dbi -package extlib -package netstring -package calendar -I lib -linkpkg -c lib/cocanwiki_ext_calendar.ml ocamlfind ocamlc -w s -I +apache -package pcre -I +dbi -package extlib -package netstring -package calendar -I lib -linkpkg -c lib/cocanwiki_mail.ml ocamlfind ocamlc -w s -I +apache -package pcre -I +dbi -package extlib -package netstring -package calendar -I lib -linkpkg -a -o lib/cocanwiki.cma lib/cocanwiki_version.cmo lib/cocanwiki_date.cmo lib/cocanwiki_files.cmo lib/cocanwiki_server_settings.cmo lib/cocanwiki_strings.cmo lib/cocanwiki_create_host.cmo lib/wikilib.cmo lib/cocanwiki_template.cmo lib/cocanwiki_images.cmo lib/cocanwiki_ok.cmo lib/cocanwiki.cmo lib/cocanwiki_links.cmo lib/cocanwiki_ext_calendar.cmo lib/cocanwiki_emailnotify.cmo lib/cocanwiki_diff.cmo lib/cocanwiki_pages.cmo lib/cocanwiki_mail.cmo
Files lib/cocanwiki_server_settings.cmo
and /usr/lib/ocaml/site-packages/netstring/compatcgi.cma
make inconsistent assumptions over interface Cgi
make[1]: *** [lib/cocanwiki.cma] Error 2
make[1]: Leaving directory `/usr/local/src/ocaml/cocanwiki-1.3.12/scripts'
make: *** [all] Error 2
Exit 2

Hmmm.... netstring.cgi conflicts with apache.cgi. How do I get around that?

--
Jesse Guardiani
Programmer/Sys Admin
address@hidden





reply via email to

[Prev in Thread] Current Thread [Next in Thread]