From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from majordomo@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id OAA22382; Thu, 9 Oct 2003 14:11:25 +0200 (MET DST) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id OAA30949 for ; Thu, 9 Oct 2003 14:11:24 +0200 (MET DST) Received: from jamlikhet.polytechnique.org (b.mx.polytechnique.org [129.104.30.35]) by nez-perce.inria.fr (8.11.1/8.11.1) with ESMTP id h99CBN105465 for ; Thu, 9 Oct 2003 14:11:23 +0200 (MET DST) Received: from alan-schm1p.inria.fr (pool-141-151-23-235.phil.east.verizon.net [141.151.23.235]) by ssl.polytechnique.org (Postfix) with ESMTP id A6C84B732; Thu, 9 Oct 2003 14:11:21 +0200 (CEST) Received: by alan-schm1p.inria.fr (Postfix, from userid 501) id AA5A342AC; Thu, 9 Oct 2003 08:09:18 -0400 (EDT) Date: Thu, 9 Oct 2003 08:09:18 -0400 From: Alan Schmitt To: Sven Luther Cc: caml-list@inria.fr Subject: Re: [Caml-list] static linking and ocaml 3.07 beta 1 Message-ID: <20031009120918.GX9670@alan-schm1p> Mail-Followup-To: Sven Luther , caml-list@inria.fr References: <20030804142916.GV3049@alan-schm1p> <20030806120247.GB2333@roke.freak> <20031008192529.GA10828@iliana> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="McQJJYUzjTUqtsGv" Content-Disposition: inline In-Reply-To: <20031008192529.GA10828@iliana> X-Editor: Vim http://vim.sf.net/ X-Info: http://pauillac.inria.fr/~aschmitt/ X-Operating-System: Linux/2.4.22-10mdk (i686) X-Uptime: 08:06:18 up 5 days, 2:34, 10 users, load average: 0.02, 0.03, 0.01 User-Agent: Mutt/1.5.4i X-Loop: caml-list@inria.fr X-Spam: no; 0.00; caml-list:01 3.07:01 sven:01 luther:01 sven:01 luther:01 michal:01 moskal:01 0400,:01 ocamlopt:01 -static:01 sysconf:01 cmx:01 abort:01 cmx:01 X-Attachments: type="application/pgp-signature" Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk --McQJJYUzjTUqtsGv Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable * Sven Luther (sven.luther@wanadoo.fr) wrote: > On Wed, Aug 06, 2003 at 02:02:47PM +0200, Michal Moskal wrote: > > On Mon, Aug 04, 2003 at 10:29:16AM -0400, Alan Schmitt wrote: > > > I have had the following strange message when doing a static link: > > >=20 > > > ocamlopt unix.cmxa str.cmxa -ccopt -static sysconf.cmx abort.cmx = debug.cmx timeout.cmx bufrw.cmx ftp.cmx config.cmx utils.cmx crypt.cm= x future.cmx timed_events.cmx dns.cmx http.cmx commands.cmx event.cmx= maingrenouille.cmx -o camlgrenouille.static=20 > > > /usr/local/lib/ocaml/libunix.a(getgr.o)(.text+0x10c): In function `un= ix_getgrgid': > > > : Using 'getgrgid' in statically linked applications requires at runt= ime the shared libraries from the glibc version used for linking > >=20 > > You might be better off linking statically everything *except* glibc. > > Executables linked dynamically against given version of glibc will > > mostly run with later versions (but not the other way around). > >=20 >=20 > Mmm, how did you solve this one ? I also get this : >=20 > ocamlopt -I Objets -w p -I +lablgtk2 -ccopt -static -o svenopt > lablgtk.cmxa gtkInit.cmx unix.cmxa date.cmx ... interface.cmx main.cmx > /usr/lib/ocaml/3.07/libunix.a(getgr.o)(.text+0x115): dans la fonction =AB > unix_getgrgid =BB: > : warning: Using 'getgrgid' in statically linked applications requires > at runtime the shared libraries from the glibc version used for linking > /usr/lib/ocaml/3.07/libunix.a(getgr.o)(.text+0xdc): dans la fonction =AB > unix_getgrnam =BB: > : warning: Using 'getgrnam' in statically linked applications requires > at runtime the shared libraries from the glibc version used for linking > /usr/lib/gcc-lib/i486-linux/3.3.2/../../../libgtk-x11-2.0.a(gtkfilesel.o)= (.text+0x6d81): > dans la fonction =AB get_pwdb =BB: > : warning: Using 'getpwent' in statically linked applications requires > at runtime the shared libraries from the glibc version used for linking > /usr/lib/ocaml/3.07/libunix.a(getpw.o)(.text+0x128): dans la fonction =AB > unix_getpwnam =BB: > : warning: Using 'getpwnam' in statically linked applications requires > at runtime the shared libraries from the glibc version used for linking > ... > /usr/lib/gcc-lib/i486-linux/3.3.2/../../../libgtk-x11-2.0.a(gtkplug.o)(.t= ext+0x14c5): > dans la fonction =AB xembed_set_info =BB: > : undefined reference to `XChangeProperty' > /usr/lib/gcc-lib/i486-linux/3.3.2/../../../libgtk-x11-2.0.a(gtksocket.o)(= =2Etext+0x623): > dans la fonction =AB gtk_socket_realize =BB: > : undefined reference to `XGetWindowAttributes' > /usr/lib/gcc-lib/i486-linux/3.3.2/../../../libgtk-x11-2.0.a(gtksocket.o)(= =2Etext+0x657): > dans la fonction =AB gtk_socket_realize =BB: > : undefined reference to `XSelectInput' > /usr/lib/gcc-lib/i486-linux/3.3.2/../../../libgtk-x11-2.0.a(gtksocket.o)(= =2Etext+0x8b9): > dans la fonction =AB gtk_socket_size_request =BB: > : undefined reference to `XGetWMNormalHints' > ... > /usr/lib/gcc-lib/i486-linux/3.3.2/../../../libpangox-1.0.a(pangox-fontmap= =2Eo)(.text+0x1db8): > dans la fonction =AB pango_x_fontmap_atom_from_name =BB: > : undefined reference to `XInternAtom' > /usr/lib/gcc-lib/i486-linux/3.3.2/../../../libpangox-1.0.a(pangox-fontmap= =2Eo)(.text+0x1e20): > dans la fonction =AB pango_x_fontmap_name_from_atom =BB: > : undefined reference to `XGetAtomName' > /usr/lib/gcc-lib/i486-linux/3.3.2/../../../libpangox-1.0.a(pangox-fontmap= =2Eo)(.text+0x1e35): > dans la fonction =AB pango_x_fontmap_name_from_atom =BB: > : undefined reference to `XFree' > collect2: ld a retourn=E9 1 code d'=E9tat d'ex=E9cution > Error during linking > make: *** [svenopt] Erreur 2 I think there are two things here: the first glibc warnings are just warnings, and I have distributed binaries built with these warnings with no problem. However you seem to be missing XFree86-static-devel (or static-libs, I don't really know how it is under debian, for Mandrake it's libxfree86-static-devel) Alan Schmitt --=20 The hacker: someone who figured things out and made something cool happen. --McQJJYUzjTUqtsGv Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.3 (GNU/Linux) iD8DBQE/hU/uNIAqM4hFUWgRAoYxAJ9siuWWECpT3w0+YY1PjO8fs8Z+FQCfanWn YhbliyOnK7AkV2mO0Bxcer8= =W6U2 -----END PGP SIGNATURE----- --McQJJYUzjTUqtsGv-- ------------------- 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