Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 25 Nov 2010 10:49:42 +0300
From:      Anonymous <swell.k@gmail.com>
To:        Alexander Best <arundel@freebsd.org>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: libm alternative in ports
Message-ID:  <86ipzlg7vt.fsf@gmail.com>
In-Reply-To: <20101123210013.GA71784@freebsd.org> (Alexander Best's message of "Tue, 23 Nov 2010 21:00:13 %2B0000")
References:  <20101123210013.GA71784@freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Alexander Best <arundel@freebsd.org> writes:

> hi there,
>
> does anybody if there's an alternative for libm in the ports dir? i need it,
> because the newest snapshots of mplayer require log2() and log2f(), which the
> base libm doesn't support.

for mplayer I'd suggest using code from x264 because both projects use GPLv2+

  #if !HAVE_LOG2F
  #define log2f(x) (logf(x)/0.693147180559945f)
  #define log2(x) (log(x)/0.693147180559945)
  #endif



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?86ipzlg7vt.fsf>