From 5ccd68e0c3510f5af82c5137f5fd1e945711a621f250f51fa837490b47d2e69f Mon Sep 17 00:00:00 2001 From: Dave Plater Date: Tue, 19 May 2020 10:49:58 +0000 Subject: [PATCH] Accepting request 807192 from home:plater - Update to release 2.4.0 and rebase audacity-no_buildstamp.patch. - Add patch from git: 0001-Bug2436-Cross-project-paste-should-duplicate-block-f.patch - Add plugins sub package. OBS-URL: https://build.opensuse.org/request/show/807192 OBS-URL: https://build.opensuse.org/package/show/multimedia:apps/audacity?expand=0&rev=140 --- ...oject-paste-should-duplicate-block-f.patch | 109 ++++++++++++++++++ Audacity-2.3.3.tar.gz | 3 - Audacity-2.4.0.tar.gz | 3 + audacity-no_buildstamp.patch | 54 ++++----- audacity.changes | 15 +++ audacity.spec | 22 +++- 6 files changed, 171 insertions(+), 35 deletions(-) create mode 100644 0001-Bug2436-Cross-project-paste-should-duplicate-block-f.patch delete mode 100644 Audacity-2.3.3.tar.gz create mode 100644 Audacity-2.4.0.tar.gz diff --git a/0001-Bug2436-Cross-project-paste-should-duplicate-block-f.patch b/0001-Bug2436-Cross-project-paste-should-duplicate-block-f.patch new file mode 100644 index 0000000..236ef12 --- /dev/null +++ b/0001-Bug2436-Cross-project-paste-should-duplicate-block-f.patch @@ -0,0 +1,109 @@ +From 242b7fd7b7a7e4a720706a8bb6cf1d4a17099e2e Mon Sep 17 00:00:00 2001 +From: Paul Licameli +Date: Mon, 18 May 2020 07:53:01 -0400 +Subject: [PATCH] Bug2436: Cross-project paste should duplicate block files... + +... to avoid data loss! + +Bug caused by commit c2feee6 +--- + src/DirManager.cpp | 2 +- + src/WaveTrack.cpp | 4 +++- + src/WaveTrack.h | 3 ++- + src/menus/EditMenus.cpp | 7 +++++-- + 4 files changed, 11 insertions(+), 5 deletions(-) + +diff --git a/src/DirManager.cpp b/src/DirManager.cpp +index 71922a395..5278ce916 100644 +--- a/src/DirManager.cpp ++++ b/src/DirManager.cpp +@@ -400,7 +400,7 @@ DirManager::DirManager() + srand(time(NULL)); + + // Set up local temp subdir +- // Previously, Audacity just named project temp directories "project0", ++ // Previously, Audacity just na med project temp directories "project0", + // "project1" and so on. But with the advent of recovery code, we need a + // unique name even after a crash. So we create a random project index + // and make sure it is not used already. This will not pose any performance +diff --git a/src/WaveTrack.cpp b/src/WaveTrack.cpp +index 9feded420..b4ef344a3 100644 +--- a/src/WaveTrack.cpp ++++ b/src/WaveTrack.cpp +@@ -530,10 +530,12 @@ void WaveTrack::Trim (double t0, double t1) + + + +-WaveTrack::Holder WaveTrack::EmptyCopy() const ++WaveTrack::Holder WaveTrack::EmptyCopy( ++ const std::shared_ptr &pDirManager ) const + { + auto result = std::make_shared( mDirManager, mFormat, mRate ); + result->Init(*this); ++ result->mDirManager = pDirManager ? pDirManager : mDirManager; + return result; + } + +diff --git a/src/WaveTrack.h b/src/WaveTrack.h +index c99f249d8..e870434aa 100644 +--- a/src/WaveTrack.h ++++ b/src/WaveTrack.h +@@ -160,7 +160,8 @@ private: + + // Make another track copying format, rate, color, etc. but containing no + // clips +- Holder EmptyCopy() const; ++ Holder EmptyCopy( ++ const std::shared_ptr &pDirManager = {} ) const; + + // If forClipboard is true, + // and there is no clip at the end time of the selection, then the result +diff --git a/src/menus/EditMenus.cpp b/src/menus/EditMenus.cpp +index 6a4b550e3..6e14f4f7d 100644 +--- a/src/menus/EditMenus.cpp ++++ b/src/menus/EditMenus.cpp +@@ -2,6 +2,7 @@ + #include "../AdornedRulerPanel.h" + #include "../Clipboard.h" + #include "../CommonCommandFlags.h" ++#include "../DirManager.h" + #include "../LabelTrack.h" + #include "../Menus.h" + #include "../NoteTrack.h" +@@ -75,6 +76,7 @@ bool DoPasteText(AudacityProject &project) + bool DoPasteNothingSelected(AudacityProject &project) + { + auto &tracks = TrackList::Get( project ); ++ auto &dirManager = DirManager::Get( project ); + auto &trackFactory = TrackFactory::Get( project ); + auto &selectedRegion = ViewInfo::Get( project ).selectedRegion; + auto &window = ProjectWindow::Get( project ); +@@ -101,7 +103,7 @@ bool DoPasteNothingSelected(AudacityProject &project) + // Cause duplication of block files on disk, when copy is + // between projects + locker.emplace(wc); +- uNewTrack = wc->EmptyCopy(); ++ uNewTrack = wc->EmptyCopy( dirManager.shared_from_this() ); + pNewTrack = uNewTrack.get(); + }, + #ifdef USE_MIDI +@@ -379,6 +381,7 @@ void OnPaste(const CommandContext &context) + { + auto &project = context.project; + auto &tracks = TrackList::Get( project ); ++ auto &dirManager = DirManager::Get( project ); + auto &trackFactory = TrackFactory::Get( project ); + auto &selectedRegion = ViewInfo::Get( project ).selectedRegion; + const auto &settings = ProjectSettings::Get( project ); +@@ -596,7 +599,7 @@ void OnPaste(const CommandContext &context) + wt->ClearAndPaste(t0, t1, wc, true, true); + } + else { +- auto tmp = wt->EmptyCopy(); ++ auto tmp = wt->EmptyCopy( dirManager.shared_from_this() ); + tmp->InsertSilence( 0.0, + // MJS: Is this correct? + clipboard.Duration() ); +-- +2.16.4 + diff --git a/Audacity-2.3.3.tar.gz b/Audacity-2.3.3.tar.gz deleted file mode 100644 index cdf89a4..0000000 --- a/Audacity-2.3.3.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:404e6c49693dedc94212fc5525974058d848536025e19da31359ae02babe8bd7 -size 62073352 diff --git a/Audacity-2.4.0.tar.gz b/Audacity-2.4.0.tar.gz new file mode 100644 index 0000000..f8b2392 --- /dev/null +++ b/Audacity-2.4.0.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5d1c096d7b04ff8d5dbca3dca5b9d9f8e62093b5ea6e57ae5f821ae3132dc88f +size 63934879 diff --git a/audacity-no_buildstamp.patch b/audacity-no_buildstamp.patch index a158e6f..769fa62 100644 --- a/audacity-no_buildstamp.patch +++ b/audacity-no_buildstamp.patch @@ -1,31 +1,7 @@ -Index: audacity-Audacity-2.3.3/src/AboutDialog.cpp +Index: audacity-Audacity-2.4.0/lib-src/portaudio-v19/qa/loopback/src/paqa.c =================================================================== ---- audacity-Audacity-2.3.3.orig/src/AboutDialog.cpp 2019-11-15 13:14:55.000000000 +0200 -+++ audacity-Audacity-2.3.3/src/AboutDialog.cpp 2020-02-02 15:40:57.718746982 +0200 -@@ -65,7 +65,7 @@ hold information about one contributor t - #ifdef REV_LONG - #define REV_IDENT wxString( "[[https://github.com/audacity/audacity/commit/" )+ REV_LONG + "|" + wxString( REV_LONG ).Left(6) + "]] of " + REV_TIME - #else --#define REV_IDENT wxT("No revision identifier was provided") -+#define REV_IDENT wxT("Official openSUSE Build") - #endif - - extern wxString FormatHtmlText( const wxString & Text ); -@@ -604,8 +604,8 @@ void AboutDialog::PopulateInformationPag - informationStr += _("Build Information"); - informationStr += wxT("\n"); - -- // Current date -- AddBuildinfoRow(&informationStr, _("Program build date: "), __TDATE__); -+ /*/ Current date -+ AddBuildinfoRow(&informationStr, _("Program build date: "), __TDATE__);*/ - AddBuildinfoRow(&informationStr, _("Commit Id:"), REV_IDENT ); - - // Not translated in 2.3.1. -Index: audacity-Audacity-2.3.3/lib-src/portaudio-v19/qa/loopback/src/paqa.c -=================================================================== ---- audacity-Audacity-2.3.3.orig/lib-src/portaudio-v19/qa/loopback/src/paqa.c 2019-11-15 13:14:55.000000000 +0200 -+++ audacity-Audacity-2.3.3/lib-src/portaudio-v19/qa/loopback/src/paqa.c 2020-02-02 15:40:57.718746982 +0200 +--- audacity-Audacity-2.4.0.orig/lib-src/portaudio-v19/qa/loopback/src/paqa.c 2020-05-18 12:54:40.106763016 +0200 ++++ audacity-Audacity-2.4.0/lib-src/portaudio-v19/qa/loopback/src/paqa.c 2020-05-18 12:55:07.291841573 +0200 @@ -1460,7 +1460,7 @@ int main( int argc, char **argv ) int justMath = 0; char *executableName = argv[0]; @@ -35,3 +11,27 @@ Index: audacity-Audacity-2.3.3/lib-src/portaudio-v19/qa/loopback/src/paqa.c if( argc > 1 ){ printf("running with arguments:"); +Index: audacity-Audacity-2.4.0/src/AboutDialog.cpp +=================================================================== +--- audacity-Audacity-2.4.0.orig/src/AboutDialog.cpp 2020-05-18 12:55:07.291841573 +0200 ++++ audacity-Audacity-2.4.0/src/AboutDialog.cpp 2020-05-18 13:03:11.727062253 +0200 +@@ -69,7 +69,7 @@ hold information about one contributor t + #endif + + #ifdef REV_LONG +-#define REV_IDENT wxString( "[[https://github.com/audacity/audacity/commit/" )+ REV_LONG + "|" + wxString( REV_LONG ).Left(6) + "]] of " + REV_TIME ++#define REV_IDENT wxString( "Official openSUSE Build" )+ REV_LONG + "|" + wxString( REV_LONG ).Left(6) + "]] of " + REV_TIME + #else + #define REV_IDENT (XO("No revision identifier was provided").Translation()) + #endif +@@ -701,8 +701,8 @@ void AboutDialog::PopulateInformationPag + << XO("Build Information") + << wxT("\n
"); + +- // Current date +- AddBuildinfoRow(&informationStr, XO("Program build date:"), __TDATE__); ++ /*/ Current date ++ AddBuildinfoRow(&informationStr, XO("Program build date:"), __TDATE__);*/ + AddBuildinfoRow(&informationStr, XO("Commit Id:"), REV_IDENT ); + + auto buildType = diff --git a/audacity.changes b/audacity.changes index 39ac4ae..d220e46 100644 --- a/audacity.changes +++ b/audacity.changes @@ -1,3 +1,18 @@ +------------------------------------------------------------------- +Mon May 18 11:11:10 UTC 2020 - Dave Plater + +- Update to release 2.4.0 and rebase audacity-no_buildstamp.patch. +- Add patch from git: + 0001-Bug2436-Cross-project-paste-should-duplicate-block-f.patch +- Add plugins sub package. +- Upstream changes: + *have split the recording/playing time off from the selection + toolbar and it can now be dragged to make it larger. + *added a new optional mode for viewing audio. In this new mode + you can see both the waveform and a spectrogram at the same time. + Previously you would switch back and forth between them if you + wanted both. + ------------------------------------------------------------------- Thu Feb 13 14:51:29 CET 2020 - sbrabec@suse.com diff --git a/audacity.spec b/audacity.spec index 7763f6b..cd4f891 100644 --- a/audacity.spec +++ b/audacity.spec @@ -16,14 +16,10 @@ # -%if 0%{?suse_version} >= 1330 || 0%{?leap_version} >= 420300 %bcond_without mad -%else -%bcond_with mad -%endif Name: audacity -Version: 2.3.3 +Version: 2.4.0 Release: 0 Summary: A Multi Track Digital Audio Editor License: GPL-2.0-or-later @@ -40,6 +36,7 @@ Patch1: audacity-flacversion.patch Patch2: audacity-misc-errors.patch # PATCH-FIX-UPSTREAM audacity-no_return_in_nonvoid.patch Patch3: audacity-no_return_in_nonvoid.patch +Patch4: 0001-Bug2436-Cross-project-paste-should-duplicate-block-f.patch BuildRequires: autoconf BuildRequires: automake BuildRequires: cmake @@ -88,6 +85,7 @@ Recommends: %{name}-lang # WARNING Nothing provides libavutil without a suffix Requires: ffmpeg Recommends: libmp3lame0 +Requires: %{name}-plugins = %{version} Requires: libFLAC++6 >= 1.3.1 Requires: libFLAC8 >= 1.3.1 @@ -100,6 +98,14 @@ physical memory size can be edited. %lang_package +%package plugins +Summary: Enhancments for Audacity +#Requires: %%{name} = %%{version} +Group: Productivity/Multimedia/Sound + +%description plugins +This package contains extra plugins for audacity. + %prep %setup -q -n %{name}-Audacity-%{version} %autopatch -p1 @@ -164,6 +170,12 @@ rm %{buildroot}%{_docdir}/%{name}/LICENSE.txt %icon_theme_cache_postun %mime_database_postun +%files plugins +%license LICENSE.txt +%dir %{_libdir}/%{name} +%{_libdir}/%{name}/libsuil_x11.so +%{_libdir}/%{name}/libsuil_x11_in_gtk2.so + %files %defattr(-,root,root) %doc README.txt