What happens with these libraries if you don't set BUILD_SHARED_LIBS to ON?
re-building to check that right now ...
for the build/install itself: (1) -DBUILD_SHARED_LIBS=1 ls -al /usr/local/mariadb/lib64 total 876K drwxr-xr-x 2 root root 4.0K Aug 2 07:41 ./ drwxr-xr-x 13 root root 4.0K Aug 2 07:42 ../ -rw-r--r-- 1 root root 473K Aug 2 07:17 libmariadbclient.a lrwxrwxrwx 1 root root 15 Aug 2 07:41 libmariadb.so -> libmariadb.so.3* -rwxr-xr-x 1 root root 364K Aug 2 07:17 libmariadb.so.3* lrwxrwxrwx 1 root root 18 Aug 2 07:41 libmysqlclient.a -> libmariadbclient.a lrwxrwxrwx 1 root root 18 Aug 2 07:41 libmysqlclient_r.a -> libmariadbclient.a lrwxrwxrwx 1 root root 15 Aug 2 07:41 libmysqlclient_r.so -> libmariadb.so.3* lrwxrwxrwx 1 root root 15 Aug 2 07:41 libmysqlclient.so -> libmariadb.so.3* -rw-r--r-- 1 root root 25K Aug 2 07:16 libmysqlservices.a mysqld -V mysqld: error while loading shared libraries: libwsrep-lib.so: cannot open shared object file: No such file or directory ldd /usr/local/mariadb/bin/mysqld | grep wsrep libwsrep-lib.so => not found libwsrep_api_v26.so => not found ls /usr/local/lib64/galera/* /usr/local/lib64/galera/libgalera_smm.so* cp -af \ ./wsrep-lib/src/libwsrep-lib.so \ ./wsrep-lib/wsrep-API/libwsrep_api_v26.so \ /usr/local/lib64/galera/ mysqld -V mysqld Ver 10.4.8-MariaDB-log for Linux on x86_64 (Source distribution) (2) -DBUILD_SHARED_LIBS=0 ls -al /usr/local/mariadb/lib64 total 900K drwxr-xr-x 2 root root 4.0K Aug 2 08:49 ./ drwxr-xr-x 13 root root 4.0K Aug 2 08:49 ../ -rw-r--r-- 1 root root 488K Aug 2 08:37 libmariadbclient.a lrwxrwxrwx 1 root root 15 Aug 2 08:49 libmariadb.so -> libmariadb.so.3* -rwxr-xr-x 1 root root 376K Aug 2 08:37 libmariadb.so.3* lrwxrwxrwx 1 root root 18 Aug 2 08:49 libmysqlclient.a -> libmariadbclient.a lrwxrwxrwx 1 root root 18 Aug 2 08:49 libmysqlclient_r.a -> libmariadbclient.a lrwxrwxrwx 1 root root 15 Aug 2 08:49 libmysqlclient_r.so -> libmariadb.so.3* lrwxrwxrwx 1 root root 15 Aug 2 08:49 libmysqlclient.so -> libmariadb.so.3* -rw-r--r-- 1 root root 25K Aug 2 08:37 libmysqlservices.a ls /usr/local/lib64/galera/* /usr/local/lib64/galera/libgalera_smm.so* ldd /usr/local/mariadb/bin/mysqld | grep wsrep (empty) mysqld -V mysqld Ver 10.4.8-MariaDB-log for Linux on x86_64 (Source distribution) Don't yet know what, if any, runtime or downstream effect this'll have. IIUC, the requirement is that libwsrep is always/only statically built? If so, set it explicitly?