From owner-freebsd-current@FreeBSD.ORG Sat May 30 07:00:13 2009 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 445A3106564A for ; Sat, 30 May 2009 07:00:13 +0000 (UTC) (envelope-from kientzle@freebsd.org) Received: from kientzle.com (kientzle.com [66.166.149.50]) by mx1.freebsd.org (Postfix) with ESMTP id 12BD68FC14 for ; Sat, 30 May 2009 07:00:12 +0000 (UTC) (envelope-from kientzle@freebsd.org) Received: (from root@localhost) by kientzle.com (8.14.3/8.14.3) id n4U70C5v060455; Sat, 30 May 2009 00:00:12 -0700 (PDT) (envelope-from kientzle@freebsd.org) Received: from dark.x.kientzle.com (fw2.kientzle.com [10.123.1.2]) by kientzle.com with SMTP id d7msftxvtdx48igymqntnmza3s; Sat, 30 May 2009 00:00:12 -0700 (PDT) (envelope-from kientzle@freebsd.org) Message-ID: <4A20D97B.1030609@freebsd.org> Date: Sat, 30 May 2009 00:00:11 -0700 From: Tim Kientzle User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.8.1.21) Gecko/20090409 SeaMonkey/1.1.15 MIME-Version: 1.0 To: Mel Flynn References: <57200BF94E69E54880C9BB1AF714BBCB5DE72E@w2003s01.double-l.local> <200904172107.15616.mel.flynn+fbsd.current@mailing.thruhere.net> <49E96E4E.3070206@freebsd.org> <200905291857.34848.mel.flynn+fbsd.current@mailing.thruhere.net> In-Reply-To: <200905291857.34848.mel.flynn+fbsd.current@mailing.thruhere.net> Content-Type: text/plain; charset=windows-1250; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-current@freebsd.org Subject: Re: Linking with libarchive fails (Was: Re: buildworld fails.) X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 May 2009 07:00:13 -0000 Mel Flynn wrote: > > Linking with libarchive now results in: > /usr/local/libexec/ccache/world-cc -O2 -pipe -std=iso9899:1999 -fstack- > protector -Wsystem-headers -Werror -Wall -Wno-format-y2k -W -Wno-unused- > parameter -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Wno- > uninitialized -Wno-pointer-sign -o tardiff tardiff.o -larchive > /usr/lib/libarchive.so: undefined reference to `SHA1_Init' > /usr/lib/libarchive.so: undefined reference to `SHA256_Update' > /usr/lib/libarchive.so: undefined reference to `SHA512_Final' ... omitted many more... > *** Error code 1 > > Stop in /home/mel/cvs/utils/tardiff. > > % cat BSDmakefile > PROG=tardiff > LDADD=-larchive > WARNS=3 > NO_MAN=yes You need: LDADD=-larchive -lmd -lcrypto One of the formats supported by libarchive has recently gained support for some cryptographic extensions which rely on the 'md' and 'crypto' libraries. > (In case you curious types are wondering what tardiff is, it's something I'm > writing at the moment, to figure out why 2 tars are different even though > their TOC is the same and are created from in theory the same source tree). Sounds like exactly the kind of tool that libarchive was created to help support. I'd be happy to include that in the "contrib" examples area of the libarchive portable distribution. Tim