On 2017/07/24 17:40, Vadim Zhukov wrote:
> This synfig at run-time, unbreaking (at least) synfigstudio build.
> 
> I'm not skilled enough to find the root cause quickly, but this at least
> allows bulk builds to continue. According to espie@, building with clang
> doesn't result in such problems.
> 
> Okay? Or should it better to drop the DEBUG-related chunk? The reason
> for it is that configure script replaces -O* in CXXFLAGS with value
> coming from --enable-optimization; if there was none, it "autodetects".

I'm not a fan of "hiding" -O1 behind "--enable-optimization=1",
what do you think about this instead?

(It would be better with a comment explaining why -O1, but I don't
understand the problem enough to write one..)

Index: Makefile
===================================================================
RCS file: /cvs/ports/multimedia/synfig/Makefile,v
retrieving revision 1.14
diff -u -p -r1.14 Makefile
--- Makefile    23 Jul 2017 10:49:37 -0000      1.14
+++ Makefile    24 Jul 2017 15:31:44 -0000
@@ -1,7 +1,7 @@
 # $OpenBSD: Makefile,v 1.14 2017/07/23 10:49:37 zhuk Exp $
 
 COMMENT =              2D animation software
-REVISION =             4
+REVISION =             5
 
 V=                     1.0.1
 DISTNAME =             synfig-$V
@@ -45,10 +45,11 @@ LIB_DEPENDS =               archivers/xz \
                        multimedia/mlt \
                        textproc/libxml++
 
+CXXFLAGS+=             -O1 -std=c++11
 CONFIGURE_ENV =                CPPFLAGS="-I${LOCALBASE}/include" \
-                       CXXFLAGS="-std=c++11" \
                        LDFLAGS="-L${LOCALBASE}/lib"
-CONFIGURE_STYLE =      gnu
+CONFIGURE_STYLE =      autoconf
+AUTOCONF_VERSION =     2.69
 CONFIGURE_ARGS =       --without-included-ltdl
 
 FAKE_FLAGS =           sysconfdir=${PREFIX}/share/examples/synfig
Index: patches/patch-configure_ac
===================================================================
RCS file: patches/patch-configure_ac
diff -N patches/patch-configure_ac
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ patches/patch-configure_ac  24 Jul 2017 15:31:44 -0000
@@ -0,0 +1,15 @@
+$OpenBSD$
+
+Don't override CXXFLAGS optimisation levels.
+
+Index: configure.ac
+--- configure.ac.orig
++++ configure.ac
+@@ -46,7 +46,6 @@ AC_C_BIGENDIAN
+ 
+ # -- A R G U M E N T S ----------------------------------------
+ 
+-AC_ARG_OPTIMIZATION
+ AC_ARG_DEBUG
+ AC_ARG_WARNINGS
+ AC_ARG_PROFILING

Reply via email to