From owner-freebsd-current Tue Sep 1 21:19:27 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id VAA00994 for freebsd-current-outgoing; Tue, 1 Sep 1998 21:19:27 -0700 (PDT) (envelope-from owner-freebsd-current@FreeBSD.ORG) Received: from austin.polstra.com (austin.polstra.com [206.213.73.10]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id VAA00989 for ; Tue, 1 Sep 1998 21:19:26 -0700 (PDT) (envelope-from jdp@austin.polstra.com) Received: from austin.polstra.com (jdp@localhost) by austin.polstra.com (8.8.8/8.8.8) with ESMTP id VAA17950; Tue, 1 Sep 1998 21:18:23 -0700 (PDT) (envelope-from jdp) Message-Id: <199809020418.VAA17950@austin.polstra.com> To: tlambert@primenet.com Subject: Re: XFree86 and ELF In-Reply-To: <199809020127.SAA12927@usr01.primenet.com> References: <199809020127.SAA12927@usr01.primenet.com> Organization: Polstra & Co., Seattle, WA Cc: current@FreeBSD.ORG Date: Tue, 01 Sep 1998 21:18:23 -0700 From: John Polstra Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG In article <199809020127.SAA12927@usr01.primenet.com>, Terry Lambert wrote: > > This is due to the fact that I am unaware of a portable way to check > > if we're on an ELF system. Bear in mind it might be a prehistoric > > -stable version, so it isn't just a question of `objformat`. > > #!/bin/sh > > echo "Is it ELF yet?" > file `which ld` | grep ELF >/dev/null 2>&1 > if test "$?" = "0" > then > echo "It's ELF, yet!" > else > echo "No, not yet..." > fi What I've been using in ports Makefiles is: OBJFORMAT!= test -x /usr/bin/objformat && /usr/bin/objformat || echo aout John -- John Polstra jdp@polstra.com John D. Polstra & Co., Inc. Seattle, Washington USA "Self-knowledge is always bad news." -- John Barth To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message