Commit graph

1822 commits

Author SHA1 Message Date
Julius Goryavsky
41b036bff0 This commit adds package dependencies for socat
which is needed for testing galera.
2024-10-17 03:21:51 +02:00
Daniel Black
e927e28ebe Remove HAVE_BROKEN_REALPATH
Was only applicable to FreeBSD < ~5.1.9
per: 33173fbe82
2024-10-16 11:46:19 +11:00
Sergei Golubchik
d5f5062a48 our release packages on rhel8 use bundled readline
for historical reasons, but we keep doing it for compatibility
2024-10-14 13:09:20 +02:00
Sergei Golubchik
566c22e814 pcre.cmake: always check the library with check_library_exists()
even if pkg-config has it. otherwise build dependencies
aren't detected.
2024-09-05 12:14:06 +10:00
Sergei Golubchik
b2ebe1cb7b MDEV-33091 pcre2 headers aren't found on Solaris
use pkg-config to find pcre2, if possible

rename PCRE_INCLUDES to use PKG_CHECK_MODULES naming, PCRE_INCLUDE_DIRS
2024-09-05 12:14:06 +10:00
Daniel Black
c991efd9c3 MDEV-34825 FreeBSD fails to build under clang natively
clang doesn't have /usr/local/lib in the path. As such
there are various depedency linkages that will fail.

For example pcre and libfmt.`
2024-09-05 12:14:06 +10:00
Vladislav Vaintroub
b619be3569 Support -DCONC_WITH_SSL parameter passed to CMake
Usually it is not needed, but sometimes we need to testing interoperability,
e.g OpenSSL server / SCHANNEL client, or WolfSSL server / OpenSSL client.
2024-08-09 01:15:45 +02:00
Andre F de Miranda
83040474dc MDEV-34234: make lsof optional on RPM
Signed-off-by: Julius Goryavsky <julius.goryavsky@mariadb.com>
2024-08-04 17:44:08 +02:00
Oleksandr Byelkin
7478fabcff new PCRE2-10.44 2024-07-17 13:04:24 +02:00
Daniel Black
54b7a879e9 MDEV-34313 WITHOUT_SERVER/WSREP postfix
Mismatched IF/ENDIF statements in cmake
caused a warning.
2024-06-29 10:24:09 +10:00
Daniel Black
d5bad49011 MDEV-34313: compile WITHOUT_SERVER and WSREP=ON
CMake WSREP=ON has some implications for client
executables so still present this as an option
when compiling WITHOUT_SERVER. In this case
default to ON for maximium compatibility of
the build client executables and libraries.
2024-06-26 12:42:25 +10:00
Dave Gosselin
db0c28eff8 MDEV-33746 Supply missing override markings
Find and fix missing virtual override markings.  Updates cmake
maintainer flags to include -Wsuggest-override and
-Winconsistent-missing-override.
2024-06-20 11:32:13 -04:00
Sergei Golubchik
7e65512ecc cleanup: compile with -fno-operator-names in maintainer mode 2024-05-14 13:37:59 +02:00
Vladislav Vaintroub
029e2a5fd9 MDEV-33876 CMake, zlib - use names compatible with official FindZLIB.cmake
- ZLIB_LIBRARIES, not ZLIB_LIBRARY
- ZLIB_INCLUDE_DIRS, not ZLIB_INCLUDE_DIR

For building libmariadb, ZLIB_LIBRARY/ZLIB_INCLUDE_DIR are still defined
This workaround will be removed later.
2024-05-03 21:48:47 +02:00
Vladislav Vaintroub
20f60fe70f postfix a09ebe5567 (PCRE-10.43)
- no need to switch off -fsanitize-address for MSVC anymore
- option /WX is MSVC only
- CMAKE_C_STANDARD C99 is already in pcre's own CMakeLists.txt
2024-05-02 22:13:48 +02:00
Dimitri John Ledkov
bf77f9793d openssl: add a more specific DES support detection
Improve detection for DES support in OpenSSL, to allow compilation
against system OpenSSL without DES.

Note that MariaDB needs to be compiled against OpenSSL-like library
that itself has DES support which cmake detected. Positive detection
is indicated with CMake variable HAVE_des 1.

Signed-off-by: Dimitri John Ledkov <dimitri.ledkov@surgut.co.uk>
2024-04-30 23:09:02 +10:00
Oleksandr Byelkin
a09ebe5567 PCRE2-10.43
pcre2 - fix CMAKE_C_FLAGS for MSVC for external project by Vladislav Vaintroub <vvaintroub@gmail.com>
2024-04-28 18:09:13 +02:00
Meng-Hsiu Chiang
55cb2c2916 MDEV-29955: Set path for zlib library with pkg-config
`FindZLIB` module uses variable `ZLIB_ROOT`[1] to look for libraries. By
setting the variable, `FindZLIB` is able to search the libraries that
installed in a non-system path (/workspace/mylib for example).

And when using `z` in `LINK_LIBRARIES()` CMake tries to lookup the
library in system path by default. It doesn't work if the library isn't
installed in the path, and use ${ZLIB_LIBRARY} which set by FindZLIB
solve the issue.

All new code of the whole pull request, including one or several files
that are either new files or modified ones, are contributed under the
BSD-new license. I am contributing on behalf of my employer Amazon Web
Services.

[1]: https://cmake.org/cmake/help/latest/module/FindZLIB.html#hints
2024-04-23 15:40:57 +01:00
Vladislav Vaintroub
e87a175b3a Fix LTO (aka interprocedural optimization) build with MSVC
Also, disable MSVC LTO for static client libraries - they won't be usable
for end-users.
2024-04-17 16:18:44 +02:00
Daniel Black
ee2ed1a036 Revert "MDEV-33636: RPM caps is on mariadbd exe"
This was the orginal implementation that reverted with a bunch of
commits.

This reverts commit a13e521bc5.

Revert "cmake: append to the array correctly"
This reverts commit 51e3f1daf5.

Revert "build failure with cmake < 3.10"
This reverts commit 49cf702ee5.

Revert "MDEV-33301 memlock with systemd still not working"
This reverts commit 8a1904d782.
2024-03-27 13:36:31 +11:00
Daniel Black
a13e521bc5 MDEV-33636: RPM caps is on mariadbd exe
Postfix on 51e3f1daf5 that
mariadbd should be the executable name rather than capabilities
on a symlink.
2024-03-19 09:15:03 +11:00
Sergei Golubchik
51e3f1daf5 cmake: append to the array correctly
it was generating broken spec files
2024-03-14 19:11:18 +01:00
Sergei Golubchik
49cf702ee5 build failure with cmake < 3.10
cmake bug #14362
2024-03-14 11:43:13 +01:00
Vladislav Vaintroub
d510f80549 MDEV-33482: Optimize WolfSSL for improved performance
- Use "new" math library WOLFSSL_SP_MATH_ALL, which is now  promoted by
  WolfSSL for faster performance. "fastmath" we  used previously is going
  to be deprecated, it was not really always fast.
- Optimize common RSA math operations with WOLFSSL_HAVE_SP_RSA
- Incorporate assembly optimizations, currently for Intel x64 only

This patch significantly reduces execution time for SSL tests like
main.ssl-big and main.ssl_connect, which now run 2 to 3 times faster.

Notably, when this patch is applied to 11.4, server startup in with
ephemeral certificates becomes approximately 10x faster due to optimized
wolfSSL_EVP_PKEY_keygen().

Additionally, refactored WolfSSL by removing old workarounds and
consolidating wolfssl and wolfcrypt into a single library wolfssl, just
like it was done in WolfSSL's own CMake.
2024-02-18 01:10:41 +01:00
Daniel Black
8a1904d782 MDEV-33301 memlock with systemd still not working
CapabilityBoundingSet included CAP_IPC_LOCK in MDEV-9095, however
it requires that the executable has the capability marked in extended
attributes also.

The alternate to this is raising the RLIMIT_MEMLOCK for the service/
process to be able to complete the mlockall system call. This needs to
be adjusted to whatever the MariaDB server was going to allocate.
Rather than leave the non-obvious mapping of settings and tuning,
add the capability so its easier for the user.

We set the capability, if possible, but may never be used depending
on user settings. As such in the Debian postinst script, don't
complain if this fails.

The CAP_IPC_LOCK also facilitates the mmaping of huge memory pages.
(see man mmap), like mariadb uses with --large-pages.
2024-02-15 12:58:13 +11:00
Sergei Golubchik
01f6abd1d4 Merge branch '10.4' into 10.5 2024-01-31 17:32:53 +01:00
Vladislav Vaintroub
b62f25c650 MDEV-26579 fixup 2024-01-26 00:15:13 +01:00
Vladislav Vaintroub
0f59810b99 MDEV-26579 Support minor MSI in Windows installer.
With this patch, 4-component MSI version can be used, e.g by setting
TINY_VERSION variable in CMake, or by adding a string, e.g
MYSQL_VERSION_EXTRA=-2
which sets TINY_VERSION to 2, and also changes the package name.

The 4-component MSI versions do not support MSI major upgrades, only minor
ones, i.e do not reinstall components, just update existing ones based
on versioning rules.

To support these rules, add DefaultVersion for the files that won't
otherwise be versioned - headers, static and import libraries,
pdbs, text - xml, python and perl scripts Also silence WiX warning
that MSI won't store hashes for those files anymore.
2024-01-26 00:15:13 +01:00
Daniel Black
3699a7e1a9 macos: Fix CMAKE_OSX_ARCHITECTURES when not set
When CMAKE_OSX_ARCHITECTURES isn't set we end up with
"Packaging as: mariadb-10.4.33-osx10.19-x86_64" on arm64 builders.

Instead of implying 64bit is x86, use CMAKE_SYSTEM_PROCESSOR to form
the filename.
2024-01-24 10:01:15 +11:00
Vicențiu Ciorbaru
7c2f082222
Improve READLINE_V5 detection
More in depth check to cover all used readline functions.
2024-01-23 18:38:22 +02:00
Sergei Golubchik
761d5c8987 MDEV-33092 Undefined reference to concurrency on Solaris
remove thr_setconcurrency()
followup for 8bbcaab160

Fix by Rainer Orth
2024-01-10 10:16:20 +01:00
Sergei Golubchik
98a39b0c91 Merge branch '10.4' into 10.5 2023-12-02 01:02:50 +01:00
Faustin Lammler
60c01206df The MariaDB mailing list system has been moved
See: https://mariadb.org/mailing-lists/
2023-11-28 16:30:04 +11:00
Marko Mäkelä
6c05edfdcd Merge 10.4 into 10.5 2023-09-19 10:20:09 +03:00
Marko Mäkelä
d0abbdf56e MDEV-31605 cmake/stack_direction.c does not work correctly on clang 16
According to commit ea56841997
the stack normally grows downwards, except on HP PA-RISC where
it grows upwards. Because determining the stack direction is not
possible in a portable way, let us determine the default STACK_DIRECTION
in CMake based on the ISA.

On clang 16.0.6 running on and targeting AMD64, STACK_DIRECTION=1 is
being incorrectly detected, causing the failure of a number of tests.
2023-09-19 10:14:03 +03:00
Oleksandr Byelkin
f291c3df2c Merge branch '10.4' into 10.5 2023-07-27 15:43:21 +02:00
Geoff Montee
23dae6173c MDEV-18374: Add SELinux policy to cracklib_password_check packages 2023-07-26 11:13:09 +01:00
Oleksandr Byelkin
f52954ef42 Merge commit '10.4' into 10.5 2023-07-20 11:54:52 +02:00
Daniel Black
5f2a77cef1 MDEV-31268 Fedora MariaDB-shared replaces mariadb-connector-c
file /usr/lib64/libmariadb.so.3 from install of MariaDB-shared-10.11.3-1.fc38.x86_64 conflicts with file from package mariadb-connector-c-3.3.5-1.fc38.x86_64
2023-07-04 09:01:01 +10:00
Anel Husakovic
77a229cd2d MDEV-31358: Update description for MariaDB debian/rpm packages
Reviewer: <daniel@mariadb.org>
2023-07-03 17:45:58 +10:00
Sergei Golubchik
e146940ab3 MDEV-31480 RPM packages fail to install because they require /bin/sh for %pretrans
workaround cmake bug #25044

https://gitlab.kitware.com/cmake/cmake/-/issues/25044
2023-06-30 01:28:29 +02:00
heyingquan0030
8de6740a2f MDEV-31205 Typo: complatible > compatible 2023-06-05 09:16:44 +10:00
Sergei Golubchik
dc9498beb6 Revert "MDEV-31230: Fix CONNECT_JDBC in CMake"
This reverts commit 1d0e3d80d8.
2023-06-02 09:02:41 +02:00
Anel Husakovic
1d0e3d80d8 MDEV-31230: Fix CONNECT_JDBC in CMake
- Fix feature summary
- Use native CMake module instead of `CMAKE_MODULE_PATH`
- Make Java and JNI package as required

Reviewer: <daniel@mariadb.org>
2023-05-31 11:58:46 +02:00
Daniel Black
c0adb05b30 MDEV-31268: Fedora mariadb-connector-c-config conflicts with MariaDB's MariaDB-common
The previous fix in MDEV-24629 had a version end of life date.

Thanks @pgnd on Zulip for noticing.
2023-05-22 16:54:42 +10:00
Oleksandr Byelkin
a977054ee0 Merge branch '10.3' into 10.4 2023-01-28 18:22:55 +01:00
Oleksandr Byelkin
7fa02f5c0b Merge branch '10.4' into 10.5 2023-01-27 13:54:14 +01:00
Oleksandr Byelkin
dd24fa3063 Merge branch '10.3' into 10.4 2023-01-26 10:34:26 +01:00
Vladislav Vaintroub
2279dddad6 MDEV-30457 Windows, signtool error "No file digest algorithm specified."
Add /fd parameter. It is now mandatory for the recent versions of
signtool
2023-01-24 20:51:53 +01:00
Oleksandr Byelkin
da798c9511 new PCRE2 10.42 2023-01-18 15:52:51 +01:00