caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Gerd Stolpmann <info@gerd-stolpmann.de>
To: Matej Kosik <5764c029b688c1c0d24a2e97cd764f@gmail.com>
Cc: caml-list@inria.fr
Subject: Re: [Caml-list] a question about compilation ... [sexplib; gramlib]
Date: Thu, 19 Sep 2013 17:16:49 +0200	[thread overview]
Message-ID: <1379603809.11824.18.camel@thinkpad> (raw)
In-Reply-To: <523AE1BE.8090808@gmail.com>

[-- Attachment #1: Type: text/plain, Size: 1448 bytes --]

Am Donnerstag, den 19.09.2013, 12:36 +0100 schrieb Matej Kosik:
> Hi,
> 
> If my program contains "__LOCATION__" macro, I can get it compiled with the following instructions:
> 
> 	ocamlfind ocamlc -package camlp4.gramlib -pp camlp4of main.ml -o main.cmo -c
> 	ocamlfind ocamlc -package camlp4.gramlib -linkpkg main.cmo -o main

I don't know where you have this from, but this is not the right way of
doing it. Better:

ocamlfind ocamlc -package camlp4.macro -syntax camlp4o main.ml -c

> 
> If my program contains "with sexp" macro, I can get it compiled with the following instructions:
> 
> 	ocamlfind ocamlc -package sexplib,sexplib.syntax -syntax camlp4o main.ml -o main.cmo -c
> 	ocamlfind ocamlc -package sexplib,sexplib.syntax -linkpkg main.cmo -o main
> 
> Is it technically possible to to compile a program where I use both "__LOCATION__" as well as "with sexp" macros?
> (like the attached sample)

Combined:

ocamlfind ocamlc -package camlp4.macro,sexplib,sexplib.syntax -syntax
camlp4o main.ml -c

Gerd

> 
> Thank you very much, in advance, for the help.
> 

-- 
------------------------------------------------------------
Gerd Stolpmann, Darmstadt, Germany    gerd@gerd-stolpmann.de
Creator of GODI and camlcity.org.
Contact details:        http://www.camlcity.org/contact.html
Company homepage:       http://www.gerd-stolpmann.de
------------------------------------------------------------

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 490 bytes --]

  parent reply	other threads:[~2013-09-19 15:17 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-09-19 11:36 Matej Kosik
2013-09-19 12:17 ` Kakadu
2013-09-19 15:16 ` Gerd Stolpmann [this message]
2013-09-20  8:54   ` Matej Kosik

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=1379603809.11824.18.camel@thinkpad \
    --to=info@gerd-stolpmann.de \
    --cc=5764c029b688c1c0d24a2e97cd764f@gmail.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).