termux / termux-packages

A package build system for Termux.
https://termux.dev
Other
13.02k stars 2.99k forks source link

Audacity does not load/detect pulseaudio or any audio devices #10412

Open xu3s opened 2 years ago

xu3s commented 2 years ago

Problem description

I got this issue where audacity does not detect pulseaudio audacity-err

What steps will reproduce the bug?

Open audacity

What is the expected behavior?

Pulseaudio or opensles loaded as audio device

System information

termux-info:

Termux Variables:
TERMUX_API_VERSION=0.50.1
TERMUX_APK_RELEASE=F_DROID
TERMUX_APP_PID=26202
TERMUX_IS_DEBUGGABLE_BUILD=0
TERMUX_MAIN_PACKAGE_FORMAT=debian
TERMUX_VERSION=0.118.0
Packages CPU architecture:
aarch64
Subscribed repositories:
# sources.list
deb https://grimler.se/termux-packages-24/ stable main
# x11-repo (sources.list.d/x11.list)
deb https://packages-cf.termux.org/apt/termux-x11 x11 main
# sources.list.d/pointless.list
deb https://its-pointless.github.io/files/24 termux extras
Updatable packages:
All packages up to date
Android version:
9
Kernel build information:
Linux localhost 4.4.153-perf+ #1 SMP PREEMPT Thu Feb 20 17:26:22 CST 2020 aarch64 Android
Device manufacturer:
asus
Device model:
ASUS_X00TD
ghost commented 2 years ago

Possibly related:

(1) Currently, Audacity is built without ffmpeg support. Yet libmp3lame cannot be specified, even though it is installed in $PREFIX/lib. I have tried manually creating $PREFIX/lib/audacity and copying $PREFIX/lib/libmp3lame.so into that directory, named as libmp3lame.so.0. But Audacity does not save or recognize this setting. Therefore, it cannot open mp3 files. But it does open and play ogg files without problem.

(2) When I launch audacity from command line, I see this warning, which vaguely sounds like it might involve a memory leak (I do not know):

(audacity:31904): Gtk-WARNING **: 13:59:56.401: A floating object was finalized. This means that someone
called g_object_unref() on an object that had only a floating
reference; the initial floating reference is not owned by anyone
and must be removed with g_object_ref_sink().
xtkoba commented 2 years ago

Honestly this is pretty much expected because PortAudio (the library used by Audacity for audio playback and recording) uses ALSA or JACK, neither of which is available in Termux.

ghost commented 2 years ago

Using Audacity, 32-bit Android 11. Audacity can open OGG files, as well as its own native projects. It can export OGG and WAV. I can use command-line ffmpeg to convert mp3 to OGG or WAV, manipulate in Audacity, export to OGG or WAV, then use ffmpeg to convert to mp3. Although I have LAME, Audacity does not recognize the library for import. It appears to use it for export, but I believe that is deceptive, as the exported mp3 fails some tests.

Bottom line: Audacity is useful. Not fully capable, but useful.

DLC01 commented 2 years ago

Honestly this is pretty much expected because PortAudio (the library used by Audacity for audio playback and recording) uses ALSA or JACK, neither of which is available in Termux.

there is an version of portaudio which has been patched to use opensles https://github.com/Gundersanne/portaudio_opensles

macerg commented 2 years ago

Honestly this is pretty much expected because PortAudio (the library used by Audacity for audio playback and recording) uses ALSA or JACK, neither of which is available in Termux.

Why not pulseaudio?

stale[bot] commented 2 years ago

This issue/PR has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

xtkoba commented 1 year ago

See also #821.

truboxl commented 10 months ago

Portaudio now has Pulseaudio support, so probably need to rebuild to verify, see https://github.com/PortAudio/portaudio/pull/336

But I don't see Portaudio releasing new tags anytime soon