From owner-freebsd-ports@FreeBSD.ORG Sat Oct 11 15:59:48 2008 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1E44C106568B for ; Sat, 11 Oct 2008 15:59:48 +0000 (UTC) (envelope-from talon@lpthe.jussieu.fr) Received: from shiva.jussieu.fr (shiva.jussieu.fr [134.157.0.129]) by mx1.freebsd.org (Postfix) with ESMTP id ACC198FC16 for ; Sat, 11 Oct 2008 15:59:47 +0000 (UTC) (envelope-from talon@lpthe.jussieu.fr) Received: from parthe.lpthe.jussieu.fr (parthe.lpthe.jussieu.fr [134.157.10.1]) by shiva.jussieu.fr (8.14.3/jtpda-5.4) with ESMTP id m9BFxj3a042581 ; Sat, 11 Oct 2008 17:59:46 +0200 (CEST) X-Ids: 164 Received: from niobe.lpthe.jussieu.fr (niobe.lpthe.jussieu.fr [134.157.10.41]) by parthe.lpthe.jussieu.fr (Postfix) with ESMTP id 9FE2A8A084; Sat, 11 Oct 2008 17:59:44 +0200 (CEST) Received: by niobe.lpthe.jussieu.fr (Postfix, from userid 2005) id 75ED710A; Sat, 11 Oct 2008 17:59:44 +0200 (CEST) Date: Sat, 11 Oct 2008 17:59:44 +0200 From: Michel Talon To: Sean Winn Message-ID: <20081011155944.GA54404@lpthe.jussieu.fr> References: <20081009122839.GA58927@lpthe.jussieu.fr> <20081011073738.GA38584@lpthe.jussieu.fr> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.3i X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.0 (shiva.jussieu.fr [134.157.0.164]); Sat, 11 Oct 2008 17:59:46 +0200 (CEST) X-Virus-Scanned: ClamAV 0.93.3/8412/Sat Oct 11 14:30:20 2008 on shiva.jussieu.fr X-Virus-Status: Clean X-Miltered: at jchkmail2.jussieu.fr with ID 48F0B174.003 by Joe's j-chkmail (http : // j-chkmail dot ensmp dot fr)! X-j-chkmail-Enveloppe: 48F0B174.003/134.157.10.1/parthe.lpthe.jussieu.fr/parthe.lpthe.jussieu.fr/ X-j-chkmail-Score: MSGID : 48F0B174.003 on jchkmail2.jussieu.fr : j-chkmail score : . : R=. U=. O=. B=0.033 -> S=0.033 X-j-chkmail-Status: Ham Cc: freebsd-ports@freebsd.org Subject: Re: multimedia/xvid X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 11 Oct 2008 15:59:48 -0000 On Sun, Oct 12, 2008 at 12:42:08AM +1100, Sean Winn wrote: > > Another option is to just fix the configure script so it doesn't break on > nasm > 1 (it's failing on the patch level check) > > The attached file dropped in ports/multimedia/xvid/files/ seems to do the > trick, though I don't use xvid so I can't exactly test that the new version > assembles things properly. > > Something done to configure.in should be sent upstream really. Yes, fixing the configure script should be done upstream, but it seems that the xvid project is somewhat asleep, so better use yasm in the Makefile on which there is control. As you note below, the problem comes because the configure script tries to use the -r option which yasm has but not nasm, so the xvid people had really yasm in view when doing their work. > --- configure.orig 2008-10-11 13:40:34.000000000 +1100 > +++ configure 2008-10-11 13:43:14.000000000 +1100 > @@ -4016,7 +4016,12 @@ > if test "$ac_nasm" = "yes" ; then > echo "$as_me:$LINENO: checking for nasm patch version" >&5 > echo $ECHO_N "checking for nasm patch version... $ECHO_C" >&6 > - nasm_patch=`$nasm_prog -r | cut -d '.' -f 3 | cut -d ' ' -f 1` > + nasm_version=`$nasm_prog -v | cut -d '.' -f 1 | cut -d ' ' -f3` > + if test -n "$nasm_version" -a "$nasm_version" -gt 1; then > + nasm_patch=$minimum_nasm_patch_version > + else > + nasm_patch=`$nasm_prog -r | cut -d '.' -f 3 | cut -d ' ' -f 1` > + fi > if test -z $nasm_patch ; then > nasm_patch=-1 > fi By the way, the performance improvement obtained by using SSE instructions in the assembly files is astounding. I could not beleive what i was seeing, basically an x 4 improvement, that is the code perfectly parallelizes the computations on the 128 bits registers. This is a good illustration of the fact that compilers are not always as smart as people say, and assembly code can crush C code. -- Michel TALON