Commit graph

1650 commits

Author SHA1 Message Date
Vladislav Vaintroub
cb545f1116 CMake cleanup
- use FIND_PACKAGE(LIBAIO) to find libaio
- Use standard CMake conventions in Find{PMEM,URING}.cmake
- Drop the LIB from LIB{PMEM,URING}_{INCLUDE_DIR,LIBRARIES}
  It is cleaner, and consistent with how other packages are handled in CMake.
  e.g successful FIND_PACKAGE(PMEM) now sets PMEM_FOUND, PMEM_LIBRARIES,
  PMEM_INCLUDE_DIR, not  LIBPMEM_{FOUND,LIBRARIES,INCLUDE_DIR}.
- Decrease the output. use FIND_PACKAGE with QUIET argument.
- for Linux packages, either liburing, or libaio is required
  If liburing is installed, libaio does not need to be present   .
  Use FIND_PACKAGE([LIBAIO|URING] REQUIRED) if either library is required.
2021-03-23 17:20:17 +01:00
Marko Mäkelä
e8113f7572 CMake cleanup: Make WITH_URING, WITH_PMEM Boolean
The new default values WITH_URING:BOOL=OFF, WITH_PMEM:BOOL=OFF imply
that the dependencies are optional.
An explicit request WITH_URING=ON or WITH_PMEM=ON will cause the
build to fail if the requested dependencies are not available.

Last, to prevent a feature to be built in even though the built-time
dependencies are available, the following can be used:

cmake -DCMAKE_DISABLE_FIND_PACKAGE_URING=1
cmake -DCMAKE_DISABLE_FIND_PACKAGE_PMEM=1

This cleanup was suggested by Vladislav Vaintroub.
2021-03-20 16:23:47 +02:00
Marko Mäkelä
00528a0445 Merge 10.5 into 10.6 2021-03-19 13:35:18 +02:00
Marko Mäkelä
be881ec457 Merge 10.4 into 10.5 2021-03-19 13:09:21 +02:00
Marko Mäkelä
44d70c01f0 Merge 10.3 into 10.4 2021-03-19 11:42:44 +02:00
Eugene Kosov
62e4aaa240 cleanup: os_thread_sleep() -> std::this_thread::sleep_for()
std version has an advantage of a more convenient units implementation from
std::chrono. Now it's no need to multipy/divide to bring anything to
micro seconds.
2021-03-19 11:44:03 +03:00
Marko Mäkelä
19052b6deb Merge 10.2 into 10.3 2021-03-18 12:34:48 +02:00
Vladislav Vaintroub
aa2ff62082 MDEV-9077 Use sys schema in bootstrapping, incl. mtr 2021-03-18 08:02:48 +01:00
Marko Mäkelä
7c5c6fa65c MDEV-25090: Depend on libpmem where available
WITH_PMEM: Change the parameter from BOOL to a ternary STRING
with a default value that allows to use libpmem when it is available.
In this way, a libpmem dependency will be automatically installed
on other than Debian-based systems, based on what is available on
the continuous integraton system for building the packages.

WITH_PMEM=auto (default): Use libpmem when available.
WITH_PMEM=yes: Require libpmem to be available.
WITH_PMEM=no: Do not depend on libpmem.
2021-03-17 13:23:18 +02:00
Eugene Kosov
a4d3e04659 MDEV-24883 follow up: unset variables in CMake 2021-03-17 10:57:45 +03:00
Marko Mäkelä
f87a944c79 Merge 10.5 into 10.6 2021-03-16 15:51:26 +02:00
Vladislav Vaintroub
f2c79eda4b MDEV-24554 Windows authenticode signing stopped working
Change the default timestamping URL, again
http://timestamp.globalsign.com/?signature=sha2 seems to work fine atm
2021-03-16 00:15:34 +01:00
Otto Kekäläinen
211e9b3e0a MDEV-24927: Deb: Use liburing-dev instead of libaio-dev
Updating the debian/control file will automatically update the dependencies
in all CI environments that directly read the debian/control file, such
as Salsa-CI and buildbot.mariadb.org to some degree.
(https://github.com/MariaDB/mariadb.org-tools/issues/43)

On Debian/Ubuntu releases that don't have liburing-dev available,
automatically downgrade to libaio-dev (just like libcurl4->3 is done).
This ensures the debian/control file is always up-to-date and works for
latest Debian and Ubuntu releases, while the backwards compatibility mods
are maintained in autobake-deb.sh separately, and can be dropped from there
once support for certain platforms end.

Debian/Ubuntu availability visible at:
- https://packages.debian.org/search?searchon=names&keywords=liburing-dev
- https://packages.ubuntu.com/search?searchon=names&keywords=liburing-dev

Also modify debian/rules to force a build without libaio. Use YES instead
of ON to make the flag more logical (=turning libaio check "off").

Stop running Salsa-CI for Debian Stretch-backports, as it does not have
liburing-dev available nor is the old-old Debian stable a relevant platform
for MariaDB 10.6 to test against anymore. Since the Stretch-backports build
can no longer be made, neither can the MySQL 5.7 on Bionic upgrade test be
run, as it depended on the Stretch binary.

This commit does not modify the .travis.yml file, as Travis-CI does not
have new enough Ubuntu releases available yet. Also Travis-CI.org is
practically dead now as build times have been shrunk to near zero.

The scope of this change is also Debian/Ubuntu only. No RPM or Windows or
Mac changes are included in this commit.

This commit does not update the external libmariadb or ColumnStore
CI pipelines, as those are maintained in different repositories.
2021-03-15 11:34:02 +02:00
Marko Mäkelä
783625d78f MDEV-24883 add io_uring support for tpool
liburing is a new optional dependency (WITH_URING=auto|yes|no)
that replaces libaio when it is available.

aio_uring: class which wraps io_uring stuff

aio_uring::bind()/unbind(): optional optimization

aio_uring::submit_io(): mutex prevents data race. liburing calls are
thread-unsafe. But if you look into it's implementation you'll see
atomic operations. They're used for synchronization between kernel and
user-space only. That's why our own synchronization is still needed.

For systemd, we add LimitMEMLOCK=524288 (ulimit -l 524288)
because the io_uring_setup system call that is invoked
by io_uring_queue_init() requests locked memory. The value
was found empirically; with 262144, we would occasionally
fail to enable io_uring when using the maximum values of
innodb_read_io_threads=64 and innodb_write_io_threads=64.

aio_uring::thread_routine(): Tolerate -EINTR return from
io_uring_wait_cqe(), because it may occur on shutdown
on Ubuntu 20.10 (Groovy Gorilla).

This was mostly implemented by Eugene Kosov. Systemd integration
and improved startup/shutdown error handling by Marko Mäkelä.
2021-03-15 11:30:17 +02:00
Vladislav Vaintroub
031b3dfc22 MDEV-25123 support MSVC ASAN 2021-03-12 08:44:55 +01:00
Marko Mäkelä
a43ff483fa Merge 10.5 into 10.6 2021-03-11 20:20:07 +02:00
Vladislav Vaintroub
baddbaa0e3 fixup 449871458b 2021-03-09 11:44:29 +01:00
Vladislav Vaintroub
449871458b Fix Windows clang build with newest cmake 2021-03-08 18:00:55 +01:00
Marko Mäkelä
7953bae22a Merge 10.5 into 10.6 2021-02-24 09:30:17 +02:00
Marko Mäkelä
f159061510 Merge 10.4 into 10.5 2021-02-24 08:54:44 +02:00
Vicențiu Ciorbaru
ad0f0d2b1a Merge branch '10.3' into 10.4 2021-02-23 21:44:22 +02:00
Vicențiu Ciorbaru
13f0e1e139 Merge branch '10.2' into 10.3 2021-02-23 21:43:05 +02:00
Vicențiu Ciorbaru
9e259d58c2 Remove race condition during make dist
Introduced by 85828b8f22

This is running 2 git processes in parallel, which, if unlucky can cause
either of them to fail with "File already exists" error.
2021-02-23 17:26:08 +02:00
Marko Mäkelä
94b4578704 Merge 10.5 into 10.6 2021-02-17 19:39:05 +02:00
Sergei Golubchik
f13f966304 update PCRE2 ref 2021-02-15 16:46:32 +01:00
Marko Mäkelä
1110beccd4 Merge 10.5 into 10.6 2021-02-02 15:15:53 +02:00
Sergei Golubchik
e2c571ad84 MDEV-24498 mysql_config reports wrong libs for libmysqld
filter out tpool
2021-02-01 20:05:54 +01:00
Marko Mäkelä
6d05a95c65 Merge 10.5 into 10.6 2021-01-14 16:13:31 +02:00
Sergei Golubchik
fbc171333e MDEV-24292 support semi-independent versioning for sub-packages
3. Embed plugin version into the DEB package version

this assumes that -DDEB is only used from within autobake-deb.sh
2021-01-12 16:47:23 +01:00
Sergei Golubchik
78806be6d3 MDEV-24292 support semi-independent versioning for sub-packages
2. Embed plugin version into the RPM package version

introduce SERVER_VERSION, because plugins can overwrite VERSION
(and columnstore actually does)
2021-01-12 16:47:23 +01:00
Sergei Golubchik
64d2849b3e MDEV-24292 support semi-independent versioning for sub-packages
1. specify plugin version in MYSQL_ADD_PLUGIN
2021-01-12 16:47:23 +01:00
Marko Mäkelä
666565c7f0 Merge 10.5 into 10.6 2021-01-11 17:32:08 +02:00
Marko Mäkelä
8de233af81 Merge 10.4 into 10.5 2021-01-11 16:29:51 +02:00
Marko Mäkelä
fd5e103aa4 Merge 10.3 into 10.4 2021-01-11 10:35:06 +02:00
Marko Mäkelä
5a1a714187 Merge 10.2 into 10.3 (except MDEV-17556)
The fix of MDEV-17556 (commit e25623e78a
and commit 61a362c949) has been
omitted due to conflicts and will have to be applied separately later.
2021-01-11 09:41:54 +02:00
Vladislav Vaintroub
3b548d3bbf MDEV-24554 Do not use verisign server for authenticode timestamping 2021-01-09 18:34:28 +01:00
Marko Mäkelä
ad436d9221 Merge 10.5 into 10.6 2020-12-21 19:52:49 +02:00
Sergei Golubchik
6529cba2e2 cleanup: plugin.cmake
list all supported options in the comment.
remove wsrep-specific hack of EXPORT_SYMBOLS, wsrep-specific hacks
belong to wsrep
2020-12-21 14:04:32 +01:00
Marko Mäkelä
c36a2a0d1c Merge 10.5 into 10.6 2020-12-17 14:56:08 +02:00
Etienne Guesnet
a6e90992c1 Add LARGE_FILES flag for GCC AIX build 2020-12-16 08:07:04 +11:00
Etienne Guesnet
1d7fc7280e Add flags for AIX build 2020-12-16 08:07:04 +11:00
Etienne Guesnet
b23e545773 Remove -Werror for AIX 2020-12-16 08:07:04 +11:00
Etienne Guesnet
2f5d372444 Add build on AIX 2020-12-16 08:07:04 +11:00
Marko Mäkelä
a62a675fd2 Merge 10.5 into 10.6 2020-11-23 17:57:58 +02:00
Daniel Black
3b486c28f7 MDEV-24125: linux large pages, linux/mman.h needed
Centos/RHEL7 have the MAP_HUGE_SHIFT constant
defined in linux/mman.h which needed to get included.
2020-11-19 16:30:17 +11:00
Vladislav Vaintroub
f950559f66 Windows : reduce useless system checks 2020-11-12 21:26:34 +00:00
Marko Mäkelä
c498250888 Merge 10.5 into 10.6 2020-11-03 19:11:36 +02:00
Marko Mäkelä
133b4b46fe Merge 10.4 into 10.5 2020-11-03 16:24:47 +02:00
Marko Mäkelä
533a13af06 Merge 10.3 into 10.4 2020-11-03 14:49:17 +02:00
Marko Mäkelä
c7f322c91f Merge 10.2 into 10.3 2020-11-02 15:48:47 +02:00