From debbugs-submit-bounces@debbugs.gnu.org Mon May 24 15:43:42 2021 Received: (at submit) by debbugs.gnu.org; 24 May 2021 19:43:42 +0000 Received: from localhost ([127.0.0.1]:43914 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1llGUA-0006ke-6S for submit@debbugs.gnu.org; Mon, 24 May 2021 15:43:42 -0400 Received: from lists.gnu.org ([209.51.188.17]:36526) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1llGU5-0006kU-E6 for submit@debbugs.gnu.org; Mon, 24 May 2021 15:43:33 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:55708) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1llGU5-00081S-53 for guix-patches@gnu.org; Mon, 24 May 2021 15:43:29 -0400 Received: from mout0.freenet.de ([2001:748:100:40::2:2]:35658) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_CHACHA20_POLY1305:256) (Exim 4.90_1) (envelope-from ) id 1llGU0-0002EL-Ff for guix-patches@gnu.org; Mon, 24 May 2021 15:43:28 -0400 Received: from [195.4.92.122] (helo=sub3.freenet.de) by mout0.freenet.de with esmtpa (ID t_w_@01019freenet.de) (port 25) (Exim 4.92 #3) id 1llGTs-0006aq-RO for guix-patches@gnu.org; Mon, 24 May 2021 21:43:16 +0200 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=freenet.de; s=mjaymdexmjqk; h=Content-Transfer-Encoding:Content-Type:MIME-Version: Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=1RJq+bHOlowhOCfVZWIYsSS5rUx1PqbUk9yPcZGxzT0=; b=K8KbnEHTsLPEubvwzsE1OKgNA+ OK3E887YfhkXgO/9PlhHQkFIV1UWkos+Mlo8czGQvz0LJjvww/SVzL4cnnYWh1QrFd65lbL71tno0 WvXnz0tB/l+dBjjU/cOHWKJUaDgNuGH9mf1vO0EASdsrRe5q3iUSnAe834Y4SPB1ZCsEdyY8CwcFW rcj/1+1DO4CeHNrTynOf0x76MOfWmFJSb8C8Kkud7cUjV4H387ueUvFEJp2gEv4Kht0eBsTWXvYK+ uTdjqqgAZBRhQexvzsQYezqJsDq6EVHuY7NYEMSWzRdHOXZsXXwsRDKdyYDG8en5rD1b4r2LL7TyV kvYcMWCA==; Received: from p200300e4f7192600ce8f2f26bcfad4db.dip0.t-ipconnect.de ([2003:e4:f719:2600:ce8f:2f26:bcfa:d4db]:40918 helo=tango.fritz.box) by sub3.freenet.de with esmtpsa (ID t_w_@01019freenet.de) (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (port 465) (Exim 4.92 #3) id 1llGTs-0001if-Nn; Mon, 24 May 2021 21:43:16 +0200 From: Thorsten Wilms To: guix-patches@gnu.org Subject: [PATCH] gnu: Add eq10q. * gnu/packages/audio.scm (eq10q): New variable. * gnu/packages/patches/eq10q-lv2-descriptor.patch. * gnu/packages/patches/eq10q-exp10.patch. Date: Mon, 24 May 2021 21:43:10 +0200 Message-Id: <20210524194310.13378-1-t_w_@freenet.de> X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Originated-At: 2003:e4:f719:2600:ce8f:2f26:bcfa:d4db!40918 X-FNSign: v=2 s=D98F2316EF9B19ACA1235C0616EEB9E307DF720572AB1304B9030A711385D59E X-Scan-TS: Mon, 24 May 2021 21:43:16 +0200 Received-SPF: pass client-ip=2001:748:100:40::2:2; envelope-from=prvs=07787866bc=t_w_@freenet.de; helo=mout0.freenet.de X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 0.6 (/) X-Debbugs-Envelope-To: submit Cc: Thorsten Wilms X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.0 (/) --- gnu/packages/audio.scm | 44 ++++++++++- gnu/packages/patches/eq10q-exp10.patch | 73 +++++++++++++++++++ .../patches/eq10q-lv2-descriptor.patch | 50 +++++++++++++ 3 files changed, 166 insertions(+), 1 deletion(-) create mode 100644 gnu/packages/patches/eq10q-exp10.patch create mode 100644 gnu/packages/patches/eq10q-lv2-descriptor.patch diff --git a/gnu/packages/audio.scm b/gnu/packages/audio.scm index 2afb37175d..4a40242204 100644 --- a/gnu/packages/audio.scm +++ b/gnu/packages/audio.scm @@ -15,7 +15,7 @@ ;;; Copyright © 2018 Clément Lassieur ;;; Copyright © 2018 Brett Gilio ;;; Copyright © 2018, 2019 Marius Bakke -;;; Copyright © 2018 Thorsten Wilms +;;; Copyright © 2018, 2021 Thorsten Wilms ;;; Copyright © 2018 Eric Bavier ;;; Copyright © 2018 Brendan Tildesley ;;; Copyright © 2019, 2021 Pierre Langlois @@ -5220,3 +5220,45 @@ while still staying in time.") (description "Butt is a tool to stream audio to a ShoutCast or Icecast server.") (license license:gpl2+))) + +(define-public eq10q + (package + (name "eq10q") + (version "2.2") + (source (origin + (method url-fetch) + (uri (string-append "mirror://sourceforge/eq10q/eq10q-" + version ".tar.gz")) + (sha256 + (base32 + "16mhcav8gwkp29k9ki4dlkajlcgh1i2wvldabxb046d37dq4qzrk")) + (patches + (search-patches "eq10q-lv2-descriptor.patch" + "eq10q-exp10.patch")))) + (build-system cmake-build-system) + (arguments + `(#:tests? #f ; No target + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'override-target-directory + (lambda* (#:key outputs #:allow-other-keys) + (substitute* (find-files "CMakeLists.txt") + (("/usr/local")(assoc-ref outputs "out"))) + #t))))) + (inputs + `(("gtkmm" ,gtkmm-2) + ("lv2" ,lv2) + ("fftw" ,fftw))) + (native-inputs + `(("pkg-config" ,pkg-config))) + (native-search-paths + (list (search-path-specification + (variable "LV2_PATH") + (files '("lib/lv2"))))) + (home-page "http://eq10q.sourceforge.net") + (synopsis "Audio plug-in pack for LV2") + (description + "EQ10Q is an audio plug-in pack for LV2. It contains equalizers with 1, 4, +6 or 10 bands, all in mono and stereo variants. Plus a noise-gate, compressor, +bass-booster and stereo-mode converters.") + (license (list license:gpl3+ license:gpl3+)))) diff --git a/gnu/packages/patches/eq10q-exp10.patch b/gnu/packages/patches/eq10q-exp10.patch new file mode 100644 index 0000000000..678009a700 --- /dev/null +++ b/gnu/packages/patches/eq10q-exp10.patch @@ -0,0 +1,73 @@ +Fix "‘pow10’ was not declared in this scope" error. +Taken from https://build.opensuse.org/package/view_file/home:geekositalia:daw/lv2-EQ10Q-plugins/lv2-EQ10Q-plugins-exp10.patch?expand=1 + +diff -rupN eq10q-2.2.org/gui/widgets/bandctl.cpp eq10q-2.2/gui/widgets/bandctl.cpp +--- eq10q-2.2.org/gui/widgets/bandctl.cpp 2016-12-11 07:07:50.000000000 -0500 ++++ eq10q-2.2/gui/widgets/bandctl.cpp 2018-03-10 16:29:14.026996405 -0500 +@@ -949,7 +949,7 @@ bool BandCtl::parseBtnString(BandCtl::Bu + if(str_k.length() > 0) + { + val_k = atof(str_k.c_str()) * 1e3; +- val *= pow10(3.0 - str.length()); ++ val *= exp10(3.0 - str.length()); + if(str.length() > 3) + { + //throw an error, imposible to match str > 3 with k +@@ -960,7 +960,7 @@ bool BandCtl::parseBtnString(BandCtl::Bu + } + if(str_d.length() > 0) + { +- val_d = atof(str_d.c_str())/ pow10((double)str_d.length()); ++ val_d = atof(str_d.c_str())/ exp10((double)str_d.length()); + } + + btn->value = val + val_k + val_d; +diff -rupN eq10q-2.2.org/gui/widgets/bodeplot.cpp eq10q-2.2/gui/widgets/bodeplot.cpp +--- eq10q-2.2.org/gui/widgets/bodeplot.cpp 2016-12-11 07:07:50.000000000 -0500 ++++ eq10q-2.2/gui/widgets/bodeplot.cpp 2018-03-10 16:27:06.222494049 -0500 +@@ -194,14 +194,14 @@ void PlotEQCurve::resetCenterSpan() + { + //Compute center and span for the full range spectrum + double sp = log10(MAX_FREQ/MIN_FREQ); +- double cn = MIN_FREQ * sqrt(pow10(sp)); ++ double cn = MIN_FREQ * sqrt(exp10(sp)); + setCenterSpan(cn, sp); + } + + void PlotEQCurve::setCenterSpan(double center, double span) + { +- m_minFreq = center / sqrt(pow10(span)); +- m_maxFreq = center * sqrt(pow10(span)); ++ m_minFreq = center / sqrt(exp10(span)); ++ m_maxFreq = center * sqrt(exp10(span)); + + //Initalize the grid + const double f_grid[GRID_VERTICAL_LINES] = {20.0, 30.0, 40.0, 50.0, 60.0, 70.0, 80.0, 90.0, +@@ -246,8 +246,8 @@ void PlotEQCurve::setCenter(double cente + { + //Limit center to the possible range according the current span + double sp = log10(m_maxFreq/m_minFreq); +- double cmin = MIN_FREQ * sqrt(pow10(sp)); +- double cmax = MAX_FREQ / sqrt(pow10(sp)); ++ double cmin = MIN_FREQ * sqrt(exp10(sp)); ++ double cmax = MAX_FREQ / sqrt(exp10(sp)); + + double cn = center; + cn = cn > cmax ? cmax : cn; +@@ -259,7 +259,7 @@ void PlotEQCurve::setSpan(double span) + { + //Limit center to the possible range according the current span + double sp_act = log10(m_maxFreq/m_minFreq); +- double cn = m_minFreq * sqrt(pow10(sp_act)); ++ double cn = m_minFreq * sqrt(exp10(sp_act)); + double smax1 = 2.0*log10(cn/MIN_FREQ); + double smax2= 2.0*log10(MAX_FREQ/cn); + double smax = smax1 < smax2 ? smax1 : smax2; +@@ -306,7 +306,7 @@ void PlotEQCurve::recomputeCenterFreq(do + double fmax = MIN_FREQ*pow((MAX_FREQ/MIN_FREQ),((local_x2 + 3.5)/((double)m_zoom_surface_ptr->get_width()))); + + double sp_act = log10(fmax/fmin); +- double cn = fmin * sqrt(pow10(sp_act)); ++ double cn = fmin * sqrt(exp10(sp_act)); + setCenter(cn); + } diff --git a/gnu/packages/patches/eq10q-lv2-descriptor.patch b/gnu/packages/patches/eq10q-lv2-descriptor.patch new file mode 100644 index 0000000000..aabd078356 --- /dev/null +++ b/gnu/packages/patches/eq10q-lv2-descriptor.patch @@ -0,0 +1,50 @@ +Replace _LV2UI_Descriptor with LV2UI_Descriptor + +diff -rupN eq10q-2.2_original/gui/bassup_ui.cpp eq10q-2.2_patched/gui/bassup_ui.cpp +--- eq10q-2.2_original/gui/bassup_ui.cpp 2016-12-11 13:07:52.000000000 +0100 ++++ eq10q-2.2_patched/gui/bassup_ui.cpp 2021-05-24 19:24:34.363536592 +0200 +@@ -38,7 +38,7 @@ using namespace std; + #define BASSUP_GUI_URI "http://eq10q.sourceforge.net/bassup/gui" + + +-static LV2UI_Handle instantiateBassUp_gui(const _LV2UI_Descriptor *descriptor, const char *plugin_uri, const char *bundle_path, LV2UI_Write_Function write_function, LV2UI_Controller controller, LV2UI_Widget *widget, const LV2_Feature *const *features) ++static LV2UI_Handle instantiateBassUp_gui(const LV2UI_Descriptor *descriptor, const char *plugin_uri, const char *bundle_path, LV2UI_Write_Function write_function, LV2UI_Controller controller, LV2UI_Widget *widget, const LV2_Feature *const *features) + { + #ifdef TESTING_EQ10Q + cout<<"instantiateEq10q_gui Entring... "; +diff -rupN eq10q-2.2_original/gui/dyn_ui.cpp eq10q-2.2_patched/gui/dyn_ui.cpp +--- eq10q-2.2_original/gui/dyn_ui.cpp 2016-12-11 13:07:50.000000000 +0100 ++++ eq10q-2.2_patched/gui/dyn_ui.cpp 2021-05-24 19:24:34.363536592 +0200 +@@ -37,7 +37,7 @@ This plugin is inside the Sapista Plugin + using namespace std; + #endif + +-static LV2UI_Handle instantiateDyn_gui(const _LV2UI_Descriptor *descriptor, const char *plugin_uri, const char *bundle_path, LV2UI_Write_Function write_function, LV2UI_Controller controller, LV2UI_Widget *widget, const LV2_Feature *const *features) ++static LV2UI_Handle instantiateDyn_gui(const LV2UI_Descriptor *descriptor, const char *plugin_uri, const char *bundle_path, LV2UI_Write_Function write_function, LV2UI_Controller controller, LV2UI_Widget *widget, const LV2_Feature *const *features) + { + #ifdef TESTING_EQ10Q + cout<<"instantiateDyn_gui Entring... "; +diff -rupN eq10q-2.2_original/gui/eq10q_ui.cpp eq10q-2.2_patched/gui/eq10q_ui.cpp +--- eq10q-2.2_original/gui/eq10q_ui.cpp 2016-12-11 13:07:50.000000000 +0100 ++++ eq10q-2.2_patched/gui/eq10q_ui.cpp 2021-05-24 19:24:34.363536592 +0200 +@@ -38,7 +38,7 @@ using namespace std; + #endif + + +-static LV2UI_Handle instantiateEq10q_gui(const _LV2UI_Descriptor *descriptor, const char *plugin_uri, const char *bundle_path, LV2UI_Write_Function write_function, LV2UI_Controller controller, LV2UI_Widget *widget, const LV2_Feature *const *features) ++static LV2UI_Handle instantiateEq10q_gui(const LV2UI_Descriptor *descriptor, const char *plugin_uri, const char *bundle_path, LV2UI_Write_Function write_function, LV2UI_Controller controller, LV2UI_Widget *widget, const LV2_Feature *const *features) + { + #ifdef TESTING_EQ10Q + cout<<"instantiateEq10q_gui Entring... "; +diff -rupN eq10q-2.2_original/gui/midside_ui.cpp eq10q-2.2_patched/gui/midside_ui.cpp +--- eq10q-2.2_original/gui/midside_ui.cpp 2016-12-11 13:07:53.000000000 +0100 ++++ eq10q-2.2_patched/gui/midside_ui.cpp 2021-05-24 19:24:34.367536562 +0200 +@@ -37,7 +37,7 @@ This plugin is inside the Sapista Plugin + using namespace std; + #endif + +-static LV2UI_Handle instantiateMidSide_gui(const _LV2UI_Descriptor *descriptor, const char *plugin_uri, const char *bundle_path, LV2UI_Write_Function write_function, LV2UI_Controller controller, LV2UI_Widget *widget, const LV2_Feature *const *features) ++static LV2UI_Handle instantiateMidSide_gui(const LV2UI_Descriptor *descriptor, const char *plugin_uri, const char *bundle_path, LV2UI_Write_Function write_function, LV2UI_Controller controller, LV2UI_Widget *widget, const LV2_Feature *const *features) + { + #ifdef TESTING_EQ10Q + cout<<"instantiateEq10q_gui Entring... "; -- 2.31.1