Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 28 Aug 2019 19:24:52 +0000 (UTC)
From:      Piotr Kubaj <pkubaj@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r510094 - in head/graphics/photoflow: . files
Message-ID:  <201908281924.x7SJOq1j034438@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: pkubaj
Date: Wed Aug 28 19:24:51 2019
New Revision: 510094
URL: https://svnweb.freebsd.org/changeset/ports/510094

Log:
  graphics/photoflow: fix build on GCC architectures, don't optimize for builder CPU
  
  This port passes -march flags which are bad for users using packages.
  
  Also merge https://github.com/aferrero2707/PhotoFlow/commit/0c79ee254eab9e4a44c7aeca9e43dc7990f14dd8#diff-2d5c4ed90f403ec79d56bb0af37dac07 and https://github.com/aferrero2707/PhotoFlow/commit/84c19b68d7a38dcf4877e7762303fb1841f33d3b#diff-2d5c4ed90f403ec79d56bb0af37dac07 for compatibility with GCC 9.
  
  PR:		239833
  Approved by:	yuri (maintainer), linimon (mentor)
  Differential Revision:	https://reviews.freebsd.org/D21285

Added:
  head/graphics/photoflow/files/patch-src_external_rawspeed_src_librawspeed_common_Mutex.h   (contents, props changed)
Modified:
  head/graphics/photoflow/Makefile
  head/graphics/photoflow/files/patch-src_CMakeLists.txt

Modified: head/graphics/photoflow/Makefile
==============================================================================
--- head/graphics/photoflow/Makefile	Wed Aug 28 19:23:10 2019	(r510093)
+++ head/graphics/photoflow/Makefile	Wed Aug 28 19:24:51 2019	(r510094)
@@ -29,6 +29,10 @@ GH_TAGNAME=	da84a071
 USE_GNOME=	atkmm cairomm glib20 glibmm gtk20 gtkmm24 libsigc++20 pangomm
 
 CMAKE_OFF=	BUNDLED_LENSFUN
+#Disable optimization for the builder CPU when building official packages
+.if defined(PACKAGE_BUILDING)
+CMAKE_ON=	BINARY_PACKAGE_BUILD
+.endif
 
 LDFLAGS+=	-lexecinfo
 

Modified: head/graphics/photoflow/files/patch-src_CMakeLists.txt
==============================================================================
--- head/graphics/photoflow/files/patch-src_CMakeLists.txt	Wed Aug 28 19:23:10 2019	(r510093)
+++ head/graphics/photoflow/files/patch-src_CMakeLists.txt	Wed Aug 28 19:24:51 2019	(r510094)
@@ -5,7 +5,7 @@
    #SET(GMIC_FLAGS "-Wno-error=c++11-narrowing -Dgmic_build -Dcimg_use_vt100 -Dcimg_use_fftw3 -Dcimg_use_tiff -Dcimg_use_zlib -Dcimg_display=0 -Dcimg_use_fftw3_singlethread -fpermissive")
  ELSE(MINGW)
 -  SET(GMIC_FLAGS "-std=gnu++11 -march=nocona -mno-sse3 -mtune=generic -Wno-error=narrowing -Dgmic_build -Dcimg_use_vt100 -Dgmic_is_parallel -Dcimg_use_fftw3 -Dcimg_use_tiff -Dcimg_use_zlib -Dcimg_display=0 -fno-ipa-sra -fpermissive")
-+  SET(GMIC_FLAGS "-std=gnu++11 -march=nocona -mno-sse3 -mtune=generic -Wno-error=narrowing -Dgmic_build -Dcimg_use_vt100 -Dgmic_is_parallel -Dcimg_use_fftw3 -Dcimg_use_tiff -Dcimg_use_zlib -Dcimg_display=0 -fpermissive")
++  SET(GMIC_FLAGS "-std=gnu++11 -Wno-error=narrowing -Dgmic_build -Dcimg_use_vt100 -Dgmic_is_parallel -Dcimg_use_fftw3 -Dcimg_use_tiff -Dcimg_use_zlib -Dcimg_display=0 -fpermissive")
  ENDIF(MINGW)
  
  set(COMPILE_FLAGS " ${GMIC_FLAGS} -I${CMAKE_SOURCE_DIR}/src/dt -DLIBRAW_NODLL -DINSTALL_PREFIX='\"${INSTALL_PREFIX}\"' ")

Added: head/graphics/photoflow/files/patch-src_external_rawspeed_src_librawspeed_common_Mutex.h
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/graphics/photoflow/files/patch-src_external_rawspeed_src_librawspeed_common_Mutex.h	Wed Aug 28 19:24:51 2019	(r510094)
@@ -0,0 +1,17 @@
+--- src/external/rawspeed/src/librawspeed/common/Mutex.h.orig	2019-08-13 19:14:10 UTC
++++ src/external/rawspeed/src/librawspeed/common/Mutex.h
+@@ -77,12 +77,12 @@ class CAPABILITY("mutex") Mutex final { (public)
+   // Acquire/lock this mutex exclusively.  Only one thread can have exclusive
+   // access at any one time.  Write operations to guarded data require an
+   // exclusive lock.
+-  void __attribute__((const)) Lock() const ACQUIRE() {
++  void Lock() ACQUIRE() {
+     // NOP, since there is no mutex. only here to still check for proper locking
+   }
+ 
+   // Release/unlock an exclusive mutex.
+-  void __attribute__((const)) Unlock() const RELEASE() {
++  void Unlock() RELEASE() {
+     // NOP, since there is no mutex. only here to still check for proper locking
+   }
+ 



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