From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail4-relais-sop.national.inria.fr (mail4-relais-sop.national.inria.fr [192.134.164.105]) by walapai.inria.fr (8.13.6/8.13.6) with ESMTP id q0DDwbxA024830 for ; Fri, 13 Jan 2012 14:58:37 +0100 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: ApACADE3EE/U4xEIk2dsb2JhbABChRCoCCIBAQEBCQkLCRQDIoFyAQEEASNWEAsaAiYCAlcGEwmHcQIGpVGRQ4Evgk6HCoEWBI0ljT6Mbw X-IronPort-AV: E=Sophos;i="4.71,504,1320620400"; d="scan'208";a="126779018" Received: from moutng.kundenserver.de ([212.227.17.8]) by mail4-smtp-sop.national.inria.fr with ESMTP; 13 Jan 2012 14:58:31 +0100 Received: from office1.lan.sumadev.de (dslb-094-219-216-241.pools.arcor-ip.net [94.219.216.241]) by mrelayeu.kundenserver.de (node=mreu4) with ESMTP (Nemesis) id 0Ln0mX-1SKCLc08IX-00hK70; Fri, 13 Jan 2012 14:56:01 +0100 Received: from [192.168.5.106] (dslb-094-219-216-241.pools.arcor-ip.net [94.219.216.241]) by office1.lan.sumadev.de (Postfix) with ESMTPSA id C63EDC00CE; Fri, 13 Jan 2012 14:56:00 +0100 (CET) From: Gerd Stolpmann To: =?ISO-8859-1?Q?St=E9phane?= Glondu Cc: Philippe Veber , caml users In-Reply-To: <4F102F24.9050000@glondu.net> References: <4F102F24.9050000@glondu.net> Content-Type: text/plain; charset="UTF-8" Date: Fri, 13 Jan 2012 14:56:05 +0100 Message-ID: <1326462965.14288.67.camel@thinkpad> Mime-Version: 1.0 X-Mailer: Evolution 2.28.3 X-Provags-ID: V02:K0:/twJxgY26/M4EQxfbhImWeCgsFYsD4NB9Wa+4Waq8vD n6VZlN1Xe1jhZkUIviH6Vy/BXAVtwXeq89l+dpTQyE4mMnne13 7guIreKs+dJ7Jx0lU7xcxJLC/7ImO0XxsAN0aEb0k9WoubU+At +QH01wkTFu+Rhe4+WXgu+qad4F6KsbeK+sP2rjKXs6dUnlLq4U pVW3SBKcEBU0F7y+eooqQal9GD7xBQYHPF7G+Mwr3j4dsjhl9q kWWZA1yfp32UEsxspKJvRgGbkxe77rT6eZ9qN0CQ/XLI0fzcFK gzSVJGX9GHaTCYU5OVNcwOiR4Xtk+ExsSIiLE+62krrmy/52YA zWxFpyuaZ8b1eiXxahEqfxLMObt98++ITmie8L4+s Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from quoted-printable to 8bit by walapai.inria.fr id q0DDwbxA024830 Subject: Re: [Caml-list] Compiling the ocaml distribution under multiarched Debian/Ubuntu Am Freitag, den 13.01.2012, 14:18 +0100 schrieb Stéphane Glondu: > Le 13/01/2012 12:59, Philippe Veber a écrit : > > Debian and Ubuntu have not so recently switched to multiarch binaries > > (including libs, see http://wiki.debian.org/Multiarch/Implementation). > > This is an important change for ocaml C bindings since the libraries are > > now to be found in /usr/lib/ instead of /usr/lib. I > > was just bitten by this, when realizing that the ocaml configure script > > couldn't find libX11.so and wouldn't install graphics. A similar problem > > was handled by the people in charge of debian ocaml packages > > (http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=619344). Now my > > question is the following: will this evolution be a problem for GODI/odb > > packages (and more generally source distribution), and what is the > > advised fix for it? > > My advice would be to rely on pkg-config (a kind of ocamlfind for C > libraries), or similar scripts (pcre-config, etc.) provided by the > libraries. Otherwise, there is no good, portable (I mean, not > Debian-specific) way to guess where a library is, and the packager will > give an explicit path in his call to the configure script in > debian/rules. By the way, this is what we did for ocaml [1]. > > [1] > http://anonscm.debian.org/gitweb/?p=pkg-ocaml-maint/packages/ocaml.git;a=commitdiff;h=1db9b654b7d8b702cddb44df5aea1982f3120883 In GODI there is a library searcher for libs that do not support pkg-config et al. It just tries a list of typical paths used by various OS. The method works well if the library is not dependent on other libraries, and is quite portable. Of course, you cannot be sure to find the right library if several versions are installed (which is quite common on non-open-source OS where the developer has to do it on its own), but otherwise it is good enough for setting a default if the user does not have special wishes. So, e.g. for X11, there is no pkg-config, and GODI falls back to searching. Btw, we don't rely here on what the Ocaml configure script finds out, but have our own searcher, simply because this makes it easier to respect users' wishes. Gerd > > Cheers, > > -- > Stéphane > -- ------------------------------------------------------------ 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 *** Searching for new projects! Need consulting for system *** programming in Ocaml? Gerd Stolpmann can help you. ------------------------------------------------------------