Commit Graph

4230 Commits

Author SHA1 Message Date
Guido Aulisi 9beb02d828 Fix build of jack-example-tools man pages
Commit e8c0be1ce9 changed the name
of the configuration environment to build the jack-example-tools,
but forgot to change it for man pages.
2022-01-16 20:44:43 +00:00
Florian Walpen 2980933a80 API: Export missing symbols to jack library.
The function pointers jack_error_callback and jack_info_callback are
offered by the jack.h header as non-weak API members, but they were not
exported to the jack library, only to the jackserver library.

This broke the Jack backend of the OpenAl Soft library when switching
from Jack1 to Jack2.
2022-01-16 17:17:15 +01:00
falkTX a2fe7ec2fd Update Changelog
Signed-off-by: falkTX <falktx@falktx.com>
2022-01-15 15:09:56 +00:00
Claudio Cabral 719fa1d545 Add 32 bit support for ALSA driver (#811)
* apply changes without whitespace

* remove neon intrinsics and fix indentation

* update float_32 macro and fix misspellings

* check msbits to determine number of bits in alsa driver

* add better error messages and support for SND_PCM_FORMAT_S32_BE

* log when sample format is not equal to bits

Co-authored-by: Claudio Cabral <clca@bang-olufsen.dk>
Co-authored-by: Claudio Cabral <cl@udio.co>
2022-01-15 15:09:56 +00:00
Alexander Traud e2ad1e40cf Fix grouping for latest doxygen.
Since doxygen 1.8.16, opening and closing a group must not be done as
C comment but as doxygen command. In other words, not one but two
asterisk characters are required so that doxygen finds a group.
2022-01-15 15:09:56 +00:00
Aleksandr Beliaev d4d464e2b1 Override permission issues by separating users metadata 2022-01-15 15:09:56 +00:00
Florian Walpen a1ea8a9bb5 FreeBSD: Add missing OSS option --excl to man page.
While there, also improve the short description of this option in the
OSS backend part of usage help and jack_control.
2022-01-15 15:09:56 +00:00
Florian Walpen 54217a5d8d CI: Bogus install prefix in FreeBSD Cirrus CI.
Apparently the ${HOME} variable is set to the filesystem root "/" in
Cirrus CI FreeBSD instances. Just create an installation directory
without it, then.

While here, set --pkgconfigdir to closely mimick the build in the
FreeBSD ports tree.
2022-01-15 15:09:56 +00:00
falkTX e332bd7e72 Update changelog
Signed-off-by: falkTX <falktx@falktx.com>
2022-01-15 15:09:56 +00:00
Florian Walpen ea359377fc CI: Add FreeBSD builds through Cirrus CI.
When the github application Cirrus CI (https://cirrus-ci.org/) is
installed, this build description file adds FreeBSD build checks to
changes and PRs in github.

There are four build tasks currently, a minimal build and one with all
options enabled on two different FreeBSD versions.
2022-01-15 15:09:56 +00:00
falkTX ffde5f7863 CI: use full list of bad packages, for posterity
Signed-off-by: falkTX <falktx@falktx.com>
2022-01-15 15:09:56 +00:00
falkTX ce575b3b81 Add back IRC notifications
Signed-off-by: falkTX <falktx@falktx.com>
2022-01-15 15:09:56 +00:00
Filipe Coelho 300692b051 Update CI setup (#832)
* CI: Build with latest PawPaw and LTO

Signed-off-by: falkTX <falktx@falktx.com>

* Ensure LTO is not enabled

Signed-off-by: falkTX <falktx@falktx.com>

* Finalize changes

Signed-off-by: falkTX <falktx@falktx.com>
2022-01-15 15:09:56 +00:00
David Runge 8d7faa5bea Move jack_control to dbus (#831)
* Move jack_control to dbus dir

dbus/jack_control:
The `jack_control` script is dbus specific and not part of the original
jack tools. As the files offered by jack-example-tools are now
optionally not built, the script needs to be made available from a
location, that is not ignored when omitting the build of
jack-example-tools files.

* Move installation of jack_control to dbus integration

dbus/wscript:
Install `jack_control` script if building/installing jackdbus.

tools/wscript:
Remove (unconditional) installation of `jack_control` script.
2022-01-15 15:09:56 +00:00
Filipe Coelho 4dec157f60 Fix CI windows builds (#830)
* Alternative attempt at fixing CI

Signed-off-by: falkTX <falktx@falktx.com>

* Cleanup

Signed-off-by: falkTX <falktx@falktx.com>

* Forgot apt-get update

Signed-off-by: falkTX <falktx@falktx.com>
2022-01-15 15:09:56 +00:00
David Runge e8c0be1ce9 Fix build of jack-example-tools with waf autooptions
wscript:
In 61a708f2c6873881ae36fa2f01b38a15bfc3f681 a regression has been
introduced, that always leads to not building the jack-example-tools
(even if selected).
This has been introduced due to the use of the wrong configuration
environment `HAVE_JACK_EXAMPLE_TOOLS`, whereas it should have been
`BUILD_JACK_EXAMPLE_TOOLS`.
2022-01-15 15:09:56 +00:00
David Runge ef2a0d3b79 Remove unused travis ci integration
.{ci/*,travis.yml}:
Remove unused travis-ci integration.
2022-01-15 15:09:56 +00:00
David Runge d02211614f Remove unused script
svnversion_regenerate.sh:
Remove unused script.
2022-01-15 15:09:56 +00:00
David Runge 3d6fd78701 Remove use of svnversion_regenerate.sh
dbus/jackdbus.c:
Rely on the `JACK_VERSION` define instead of `SVN_VERSION` (included
from svnversion.h).

dbus/wscript:
Add the `JACK_VERSION` define based on `JACK_VERSION` configuration.

wscript:
Remove all code related to the use of `svnversion.h` and
`svnversion_regenerate.sh`.
2022-01-15 15:09:56 +00:00
David Runge 8566d4a630 Add changelog entry for optional example tools
ChangeLog.rst:
Add changelog entry for new configure option to allow not to build
files provided by jack-example-tools.
2022-01-15 15:09:56 +00:00
David Runge 508d95a97e Allow optional build of jack-example-tools
wscript:
Add option `--example-tools` to allow optional build of executables and
libraries provided by jack-example-tools (defaults to True).
It can be used as `--example-tools=yes|no` or `--no-example-tools` or
plain `--example-tools`.
Based on the new option, set the configuration environment variable
`HAVE_JACK_EXAMPLE_TOOLS` which is used throughout the configuration
and build steps to include the `example-clients`, `tools` and `tests`
subdirectories.

man/wscript:
Provide the `HAVE_JACK_EXAMPLE_TOOLS` build environment variable to the
`fill_template` script as second argument.
Remove unused imports.

man/fill_template:
Change the behavior of the script to only create all man pages if the
second argument to the script is `True` (the jack-example-tools are
being built), else only create the man page for jackd.
2022-01-15 15:09:56 +00:00
David Runge 810c78e349 Add custom variable to jack pkgconfig to distinguish implementations
jack.pc.in:
Add the custom `jack_implementation=jack2` pkgconfig variable to the
generated jack.pc file to be able to distinguish jack implementations.
As jack implementations exist with jack1, jack2 and pipewire-jack, it is
not (easily) possible to distinguish them by looking at the version
alone (particularly the case with jack2 vs. pipewire-jack, as they share
the same headers).
2022-01-15 15:09:56 +00:00
Florian Walpen 655ff5e4e1 POSIX: Remove unnecessary feature test macro.
This is a no-op since the line was already commented out, to make it
compile on FreeBSD. But it deserves an explanation:

The _POSIX_C_SOURCE macro is meant to restrict the C library to a
certain POSIX standard, not to enable features. This is inappropriate
here because:

1. Jack already uses non-POSIX functions. E.g. JackPosixSemaphore.cpp
   references gettimeofday(), which is part of the X/Open specs.

2. C++ does not define a POSIX level to be based on. Headers from the
   C++ standard library may (and do) break when the POSIX feature level
   is restricted.

The canonical way is to only set the feature level through the
"--std=gnu++11" compile options.
2022-01-15 15:09:55 +00:00
Florian Walpen b5597128c2 FreeBSD: Big driver overhaul for FreeBSD OSS.
Features:
 * Internal workings more in line with other Jack drivers.
 * Use poll() for wait and sync instead of blocking I/O.
 * Allows to use Jack in "async" mode.
 * Calculate DSP usage correctly.
 * OSS buffer management to achieve stable latencies.
 * Latency correction for asymmetric OSS buffer use.
 * More robust handling of over- and underruns.
 * Handle format changes forced by the OSS interface.
 * FreeBSD 24bit samples are always packed.

No changes to the driver parameters or the user interface.
2022-01-15 15:09:55 +00:00
Florian Walpen b6f93234ef FreeBSD: Specific FreeBSD OSS driver.
Start with an unchanged copy of the Solaris OSS driver.
2022-01-15 15:09:55 +00:00
Florian Walpen 2e3c6fab02 FreeBSD: Use uptime.h relay include. 2022-01-15 15:09:55 +00:00
Florian Walpen 7c81691e38 FreeBSD: Use driver.h relay include. 2022-01-15 15:09:55 +00:00
Florian Walpen f94f285ca5 FreeBSD: Cleanup tab indents. 2022-01-15 15:09:55 +00:00
Goran Mekić 25e09df3a6 It compiles 2022-01-15 15:09:55 +00:00
Greg V ada406603c dbus: use Linux style uptime on FreeBSD 2022-01-15 15:09:55 +00:00
Greg V 92e9596aa5 Put the clock_gettime based time impl into posix/ 2022-01-15 15:09:55 +00:00
Greg V 5f9e108e16 Fix missing CELT use for net driver 2022-01-15 15:09:55 +00:00
Goran Mekić 5c667d5282 Add FreeBSD support 2022-01-15 15:09:55 +00:00
Greg V 155d6ea3f9 Do not use O_RDWR on semaphores on FreeBSD
This is forbidden (returns EINVAL)
2022-01-15 15:09:55 +00:00
Greg V e5b5ee7bc9 Start semaphore names with a slash on FreeBSD 2022-01-15 15:09:55 +00:00
Camille Gonnet 8d51e9a005 ALSA: convert properly S24_LE 2022-01-15 15:09:55 +00:00
ihsinme ffdb275081 Update JackNetUnixSocket.cpp 2022-01-15 15:09:55 +00:00
Peter Bridgman 7e599badec macOS: Pass JackMachSemaphore send right via mach_msg IPC (#788)
* macOS: Pass JackMachSemaphore send right via mach_msg IPC

Previously, JackMachSemaphore would communicate the send right for the
semaphore object from the server to a client via a named service
registered via `bootstrap_register`. However, to do this, it would
register the semaphore's port as the service port directly.

In theory this ought to be fine, however in practice, macOS `launchd`,
which provides the `bootstrap_register` interface, does not correctly
detect when such a port becomes dead, and incorrectly believes that the
service that it provides is forever alive, even past the end of the
`jackd` process' (and therefore the semaphore's) existence. This seems
to be *specific* to semaphore ports, as `launchd` is expecting a
standard IPC port, owned by the task, not the kernel. This prevents
`jackd` from later registering another service with the same name, as
`launchd` rejects the registration as conflicting with an active service.

To get around this, `jackd` previously added a counter to the end of the
named service registrations, allowing old services to remain in the
system until the end of the session. To prevent things getting out of
hand, this was capped at 98 service registrations for a given semaphore
name. This led to #784, in which running a client for the 99th time
resulted in the semaphore creation failing and the client failing to
connect.

As `launchd` outlives multiple runs of `jackd`, this situation persisted
across restarts of `jackd`, requiring a restart of the user's session
(i.e. a reboot) to fix.

An initial attempt at fixing this (see #785) tried passing the port
rights directly via shared memory, however mach is too clever for us and
foils that plan by having port names be looked up in a per-task table
(sensible when you think about it).

In this commit, we use mach IPC messages to transfer the send right for
the semaphore from the server to the client. By registering a standard
IPC port with the bootstrap server, the service registrations are
correctly torn down when the ports are destroyed.

It works something like this:

* Server creates IPC port and registers it globally via `bootstrap_register`
* Server listens on IPC port for messages
* Client looks up IPC port via `bootstrap_look_up`
* Client sends it a message
* Server replies with a message containing a send right to the
semaphore's port
* Client is then free to use the semaphore port as before.

This resolves #784.

* Improve error handling

* Add myself to Authors
2022-01-15 15:09:55 +00:00
falkTX 4ba2806038 Build netsource tool when celt or opus are available
Signed-off-by: falkTX <falktx@falktx.com>
2022-01-15 15:09:55 +00:00
falkTX b066c5c078 Fix deb path
Signed-off-by: falkTX <falktx@falktx.com>
2022-01-15 15:09:55 +00:00
falkTX 4e93e1c79f Fix path to deb packages
Signed-off-by: falkTX <falktx@falktx.com>
2022-01-15 15:09:55 +00:00
falkTX 05dd7c1e7a Build deb packages
Signed-off-by: falkTX <falktx@falktx.com>
2022-01-15 15:09:55 +00:00
falkTX 457ff53b76 Another syntax fix
Signed-off-by: falkTX <falktx@falktx.com>
2022-01-15 15:09:55 +00:00
falkTX 4e8e597c3e Fix syntax error
Signed-off-by: falkTX <falktx@falktx.com>
2022-01-15 15:09:55 +00:00
falkTX b902cf381b Begin ubuntu-20.04 automated deb packaging
Signed-off-by: falkTX <falktx@falktx.com>
2022-01-15 15:09:55 +00:00
falkTX e2b540708a CI: Fix macOS package path
Signed-off-by: falkTX <falktx@falktx.com>
2022-01-15 15:09:55 +00:00
falkTX 491b3806f6 Revert "CI: Use xvfb-run for wineboot too"
This reverts commit 9a33cc254c49c0c96c4dbe0552caade1583fb1e2.
2022-01-15 15:09:55 +00:00
falkTX e0b114da1e CI: Use xvfb-run for wineboot too
Signed-off-by: falkTX <falktx@falktx.com>
2022-01-15 15:09:55 +00:00
falkTX db0ab0f12b CI: Use xvfb-run for wine stuff
Signed-off-by: falkTX <falktx@falktx.com>
2022-01-15 15:09:55 +00:00
falkTX 8b52afbbda Update windows installers as artifacts
Signed-off-by: falkTX <falktx@falktx.com>
2022-01-15 15:09:55 +00:00