caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Trevor Jim <trevor@research.att.com>
To: Shivkumar Chandrasekaran <shiv@ece.ucsb.edu>
Cc: caml-list@inria.fr
Subject: [Caml-list] Re: Aqua ocamlbrowser on Mac OS X
Date: Fri, 6 Feb 2004 16:00:37 -0500	[thread overview]
Message-ID: <83808503-58E7-11D8-B5B7-00039393D0CC@research.att.com> (raw)
In-Reply-To: <42856FC8-58D8-11D8-A224-003065BDAA76@ece.ucsb.edu>

I debugged the following when getting a version of Unison running in 
Aqua:

     /* When you click-start or use the open command, the program is 
invoked with
        a command-line arg of the form -psn_XXXXXXXXX.  The XXXXXXXX is 
a "process
        serial number" and it seems to be important for Carbon programs. 
  We need
        to get rid of it if it's there so the ocaml code won't exit.  
Note, the
        extra arg is not added if the binary is invoked directly from 
the command
        line without using the open command. */
     if (argc == 2 && strncmp(argv[1],"-psn_",5) == 0) {
         argc--;
         argv[1] = NULL;
     }

I just put that in main before calling caml.  (I am calling caml from 
ObjC.)

-Trevor

On Friday, February 6, 2004, at 02:11  PM, Shivkumar Chandrasekaran 
wrote:

> did not work if I double-clicked on Ocamlbroswer.app. I then tried 
> from the command line
>
> open -a Ocamlbrowser
>
> That at least let ocamlbrowser display its error message that the 
> options to the command line were at fault. All the Console showed in 
> the log was a dreaded "RegisterProcess failed (error -50)" message.
>
> So I edited the source file ..../otherlibs/labltk/browser/main.ml and 
> essentially commented out the command line argument parsing step. I 
> did "make" and moved the new binary into 
> OCamlbrowser.app/Contents/MacOS/ and everything works pretty nicely 
> now.

-------------------
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


      parent reply	other threads:[~2004-02-06 21:00 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-02-06 19:11 [Caml-list] " Shivkumar Chandrasekaran
2004-02-06 19:29 ` Shivkumar Chandrasekaran
2004-02-06 21:00 ` Trevor Jim [this message]

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=83808503-58E7-11D8-B5B7-00039393D0CC@research.att.com \
    --to=trevor@research.att.com \
    --cc=caml-list@inria.fr \
    --cc=shiv@ece.ucsb.edu \
    /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).