From a395f9e31b0b01ac29205c0df35e86ed1bae3f17 Mon Sep 17 00:00:00 2001 From: Carlo Cabrera <30379873+carlocab@users.noreply.github.com> Date: Tue, 6 Jun 2023 22:55:12 +0800 Subject: [PATCH] opencv@3: fix build failure on Linux Follow-up to #131405. --- Formula/opencv@3.rb | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Formula/opencv@3.rb b/Formula/opencv@3.rb index 5c5e10e07448c..45ef91df6896c 100644 --- a/Formula/opencv@3.rb +++ b/Formula/opencv@3.rb @@ -116,6 +116,9 @@ def install args << "-DENABLE_SSE41=OFF" << "-DENABLE_SSE42=OFF" unless MacOS.version.requires_sse42? end + # error: ‘...’ has virtual functions and accessible non-virtual destructor [-Werror=non-virtual-dtor] + ENV.append_to_cflags "-Wno-non-virtual-dtor" if OS.linux? + system "cmake", "-S", ".", "-B", "build_shared", *args inreplace "build_shared/modules/core/version_string.inc", "#{Superenv.shims_path}/", "" system "cmake", "--build", "build_shared"