Commit graph

29 commits

Author SHA1 Message Date
Shunsuke Shimizu
47a6918739 build-sys: Fix macOS build
* Enable macOS specific modules (module-bonjour-publish,
  module-coreaudio-detect and module-coreaudio-device)
* Correctly set `PA_SOEXT` (.so, .dylib and .dll)
* Build `poll-posix.c` and `semaphore-osx.c`
* Drop linker flag `-Wl,-z,nodelete` on Darwin
* Drop linker flag `-Wl,--no-undefined` on Darwin
* Prefer to `clock_gettime` over compat impl for old Darwin
* Disable SCM credential on Darwin

Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/746>
2022-12-07 10:57:01 +00:00
Nicolas Cavallari
baa3d24b76 build-sys: Add missing libatomic_ops dependencies
Add libatomic_ops dependencies to libraries/modules that showed a
failure on an arch that does not have native atomic operations support.

Not all optional dependencies were tested, so it is possible that
some optional modules are still missing libatomic_ops dependencies.

Signed-off-by: Nicolas Cavallari <nicolas.cavallari@green-communications.fr>
Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/732>
2022-07-18 13:59:14 +00:00
Igor V. Kovalenko
5fcc70e2e8 build-sys: meson: Fix indentation in daemon/client blocks
Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/659>
2021-11-17 16:06:23 +00:00
Igor V. Kovalenko
80c0a497d3 build-sys: meson: Rearrange dependencies under client and daemon options
Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/659>
2021-11-17 16:06:23 +00:00
Igor V. Kovalenko
6928714b64 build-sys: meson: change daemon-only to client
Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/659>
2021-11-17 16:06:23 +00:00
Mart Raudsepp
4cf4a1fd5b build-sys: meson: Allow building the daemon only
Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/659>
2021-11-17 16:06:23 +00:00
Georg Chini
156b572954 pulsecore: Add alternative time smoother implementation
This patch adds an alternative time smoother implementation based on the theory
found at https://www.freedesktop.org/software/pulseaudio/misc/rate_estimator.odt.

The functions were written to replace the current smoother functions nearly on
a one-to-one basis, though there are a few differences:
- The smoother_2_put() function takes a byte count instead of a sound card
  time as argument. This was changed because in most places a sample count
  was converted to a time before passing it to the smoother.
- The smoother needs to know sample rate and frame size to convert byte
  counts to time.
- A smoother_2_get_delay() function was added to directly retrieve the stream
  delay from the smoother.
- A hack for USB devices was added which works around an issue in the alsa
  latency reports for USB devices.

The smoother delivers much better precision than the current implementation.
For results, see the document referenced above.

The new functions are still unused. The following patches will convert all
callers of the smoother functions so that they can use both smoother
implementations, depending on a configure option.

Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/55>
2021-11-03 21:13:38 +00:00
Igor V. Kovalenko
733969ac19 socket-server: Move systemd socket activation code to pulsecore
There is no need to support server sockets in client library. Move all related
code and tcp-wrappers dependency to pulsecore library.

Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/640>
2021-09-27 01:34:42 +00:00
Igor V. Kovalenko
2a5497bac5 json: remove json from public API
Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/570>
2021-06-03 21:15:48 +00:00
Felipe Sateler
3a1affa175 Don't link libpulsecommon with GLib and GTK
This was the behaviour with the autotools build.

Fixes #1210

Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/559>
2021-05-31 16:18:08 +00:00
Igor V. Kovalenko
424580a901 build-sys: meson: allow building client libraries only
Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/540>
2021-04-19 18:48:59 +00:00
Igor V. Kovalenko
a2db3fcfb2 message-params: clean up
Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/525>
2021-03-27 11:18:22 +00:00
Igor V. Kovalenko
156e16f941 build-sys: meson: add tcp-wrappers
Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/498>
2021-02-12 17:14:24 +00:00
Greg V
51fecacd46 build-sys: meson: add execinfo dependency for FreeBSD
For 'backtrace' and related symbols

Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/277>
2021-01-18 16:33:53 +00:00
Edward Lee
b892e327a9 win32: Fix meson build system for Windows.
Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/360>
2020-12-16 11:05:28 -05:00
Georg Chini
590fd1ca69 message-params: Allow parameter strings to contain escaped curly braces
The patch adds the possibility to escape curly braces within parameter strings
and introduces several new functions that can be used for writing parameters.

For writing, the structure pa_message_params, which is a wrapper for pa_strbuf
has been created. Following new write functions are available:

pa_message_params_new() - creates a new pa_message_params structure
pa_message_params_free() - frees a pa_message_params structure
pa_message_param_to_string_free() - converts a pa_message_param to string and
frees the structure
pa_message_params_begin_list() - starts a list
pa_message_params_end_list() - ends a list
pa_message_params_write_string() - writes a string to a pa_message_params structure
pa_message_params_write_raw() - writes a raw string to a pa_message_params structure

For string parameters that contain curly braces or backslashes, those characters
will be escaped when using pa_message_params_write_string(), while write_raw() will
put the string into the buffer without any changes.

For reading, pa_message_params_read_string() reverts the changes that
pa_message_params_write_string() might have introduced.

The patch also adds more restrictions on the object path name. Now only
alphanumeric characters and one of "_", ".", "-" and "/" are allowed.
The path name may not end with a / or contain a double slash. If the user
specifies a trailing / when sending a message, it will be silently removed.

Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/51>
2020-12-03 14:41:39 +00:00
Tanu Kaskinen
924743e612 meson: Remove libpulse dep from libpulsecore
libpulsecore is not supposed to depend on the client library.

Removing the dependency caused build failures, which are fixed by adding
more stuff to libpulsecommon.
2020-04-09 14:51:21 +00:00
Rasmus Thomsen
bff163089c meson: link libintl if it's not provided by libc
This fixes the build on musl with external gettext
2019-09-25 04:42:03 +00:00
Jan Alexander Steffens (heftig)
493e7f3582
build-sys: meson: Add some missing checks
- Header and function checks from configure.ac
  (some libc, some libpthread, dladdr from libdl)
- Find iconv and check constness
2019-08-09 23:11:24 +02:00
Arun Raghavan
6a1addf35c build-sys: Move svolume-*.c to libpulsecore
The various software volume implementations were being built as part of
libpulsecommon for some reason. These should only ever be used in the
daemon, so they should be in libpulsecore.
2019-08-05 14:19:27 +05:30
Arun Raghavan
f996ad0688 build-sys: meson: Add -Wl,no-delete to relevant libraries
This mirrors the autotools option for all server-side dynamic libraries.
2019-08-05 09:52:32 +05:30
Arnaud Rebillout
fdf3384f24 meson: Add systemduserunitdir option
Signed-off-by: Arnaud Rebillout <arnaud.rebillout@collabora.com>
2019-06-08 11:57:00 +02:00
Arnaud Rebillout
6dbb0774b2 meson: Enable (almost) all tests
Signed-off-by: Arnaud Rebillout <arnaud.rebillout@collabora.com>
2019-06-08 11:56:56 +02:00
Arun Raghavan
37dbeae031 build-sys: Fix up meson install paths
Brings things in line with the autotools build, and adds ALSA mixer
paths and profile-sets into the meson build system as well.

The module installation path is also now customisable.
2019-06-06 18:49:59 +02:00
Arnaud Rebillout
6eba2f823d meson: Add optional Async NS support
Signed-off-by: Arnaud Rebillout <arnaud.rebillout@collabora.com>
2018-12-27 17:25:56 +05:30
Arnaud Rebillout
639c54546d meson: Add optional Gtk+ support
Signed-off-by: Arnaud Rebillout <arnaud.rebillout@collabora.com>
2018-12-27 17:25:56 +05:30
Arnaud Rebillout
065a79ff8c meson: Add optional GLib support
Signed-off-by: Arnaud Rebillout <arnaud.rebillout@collabora.com>
2018-12-27 17:25:56 +05:30
Arnaud Rebillout
ec46f73f56 meson: Propagate systemd dep to libpulsecommon and daemon
This is needed now that we define HAVE_SYSTEMD_xxx

Signed-off-by: Arnaud Rebillout <arnaud.rebillout@collabora.com>
2018-10-04 08:44:18 +05:30
Arun Raghavan
114cdfbdde build-sys: First pass at a meson-ified build system
This is a working implementation of a build with meson. The server,
utils, and most modules build with this, and it is possible to run from
a build tree and play/capture audio on ALSA devices.

There are a number of FIXMEs, of course, and a number of features that
need to be enabled (modules, dependencies, installation, etc.), but this
should provide everything we need to get there relatively quickly.

To use this, install meson (distro package, or mesonbuild.com) and run:

  $ cd <pulseaudio src dir>
  $ meson <builddir>
  $ ninja -C <builddir>
2018-06-21 05:50:29 +05:30