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 q0DFOp1U028664 for ; Fri, 13 Jan 2012 16:24:51 +0100 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: ApACAEFMEE/U4xEJk2dsb2JhbABChRCoCSIBAQEBCQkLCRQDIoFyAQEEASNWBQsLGgImAgJXBhMJh3ECBqVwkT6BL4JOhwqBFgSNJY0+jG8 X-IronPort-AV: E=Sophos;i="4.71,504,1320620400"; d="scan'208";a="126796207" Received: from moutng.kundenserver.de ([212.227.17.9]) by mail4-smtp-sop.national.inria.fr with ESMTP; 13 Jan 2012 16:24:49 +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=mrbap0) with ESMTP (Nemesis) id 0Ld3qq-1STtSj3yme-00iJSx; Fri, 13 Jan 2012 16:22:18 +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 A6026C00CE; Fri, 13 Jan 2012 16:22:17 +0100 (CET) From: Gerd Stolpmann To: Philippe Veber Cc: =?ISO-8859-1?Q?St=E9phane?= Glondu , caml users In-Reply-To: References: <4F102F24.9050000@glondu.net> <1326462965.14288.67.camel@thinkpad> Content-Type: text/plain; charset="UTF-8" Date: Fri, 13 Jan 2012 16:22:22 +0100 Message-ID: <1326468142.14288.82.camel@thinkpad> Mime-Version: 1.0 X-Mailer: Evolution 2.28.3 X-Provags-ID: V02:K0:LFOWfA+M6JuYui5wxwx4NewhnLAfvDkVnaHC8SGgn+g I5Lwd+83+QLGVrE1lsCtoToXAVfXCg8Em0vh9eB50vqEPXOG/1 MEpa7AwZF1pvBs45ZJ1hLQVbLzOumJG8zn7aLuKforF/9K2i3y UdC1c6gKSvaCzkSA5Fw7QktZauyqiDBo9KPpkTmXQx7wOe5sur 7jKCoK6jsz+9AJIQqbZID5y1mVYXgF2qpDqJwWa1vei8pEwTau 5tPCI+wPNhDL7ZakpvPHRDaLdYpiD2Au816969SoJ9StZyUfmH kpNUuFkYNIIwZ2zhtfgNlpri4Fd/GzigFBIy21e0JwqI/8OcBl F4z6txLx2iFmERQ6YPaHwpXmnYkvOAHxT0/4AxyX3 Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from quoted-printable to 8bit by walapai.inria.fr id q0DFOp1U028664 Subject: Re: [Caml-list] Compiling the ocaml distribution under multiarched Debian/Ubuntu Am Freitag, den 13.01.2012, 15:17 +0100 schrieb Philippe Veber: > > > 2012/1/13 Gerd Stolpmann > 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. > 'seems like pkg-config was updated: > > pveber@gesundheit:~/usr/src/ocaml-3.12.1$ pkg-config --libs x11 > -lX11 Traditionally, X11 came with its own system called imake, which is a preprocessor for makefiles. If there is now pkg-config support, this is very new, or an extension by the distributor. Gerd -- ------------------------------------------------------------ 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. ------------------------------------------------------------