From owner-freebsd-questions Mon Jul 1 9:28: 7 2002 Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3AC6937B405 for ; Mon, 1 Jul 2002 09:27:54 -0700 (PDT) Received: from grillolja.cs.umu.se (grillolja.cs.umu.se [130.239.40.17]) by mx1.FreeBSD.org (Postfix) with ESMTP id 89F3F43E09 for ; Mon, 1 Jul 2002 09:27:53 -0700 (PDT) (envelope-from tdv94ped@cs.umu.se) Received: from gren.cs.umu.se (gren.cs.umu.se [130.239.40.187]) (using TLSv1 with cipher EDH-RSA-DES-CBC3-SHA (168/168 bits)) (No client certificate requested) by grillolja.cs.umu.se (Postfix) with ESMTP id 226B29FEA for ; Mon, 1 Jul 2002 18:27:52 +0200 (MEST) Date: Mon, 1 Jul 2002 18:27:51 +0200 (MEST) From: Paul Everlund To: freebsd-questions@freebsd.org Subject: Programming: Static libraries Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi all! Have a programming C question, that is related to FreeBSD. If I have some code that several applications will use I think it would be nice to put this in some kind of archive, then link that code statically into all the applications. (Do not want to use shared libraries.) I did take a look at but don't really know how to use it. I got so far that ranlib lib.a was executed. But how do I use this when compiling my applications, each one using ? What definitions should I use in and to make all this happen? Thank you all in advance! Best regards, Paul To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message