From owner-freebsd-ports@FreeBSD.ORG Sat Mar 31 07:01:59 2012 Return-Path: Delivered-To: ports@FreeBSD.org Received: from mandree.no-ip.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by hub.freebsd.org (Postfix) with ESMTP id 897A5106566C; Sat, 31 Mar 2012 07:01:59 +0000 (UTC) (envelope-from mandree@FreeBSD.org) Received: from [127.0.0.1] (localhost.localdomain [127.0.0.1]) by apollo.emma.line.org (Postfix) with ESMTP id B522623CEAF; Sat, 31 Mar 2012 09:01:58 +0200 (CEST) Message-ID: <4F76ABE6.206@FreeBSD.org> Date: Sat, 31 Mar 2012 09:01:58 +0200 From: Matthias Andree User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.28) Gecko/20120313 Mnenhy/0.8.3 Thunderbird/3.1.20 MIME-Version: 1.0 To: rm@freebsd.org X-Enigmail-Version: 1.1.2 Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: 7bit Cc: ports@FreeBSD.org Subject: rawtherapee 4.0.7 build failure on 9-STABLE amd64 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, 31 Mar 2012 07:01:59 -0000 Ruslan, I cannot build rawtherapee 4.0.7 on 9-STABLE amd64, re-running it after failure with "make MAKE_JOBS_UNSAFE=yes" yields: [ 5%] Building CXX object rtengine/CMakeFiles/rtengine.dir/ipresize.cc.o In file included from /var/tmp/usr/ports/graphics/rawtherapee/work/rawtherapee-4.0.7/rtengine/ipresize.cc:20: /var/tmp/usr/ports/graphics/rawtherapee/work/rawtherapee-4.0.7/rtengine/improcfun.h:21:13: warning: extra tokens at end of #ifndef directive In file included from /usr/include/c++/4.2/cmath:54, from /var/tmp/usr/ports/graphics/rawtherapee/work/rawtherapee-4.0.7/rtengine/../rtexif/rtexif.h:28, from /var/tmp/usr/ports/graphics/rawtherapee/work/rawtherapee-4.0.7/rtengine/rtengine.h:28, from /var/tmp/usr/ports/graphics/rawtherapee/work/rawtherapee-4.0.7/rtengine/imageio.h:30, from /var/tmp/usr/ports/graphics/rawtherapee/work/rawtherapee-4.0.7/rtengine/imagefloat.h:25, from /var/tmp/usr/ports/graphics/rawtherapee/work/rawtherapee-4.0.7/rtengine/improcfun.h:25, from /var/tmp/usr/ports/graphics/rawtherapee/work/rawtherapee-4.0.7/rtengine/ipresize.cc:20: /usr/include/math.h:239: error: expected `)' before '/' token *** Error code 1 math.h line 239 declares "double log2(double);", so I presume that patch-rtengine_improcfun.h proves harmful here; the "#ifndef log2(x)" is bogus if log2 isn't declared as macro (and is actually what breaks the compile), and the macro is #define log2(x) ((log(x)/log(2)). It might be more useful to do this instead: static const double lnOf2 = log(2); static inline double log2(double x) { return log(x)/lnOf2; } or possibly checking math.h for log2() before adding the patch. I'm afraid I won't have the time to do that now; could you? Thanks. Best, Matthias