Building and customizing Audacity from the source code.
-
tomwarner
- Posts: 8
- Joined: Mon May 29, 2017 10:58 pm
- Operating System: OS X 10.9 Mavericks
Post
by tomwarner » Mon May 29, 2017 11:04 pm
On master branch, made a minor change to add a try-catch in one file so it's practically clean. When I run make, I get a failure in what looks like the translation directory:
Code: Select all
make[2]: Entering directory '/home/tom/Projects/audacity/audacity/locale'
: --update --lang=af af.po audacity.pot
rm -f af.gmo && : -c --statistics --verbose -o af.gmo af.po
mv: cannot stat 't-af.gmo': No such file or directory
Makefile:742: recipe for target 'af.gmo' failed
make[2]: *** [af.gmo] Error 1
Anyone know what to do? Thanks!
-
steve
- Site Admin
- Posts: 81653
- Joined: Sat Dec 01, 2007 11:43 am
- Operating System: Linux *buntu
Post
by steve » Mon May 29, 2017 11:08 pm
tomwarner wrote:made a minor change to add a try-catch in one file so it's practically clean
Does it build if it is "actually" clean (unmodified)?
What was the change?
-
tomwarner
- Posts: 8
- Joined: Mon May 29, 2017 10:58 pm
- Operating System: OS X 10.9 Mavericks
Post
by tomwarner » Mon May 29, 2017 11:38 pm
Reset the file, build still fails for same reason.
Change was in src/import/Import.cpp line 501, I wrapped:
Code: Select all
auto inFile = plugin->Open(fName);
in a try-catch block:
Code: Select all
std::unique_ptr<ImportFileHandle> inFile;
try
{
inFile = plugin->Open(fName);
}
catch (onst std::exception &e)
{
wxLogDebug(wxT("Open with %s failed, file may be corrupted"),plugin->GetPluginStringID().c_str());)
}
-
steve
- Site Admin
- Posts: 81653
- Joined: Sat Dec 01, 2007 11:43 am
- Operating System: Linux *buntu
Post
by steve » Mon May 29, 2017 11:52 pm
Did you try building Audacity before modifying the source code?
-
tomwarner
- Posts: 8
- Joined: Mon May 29, 2017 10:58 pm
- Operating System: OS X 10.9 Mavericks
Post
by tomwarner » Tue May 30, 2017 2:36 am
No, but I've reset it to a clean copy, and it's still failing. Anyway the error make throws doesn't seem to have anything to do with the file I modified.
-
tomwarner
- Posts: 8
- Joined: Mon May 29, 2017 10:58 pm
- Operating System: OS X 10.9 Mavericks
Post
by tomwarner » Tue May 30, 2017 3:21 am
Never mind; I installed "gettext" (which was not installed before) and it works now. I hit some other make errors after that, but was able to resolve them by installing build-essential and gnome-devel. Thanks though!
-
steve
- Site Admin
- Posts: 81653
- Joined: Sat Dec 01, 2007 11:43 am
- Operating System: Linux *buntu
Post
by steve » Tue May 30, 2017 7:41 am
Glad you got it working.
For the benefit of other readers, on Ubuntu / Debian based systems, "
build-essential" is a prerequisite and should be installed first, then Audacity's other dependencies may be installed with the command: