caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Paul Snively <psnively@mac.com>
To: caml-list@inria.fr
Subject: [Caml-list] O'Caml 3.07p2 + Tk 8.4.4 on Mac OS X 10.2.8
Date: Wed, 29 Oct 2003 10:14:26 -0800	[thread overview]
Message-ID: <BB0CCEB8-0A3B-11D8-BBBB-000A27DEEC20@mac.com> (raw)

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Folks,

First, thanks for all the great, hard work on Objective Caml. It's a  
real joy to program in.

I wish to be able to use the Aqua version of Tk, so of course, I had to  
compile the sources following the instructions at  
<http://caml.inria.fr/archives/200211/msg00163.html>, specifically:

"In the ocaml source directory do

    ./configure -tkdefs "-I/Library/Frameworks/Tcl.framework/Headers
- -I/Library/Frameworks/Tk.framework/Headers" -tk-no-x11 -tklibs
"-F/Library/Frameworks/Tcl.framework -framework Tcl
- -F/Library/Frameworks/Tk.framework -framework Tk"

    make world
    make opt
    sudo make install
    make clean"

And this worked flawlessly. However, I immediately ran into the:

"you will get an error message

    SetFrontProcess failed,-606

when you try to use the calculator."

Sure enough. Since I didn't feel it was realistic or even necessarily  
desirable to create a Mac OS X app bundle for every Tk-using  
command-line tool, I set about to see if there was another solution to  
the problem. It turns out that there is, and it is described quite  
nicely at  
<http://www.erlang.org/ml-archive/erlang-questions/200210/ 
msg00148.html>. Briefly, Tk's SetFrontProcess() call needs to be  
prepended with a CPSSetProcessName() and CPSEnableForegroundOperation()  
pair. This change is controversial, which is probably why it's not in  
the current Tk builds: those calls are undocumented and in fact have  
been replaced with a public API in Mac OS X 10.3. However, this patch  
is still important for those running pre-10.3 Mac OS X.

This gets me to the point where "ocamlbrowser" brings up the browser,  
and I can successfully bring it to the front and perform most  
operations. However, whenever I click either in the scrollbar arrows or  
in the page up/down portion of the scrollbar, I get: Uncaught  
exception: Invalid_argument("TKtoCAMLscrollValue"). Also, attempting to  
quit ocamlbrowser using either of the menus (the Application menu or  
the File menu) causes a hang of indefinite duration, requiring a "force  
quit" eventually.

If any other O'Caml aficionados are also struggling to get O'Caml and  
Aqua Tk working together properly, I'd be most interested in joining  
forces. Hopefully it's clear that some good progress has been made, but  
there are just a few weird outstanding issues that it would be nice to  
resolve.

Many thanks and best regards,
Paul Snively
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (Darwin)

iEYEARECAAYFAj+gA4IACgkQugPBK9DeteqZngCeJ12EsmY8WkHRcSxmJ9xhOzS0
NagAnRgmEbxrsBZJpHwskka3XcW7n1B4
=oj1D
-----END PGP SIGNATURE-----

-------------------
To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners


             reply	other threads:[~2003-10-29 18:14 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-10-29 18:14 Paul Snively [this message]
2003-10-29 23:57 ` Jacques Garrigue

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=BB0CCEB8-0A3B-11D8-BBBB-000A27DEEC20@mac.com \
    --to=psnively@mac.com \
    --cc=caml-list@inria.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).