From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on yquem.inria.fr X-Spam-Level: ** X-Spam-Status: No, score=2.2 required=5.0 tests=AWL,DNS_FROM_RFC_POST, SPF_NEUTRAL autolearn=disabled version=3.1.3 X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from mail2-relais-roc.national.inria.fr (mail2-relais-roc.national.inria.fr [192.134.164.83]) by yquem.inria.fr (Postfix) with ESMTP id 80FD7BBAF for ; Fri, 13 Feb 2009 11:56:08 +0100 (CET) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: ArcBABbglEnRVdsVkGdsb2JhbACUDD8BAQEBCQkMBxEDrTEIgQCPIQEDAQOEFQaCN4Ep X-IronPort-AV: E=Sophos;i="4.38,201,1233529200"; d="scan'208";a="21058801" Received: from mail-ew0-f21.google.com ([209.85.219.21]) by mail2-smtp-roc.national.inria.fr with ESMTP; 13 Feb 2009 11:56:08 +0100 Received: by ewy14 with SMTP id 14so1607478ewy.9 for ; Fri, 13 Feb 2009 02:56:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:reply-to :user-agent:mime-version:to:subject:references:in-reply-to :content-type:content-transfer-encoding; bh=6VgMNqPjh+Vkdd7yzHFHfyI7sGXuYmGnncN1qtSGX2U=; b=SVpQChfYduDKhDvbACgetw5pFdd1TB3LX0cQsuoPAPtSA3fJ6cfLJc7sFiGIajclD9 AwN1tddNoSI3YIAtrTOdUI/i9m5yGQtBPNyay5kQuCACTw39sO/8dsPeqonfTXJtUOeV 4WZAfXi3H8MrL7+GWVCAuqphJYuWizuCU/zLY= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:reply-to:user-agent:mime-version:to:subject :references:in-reply-to:content-type:content-transfer-encoding; b=n0JATXbrWZRmxXEjWpi3Y7+E6pJjpR+XTR23WPaGs1TbZc9pOywt/Aq3L3/63jzvbf DE1SutBNNMjWFlCWUhfqG1qaedxPikCjGezKvNTmf6TF30iANyTcvl2Y+mlgQVBGekbn 7AxVkstjn5L+TvRs3JNXGwKKKSWUonhbtYByU= Received: by 10.210.41.14 with SMTP id o14mr185078ebo.45.1234522568101; Fri, 13 Feb 2009 02:56:08 -0800 (PST) Received: from ?192.168.0.102? (papillon.metalscan.fr [212.73.210.234]) by mx.google.com with ESMTPS id 28sm1809185eyg.35.2009.02.13.02.56.07 (version=TLSv1/SSLv3 cipher=RC4-MD5); Fri, 13 Feb 2009 02:56:07 -0800 (PST) Message-ID: <499551C6.7080107@gmail.com> Date: Fri, 13 Feb 2009 11:56:06 +0100 From: Matthieu Dubuget Reply-To: matthieu.dubuget@gmail.com User-Agent: Thunderbird 2.0.0.19 (X11/20090105) MIME-Version: 1.0 To: caml-list@inria.fr Subject: Re: [Caml-list] Ocamlbuild question References: <499350A3.2040203@gmail.com> <1234454366-sup-8627@ausone.inria.fr> <49945D1B.1060507@gmail.com> <49946B84.1010607@gmail.com> In-Reply-To: <49946B84.1010607@gmail.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Spam: no; 0.00; matthieu:01 dubuget:01 matthieu:01 dubuget:01 findlib:01 findlib:01 cmx:01 dependencies:01 ocamlfind:01 ocamlopt:01 -linkpkg:01 -package:01 -package:01 cmx:01 dependencies:01 Matthieu Dubuget a =C3=A9crit : > Matthieu Dubuget a =C3=A9crit : > =20 >> Nicolas Pouillard a =C3=A9crit : >> =20 >>> Excerpts from Matthieu Dubuget's message of Wed Feb 11 23:26:43 +0100= 2009: >>> =20 >>> =20 >>>> Hello, >>>> >>>> I'm trying to manage "internal" camlfind packages. I use "internal" = with >>>> the same meanning than in ocamlbuild documentation when speaking abo= ut >>>> libraries. >>>> >>>> I want my camlfind packages to be re-installed if one of their >>>> dependency was modified. For this, I wrote a simple rule, based on >>>> %.iocamlfind files containing the files to install into findlib >>>> directory. This rule also produces a stamp file : %.oocamlfind. >>>> >>>> I also want my camlfind package to be installed if they are needed b= y >>>> another rule. For this, I do: dep ["pkg_"^nm][nm ^ ".oocamlfind"] fo= r >>>> each internal package. >>>> >>>> It seems to work ok: Suppose that package toto requires package tutu= =2E >>>> When I ask ocamlbuild toto.oocamlfind, the packages tutu is re-built= if >>>> needed. And if I modify one file of tutu, and then ask ocamlbuild to= >>>> generate toto.oocamlbuild, tutu is re-built and installed into findl= ib >>>> directories. fine. >>>> >>>> BUT, when I'm producing a %.native from %.cmx, my dependencies (ie >>>> %.oocamlfind files) are inserted in the command line... >>>> >>>> Here is an example: >>>> ocamlfind ocamlopt -linkpkg -package mtsvrac -package log >>>> logtest/test.cmx mtsvrac.oocamlfind log.oocamlfind -o logtest/test.n= ative >>>> >>>> mtsvrac.oocamlfind and log.oocamlfind where added to the dependencie= s of >>>> logtest/test.native. >>>> >>>> What would be the right solution to avoid this problem? >>>> Is there something like a "dependency that should not be linked?" >>>> =20 >>>> =20 >>> Hello, >>> >>> You should try to tag your .oocamlfind file with the dont_link_with t= ag. >>> >>> (this point certainly needs an entry in the FAQ...) >>> >>> Best regards, >>> >>> =20 >>> =20 >> It seems not to work =E2=80=93 at least with ocaml 3.10.2 from godi. >> >> I have: >> >> =20 >>>> ocamlbuild -show-tags mtsvrac.oocamlfind >>>> Tags for "mtsvrac.oocamlfind": >>>> {. dont_link_with, extension:oocamlfind, file:mtsvrac.oocamlfind, qu= iet, >>>> traverse .} >>>> Finished, 0 targets (0 cached) in 00:00:00. >>>> =20 >> and still >> >> =20 >>>> ocamlopt.opt: don't know what to do with mtsvrac.oocamlfind. >>>> =20 >> I will check at home with 3.11 >> =20 > > Idem > =20 Thanks to Nicolas: the solution was: - tag .oocamlfind files with "dont_link_with" - and add "dont_link_with" in left part of dep: > dep ["pkg_"^nm;"dont_link_with"][nm ^ ".oocamlfind"]=20 Matt