Skip to content

Commit

Permalink
RB-2.5 => RB-2.6 Merge fixes (NatronGitHub#989)
Browse files Browse the repository at this point in the history
* Update README to reflect 2.5 release

* Remove Bountysource from Readme

Bountysource appears to be dead, so it should be removed

* macports update

* Update README.md

* update MacPorts

* Update compiler-common.sh

* Debug build fix

* CMake: Debug build type fix

* Comment out check for debug flag build type. (NatronGitHub#972)

* Fix windows pacman repo build. (NatronGitHub#968)

Msys2 updated gcc in the last few days which has caused the package
repo build to fail. Here are some minor fixes to make the build work
again.

- Add fmt to openimageio's dependency list since the version included
  with the openimageio source now appears to cause an internal compiler
  error.

- Added an include for math.h to in a libsox test file to make the
  compiler stop generating an error about fabs() not being defined.

- Fix type mismatch and missing declaration errors in ImageMagick.

- Updated mingw-w64-dump_syms gitcommit to point to a version that
  fixes a missing header build error.

* Fix Windows build failure caused by missing dependency. (NatronGitHub#969)

Msys2's libcurl package was recently updated to enable HTTP/3
support which means it now also depends on libnghttp3.
genDllVersions.sh was updated to include this new dependency.

The Windows installer build action was also changed to upload its
build artifacts before it tests to make sure the plugins load. This
makes it possible to look at the generated artifacts for missing
dependencies if the plugin load verification fails.

* Fix Windows debug cmake build. (NatronGitHub#973)

- Force Shiboken to use detected python libraries instead of
  using its own library detection logic.
- Specify -O compiler option for debug builds like the qmake build.
- Remove unconditional NDEBUG define added by the Shiboken cmake
  helper so that asserts work correctly on debug builds.

* Add logic to capture/restore existing GL context.

This fixes asserts in debug builds where Qt's GL context is set when
a ScopedGLContext is created. This can happen when we have a project
open and the user tries to open another project. When the event
callback is dispatched, the Qt GL context is still set. The fix
justs removes the assert and adds logic to save and restore any
existing GL context that is set.

* MacPorts update

* Fix rotopaint overlay 2.5 (NatronGitHub#986)

* RotoPaint: always draw the overlay when the tool is part of the overlay

* tools/MacPorts: remove .rej files

---------

Co-authored-by: Marcel Ruegenberg <gh2@picodesign.de>
Co-authored-by: Frédéric Devernay <devernay@users.noreply.github.com>
Co-authored-by: kafxa <148536772+kafxa@users.noreply.github.com>
Co-authored-by: Aaron Colwell <300262+acolwell@users.noreply.github.com>
  • Loading branch information
5 people committed Jul 23, 2024
1 parent b38d9d5 commit eb364b6
Show file tree
Hide file tree
Showing 35 changed files with 1,032 additions and 490 deletions.
32 changes: 29 additions & 3 deletions Engine/RotoPaint.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2727,6 +2727,22 @@ RotoPaint::onOverlayPenMotion(double time,
cursorSet = true;
}

switch (_imp->ui->selectedTool) {
case eRotoToolSolidBrush:
case eRotoToolEraserBrush:
case eRotoToolClone:
case eRotoToolReveal:
case eRotoToolBlur:
case eRotoToolSharpen:
case eRotoToolSmear:
case eRotoToolDodge:
case eRotoToolBurn: {
redraw = true; // Those tools use the overlay to draw the tool
}
default:
break;
} // switch

if ( !cursorSet && _imp->ui->showCpsBbox && (_imp->ui->state != eEventStateDraggingControlPoint) && (_imp->ui->state != eEventStateDraggingSelectedControlPoints)
&& ( _imp->ui->state != eEventStateDraggingLeftTangent) &&
( _imp->ui->state != eEventStateDraggingRightTangent) ) {
Expand All @@ -2751,8 +2767,10 @@ RotoPaint::onOverlayPenMotion(double time,
} else if (lastHoverState != eHoverStateNothing) {
newState = eHoverStateNothing;
}
redraw = _imp->ui->hoverState != newState;
_imp->ui->hoverState = newState;
if (_imp->ui->hoverState != newState) {
redraw = true;
_imp->ui->hoverState = newState;
}
}
const bool featherVisible = _imp->ui->isFeatherVisible();

Expand Down Expand Up @@ -3161,7 +3179,15 @@ RotoPaint::onOverlayPenUp(double /*time*/,
**/
setCurrentCursor(eCursorBusy);
context->evaluateNeatStrokeRender();
setCurrentCursor(eCursorDefault);
if ( context->isRotoPaint() &&
( ( _imp->ui->selectedRole == eRotoRoleMergeBrush) ||
( _imp->ui->selectedRole == eRotoRoleCloneBrush) ||
( _imp->ui->selectedRole == eRotoRolePaintBrush) ||
( _imp->ui->selectedRole == eRotoRoleEffectBrush) ) ) {
setCurrentCursor(eCursorCross);
} else {
setCurrentCursor(eCursorDefault);
}
_imp->ui->strokeBeingPaint->setStrokeFinished();
ret = true;
}
Expand Down
15 changes: 9 additions & 6 deletions config-macports.pri
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
boost {
INCLUDEPATH += /opt/local/include
LIBS += -lboost_serialization-mt
BOOST_VERSION = 1.76
INCLUDEPATH += /opt/local/libexec/boost/$$BOOST_VERSION/include
LIBS += -L/opt/local/libexec/boost/$$BOOST_VERSION/lib -lboost_serialization-mt
}
equals(QT_MAJOR_VERSION, 5) {
shiboken: SHIBOKEN=shiboken2-$$PYVER
Expand All @@ -17,11 +18,13 @@ equals(QT_MAJOR_VERSION, 5) {
}

macx:openmp {
# clang 12+ is OK to build Natron, but libomp 12+ has a bug on macOS when
# lanching tasks from a background thread, see https://bugs.llvm.org/show_bug.cgi?id=50579
# libomp 12+ has a bug on macOS when lanching tasks from a background thread,
# see tools/MacPorts/lang/libomp/README.md
LIBS += -L/opt/local/lib -L/opt/local/lib/libomp -liomp5
QMAKE_CC = /opt/local/bin/clang-mp-15
QMAKE_CXX = /opt/local/bin/clang++-mp-15
# clang 17 and 18 with -fopenmp links with @rpath/libc++.1.dylib instead
# of /usr/lib/libc++.1.dylib, so let's use clang 16 for now.
QMAKE_CC = /opt/local/bin/clang-mp-16
QMAKE_CXX = /opt/local/bin/clang++-mp-16
# Recent clang cannot compile QtMac.mm
QMAKE_OBJECTIVE_CC = clang
QMAKE_OBJECTIVE_CXX = clang++
Expand Down
20 changes: 10 additions & 10 deletions tools/MacPorts/devel/gnutls/Portfile
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ PortGroup legacysupport 1.0
PortGroup muniversal 1.0

name gnutls
version 3.7.10
version 3.7.11
revision 0
categories devel security
# yes, some of the libs are GPL only
Expand All @@ -23,27 +23,27 @@ long_description \
Lesser General Public License (LGPL).
homepage http://www.gnutls.org/

checksums rmd160 e221dc4200d30b8644cfe1f2c8d5e7bccac8aca0 \
sha256 b6e4e8bac3a950a3a1b7bdb0904979d4ab420a81e74de8636dd50b467d36f5a9 \
size 6407852
checksums rmd160 b8a3b948b2cfd504f72e04a31fce31a79b4316b1 \
sha256 90e337504031ef7d3077ab1a52ca8bac9b2f72bc454c95365a1cd1e0e81e06e9 \
size 6406420

subport ${name} {
conflicts ${name}-devel

patchfiles patch-lib-system-certs.c.old.diff
patchfiles patch-lib-system-certs.c.old.diff
}

subport ${name}-devel {
conflicts ${name}

version 3.8.4
version 3.8.6
revision 0

checksums rmd160 42eea662a17b646f78f3dd423200c9d17f9e3943 \
sha256 2bea4e154794f3f00180fa2a5c51fe8b005ac7a31cd58bd44cdfa7f36ebc3a9b \
size 6487520
checksums rmd160 fa7d5faf5359e6de786eacb369b8c4077b15fd99 \
sha256 2e1588aae53cb32d43937f1f4eca28febd9c0c7aa1734fc5dd61a7e81e0ebcdd \
size 6517476

patchfiles patch-lib-system-certs.c.diff
patchfiles patch-lib-system-certs.c.diff
}

if {${build_arch} ne "ppc" || ${build_arch} ne "ppc64"} {
Expand Down
20 changes: 10 additions & 10 deletions tools/MacPorts/devel/gnutls/Portfile.orig
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ PortGroup legacysupport 1.0
PortGroup muniversal 1.0

name gnutls
version 3.7.10
version 3.7.11
revision 0
categories devel security
# yes, some of the libs are GPL only
Expand All @@ -23,27 +23,27 @@ long_description \
Lesser General Public License (LGPL).
homepage http://www.gnutls.org/

checksums rmd160 e221dc4200d30b8644cfe1f2c8d5e7bccac8aca0 \
sha256 b6e4e8bac3a950a3a1b7bdb0904979d4ab420a81e74de8636dd50b467d36f5a9 \
size 6407852
checksums rmd160 b8a3b948b2cfd504f72e04a31fce31a79b4316b1 \
sha256 90e337504031ef7d3077ab1a52ca8bac9b2f72bc454c95365a1cd1e0e81e06e9 \
size 6406420

subport ${name} {
conflicts ${name}-devel

patchfiles patch-lib-system-certs.c.old.diff
patchfiles patch-lib-system-certs.c.old.diff
}

subport ${name}-devel {
conflicts ${name}

version 3.8.4
version 3.8.6
revision 0

checksums rmd160 42eea662a17b646f78f3dd423200c9d17f9e3943 \
sha256 2bea4e154794f3f00180fa2a5c51fe8b005ac7a31cd58bd44cdfa7f36ebc3a9b \
size 6487520
checksums rmd160 fa7d5faf5359e6de786eacb369b8c4077b15fd99 \
sha256 2e1588aae53cb32d43937f1f4eca28febd9c0c7aa1734fc5dd61a7e81e0ebcdd \
size 6517476

patchfiles patch-lib-system-certs.c.diff
patchfiles patch-lib-system-certs.c.diff
}

if {${build_arch} ne "ppc" || ${build_arch} ne "ppc64"} {
Expand Down
18 changes: 13 additions & 5 deletions tools/MacPorts/graphics/ImageMagick/Portfile
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@ legacysupport.newest_darwin_requires_legacy 10
# PHP Warning: Version warning: Imagick was compiled against Image Magick version XXXX but version YYYY is loaded. Imagick will run but may behave surprisingly in Unknown on line 0

name ImageMagick
version 6.9.13-7
version 6.9.13-12
revision 0
checksums rmd160 9025e38a212d8cfe5706f07c4f900a96b708c016 \
sha256 2a521f7992b3dd32469b7b7254a81df8a0045cb0b963372e3ba6404b0a4efeae \
size 9604796
checksums rmd160 b3696f5a09d6a89ee66fd128abb95f83401bca1c \
sha256 cc6189a5999c00f2fb8a0cdd2cddd8207c64bac5146639b8106e56e277c763bf \
size 9617108

categories graphics devel
maintainers {ryandesign @ryandesign}
Expand All @@ -27,7 +27,11 @@ use_xz yes

description Tools and libraries to manipulate images in many formats

long_description ImageMagick is a robust collection of tools and \
long_description This is the legacy ImageMagick version 6. For the \
modern ImageMagick version 7, please go to port \
ImageMagick7. \
\
ImageMagick is a robust collection of tools and \
libraries to create, edit and compose bitmap images \
in a wide variety of formats. You can crop, resize, \
rotate, sharpen, color reduce or add effects or text \
Expand Down Expand Up @@ -109,6 +113,7 @@ configure.args --enable-shared \
--without-rsvg \
--without-lqr \
--without-pango \
--without-raqm \
--without-x \
--without-zstd \
--with-gs-font-dir=${prefix}/share/fonts/urw-fonts \
Expand All @@ -125,6 +130,9 @@ if {${os.platform} eq "darwin" && ${os.major} < 11} {
}
}

# https://trac.macports.org/wiki/WimplicitFunctionDeclaration#strchr
configure.checks.implicit_function_declaration.whitelist-append strchr

variant natron conflicts x11 requires pango rsvg q32 hdri description {Natron version} {
# libc++-based build
# compiler with proper OpenMP support (GCC >= 4.8, clang >= 4.0)
Expand Down
18 changes: 13 additions & 5 deletions tools/MacPorts/graphics/ImageMagick/Portfile.orig
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@ legacysupport.newest_darwin_requires_legacy 10
# PHP Warning: Version warning: Imagick was compiled against Image Magick version XXXX but version YYYY is loaded. Imagick will run but may behave surprisingly in Unknown on line 0

name ImageMagick
version 6.9.13-7
version 6.9.13-12
revision 0
checksums rmd160 9025e38a212d8cfe5706f07c4f900a96b708c016 \
sha256 2a521f7992b3dd32469b7b7254a81df8a0045cb0b963372e3ba6404b0a4efeae \
size 9604796
checksums rmd160 b3696f5a09d6a89ee66fd128abb95f83401bca1c \
sha256 cc6189a5999c00f2fb8a0cdd2cddd8207c64bac5146639b8106e56e277c763bf \
size 9617108

categories graphics devel
maintainers {ryandesign @ryandesign}
Expand All @@ -26,7 +26,11 @@ use_xz yes

description Tools and libraries to manipulate images in many formats

long_description ImageMagick is a robust collection of tools and \
long_description This is the legacy ImageMagick version 6. For the \
modern ImageMagick version 7, please go to port \
ImageMagick7. \
\
ImageMagick is a robust collection of tools and \
libraries to create, edit and compose bitmap images \
in a wide variety of formats. You can crop, resize, \
rotate, sharpen, color reduce or add effects or text \
Expand Down Expand Up @@ -106,6 +110,7 @@ configure.args --enable-shared \
--without-rsvg \
--without-lqr \
--without-pango \
--without-raqm \
--without-x \
--without-zstd \
--with-gs-font-dir=${prefix}/share/fonts/urw-fonts \
Expand All @@ -122,6 +127,9 @@ if {${os.platform} eq "darwin" && ${os.major} < 11} {
}
}

# https://trac.macports.org/wiki/WimplicitFunctionDeclaration#strchr
configure.checks.implicit_function_declaration.whitelist-append strchr

test.run yes
test.target check
test.env DYLD_LIBRARY_PATH=${worksrcpath}/magick/.libs
Expand Down
14 changes: 14 additions & 0 deletions tools/MacPorts/graphics/ImageMagick/files/Color.cpp.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
Avoid using the C++11-specific nullptr.
https://github.com/ImageMagick/ImageMagick6/issues/319
https://github.com/ImageMagick/ImageMagick6/commit/945a51944874548efee9de2370b164cf797ab012
--- Magick++/lib/Color.cpp
+++ Magick++/lib/Color.cpp
@@ -223,7 +223,7 @@ const Magick::Color& Magick::Color::operator=(const std::string &x11color_)
_isValid = false;
_pixelOwn = false;
delete _pixel;
- _pixel = nullptr;
+ _pixel = (PixelPacket *)NULL;
}
ThrowPPException(false);

6 changes: 3 additions & 3 deletions tools/MacPorts/graphics/giflib/Portfile
Original file line number Diff line number Diff line change
Expand Up @@ -40,15 +40,15 @@ use_parallel_build yes
set docdir ${prefix}/share/doc/${name}
post-destroot {
xinstall -d ${destroot}${docdir}
xinstall -W ${worksrcpath} COPYING NEWS README TODO history.adoc ${destroot}${docdir}
xinstall -m 644 {*}[glob ${worksrcpath}/doc/*.1] ${destroot}${prefix}/share/man/man1
xinstall -W ${worksrcpath}-m 0644 COPYING NEWS README TODO history.adoc ${destroot}${docdir}
xinstall -m 0444 {*}[glob ${worksrcpath}/doc/*.1] ${destroot}${prefix}/share/man/man1
}

variant doc description {Install HTML documentation} {
depends_build-append port:xmlto
post-destroot {
xinstall -d ${destroot}${docdir}/html
xinstall -m 644 {*}[glob ${worksrcpath}/doc/*.html] ${destroot}${docdir}/html
xinstall -m 0644 {*}[glob ${worksrcpath}/doc/*.html] ${destroot}${docdir}/html
}
}

Expand Down
58 changes: 58 additions & 0 deletions tools/MacPorts/graphics/giflib/Portfile.orig
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4

PortSystem 1.0

name giflib
version 4.2.3
revision 1
set major [lindex [split ${version} .] 0]
categories graphics
maintainers {ryandesign @ryandesign} openmaintainer
license MIT
homepage https://sourceforge.net/projects/giflib/
master_sites sourceforge:project/giflib/giflib-${major}.x
use_bzip2 yes

description GIF library using patented LZW algorithm

long_description GIF loading and saving shared library. \
Uses the LZW algorithm.

checksums rmd160 34c30ace20155a61446d1561af44e3ad6329b49a \
sha256 0ac8d56726f77c8bc9648c93bbb4d6185d32b15ba7bdb702415990f96f3cb766 \
size 560968

patchfiles patch-gif_lib.h.diff \
patch-lib-gif_hash.c.diff

configure.args --disable-x11

use_parallel_build yes

set docdir ${prefix}/share/doc/${name}
post-destroot {
xinstall -d ${destroot}${docdir}
xinstall -W ${worksrcpath} -m 0644 AUTHORS BUGS COPYING NEWS README TODO api.txt history.txt ${destroot}${docdir}
xinstall -m 0444 {*}[glob ${worksrcpath}/doc/*.1] ${destroot}${prefix}/share/man/man1
}

variant doc description {Install HTML documentation} {
depends_build-append port:xmlto
post-destroot {
xinstall -d ${destroot}${docdir}/html
xinstall -m 0644 {*}[glob ${worksrcpath}/doc/*.html] ${destroot}${docdir}/html
}
}

if {![variant_isset doc]} {
patchfiles-append patch-no-docs.diff
}

variant x11 description {Include gif2x11 tool for displaying GIF files in an X window} {
depends_lib-append port:xorg-libsm \
port:xorg-libX11

configure.args-delete --disable-x11
}

livecheck.regex /${name}-(${major}\\.\[0-9.\]+)${extract.suffix}
Loading

0 comments on commit eb364b6

Please sign in to comment.