From owner-svn-ports-all@freebsd.org Sat Jan 28 18:22:32 2017 Return-Path: Delivered-To: svn-ports-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 98EDFCC5F44; Sat, 28 Jan 2017 18:22:32 +0000 (UTC) (envelope-from mandree@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 5B624C8B; Sat, 28 Jan 2017 18:22:32 +0000 (UTC) (envelope-from mandree@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v0SIMVOG015613; Sat, 28 Jan 2017 18:22:31 GMT (envelope-from mandree@FreeBSD.org) Received: (from mandree@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v0SIMVBZ015612; Sat, 28 Jan 2017 18:22:31 GMT (envelope-from mandree@FreeBSD.org) Message-Id: <201701281822.v0SIMVBZ015612@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: mandree set sender to mandree@FreeBSD.org using -f From: Matthias Andree Date: Sat, 28 Jan 2017 18:22:31 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r432640 - head/graphics/rawtherapee-devel X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: SVN commit messages for the ports tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 28 Jan 2017 18:22:32 -0000 Author: mandree Date: Sat Jan 28 18:22:31 2017 New Revision: 432640 URL: https://svnweb.freebsd.org/changeset/ports/432640 Log: Fix i386 SSE2 crashes (use clang), and clean up a bit. GCC 5.4 also does not get the stack properly aligned in i386 for SSE2 and causes SIGBUS on startup when trying to access an 8-byte aligned double[8] array with SIMD instructions.[1] One workaround would be to use -mstackrealign, the other is to use clang - we don't get OpenMP on i386 anyhow. Move DISTVERSIONSUFFIX up to appease portlint. Drop -fexpensive-optimizations, clang does not support it, and gcc 5.4 includes it in -O2 and -O3. Note that the upstream discourages the use of 32-bit architectures for rawtherapee. Reported by: pkg-fallout@ [1] Modified: head/graphics/rawtherapee-devel/Makefile Modified: head/graphics/rawtherapee-devel/Makefile ============================================================================== --- head/graphics/rawtherapee-devel/Makefile Sat Jan 28 18:15:23 2017 (r432639) +++ head/graphics/rawtherapee-devel/Makefile Sat Jan 28 18:22:31 2017 (r432640) @@ -3,10 +3,10 @@ PORTNAME= rawtherapee PORTVERSION= 5.0 +DISTVERSIONSUFFIX= -gtk3 PORTREVISION= 0 CATEGORIES= graphics MASTER_SITES= http://rawtherapee.com/shared/source/ -DISTVERSIONSUFFIX= -gtk3 PKGNAMESUFFIX= -devel MAINTAINER= mandree@FreeBSD.org @@ -27,7 +27,7 @@ LIB_DEPENDS= libcanberra-gtk.so:audio/li libsigc-2.0.so:devel/libsigc++20 \ libtiff.so:graphics/tiff -USES= cmake:outsource compiler:gcc-c++11-lib desktop-file-utils dos2unix \ +USES= cmake:outsource desktop-file-utils dos2unix \ jpeg localbase:ldflags pkgconfig tar:xz DOS2UNIX_REGEX= .*\.(cc|h) LDFLAGS+= -Wl,--as-needed # fontconfig, freetype, gettext, libX11 @@ -68,9 +68,8 @@ NATIVE_DESC= Use -march=native for comp OPENMP_CMAKE_BOOL= OPTION_OMP -OPTIMIZED_CFLAGS_CFLAGS= -O3 -funroll-loops -msse2 \ - ${OPTIMIZED_CFLAGS_CFLAGS_${CHOSEN_COMPILER_TYPE}} -OPTIMIZED_CFLAGS_CFLAGS_gcc= -fexpensive-optimizations +OPTIMIZED_CFLAGS_CFLAGS= -O3 -funroll-loops -msse2 +# GCC 5.4 includes -fexpensive-optimizations in -O2 already .include @@ -92,14 +91,27 @@ CMAKE_BUILD_TYPE= RelWithDebInfo STRIP= .endif +.if ${ARCH} == i386 +USES+= compiler:c++11-lib +# FIXME: if we were to use GCC on i386, we'd need to use -mstackrealign +# or similar options, else we get SIGBUS when SSE2 is enabled due to +# improper alignment. Base clang is good enough though, i386 does not +# support OpenMP, and those seeking ultimate performance need to use +# amd64. +.else +USES+= compiler:gcc-c++11-lib +.endif + # ------------------------------------------------------------------- .include +.if ${CHOSEN_COMPILER_TYPE} == gcc # Workaround: this needs to be late because Mk/Uses/compiler.mk tramples # over previously set values with gcc-libc++-configure as of r432539. # GCC 4.9 doesn't generate usable code on FreeBSD 11.0. USE_GCC= 5+ +.endif post-patch: @${REINPLACE_CMD} -e 's#DESTINATION "$${CMAKE_INSTALL_PREFIX}/share/man/man1"#DESTINATION "${MANPREFIX}/man/man1/"#' \