summaryrefslogtreecommitdiff
path: root/configure.cmake
Commit message (Collapse)AuthorAgeFilesLines
* Fix riscv64 build failure by linking correctly with pthreadbb-10.3-ottok-MDEV-23892-pthreadOtto Kekäläinen2021-04-151-0/+1
| | | | | | | | | Link with -pthread instead of -lpthread, and do that for all architectures. Contributors: Aurelien Jarno <aurelien@aurel32.net> Closes: #1717
* Merge 10.2 into 10.3Marko Mäkelä2021-03-271-0/+1
|\
| * Replace mallinfo with mallinfo2 on supported systemsMichael Okoko2021-03-271-0/+1
| | | | | | | | | | | | | | `mallinfo` is deprecated since glibc 2.33 and has been replaced by mallinfo2. The deprecation causes building the server to fail if glibc version is > 2.33. Check if mallinfo2 exist on the system and use it instead.
* | cleanup: use predefined CMAKE_DL_LIBSSergei Golubchik2020-10-231-2/+1
| | | | | | | | instead of, say, MY_SEARCH_LIBS(dlopen dl LIBDL)
* | Merge branch '10.2' into 10.3Oleksandr Byelkin2020-08-031-8/+0
|\ \ | |/
| * Merge branch '10.1' into 10.2Oleksandr Byelkin2020-08-021-8/+0
| |\
| | * MDEV-15961: Fix stacktraces under FreeBSD (aarch64)Karthik Kamath2020-07-281-8/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Largely based on MySQL commit https://github.com/mysql/mysql-server/commit/75271e51d60bce8683423b208cbb43b11ca6060e MySQL Ref: BUG#24566529: BACKPORT BUG#23575445 TO 5.6 (cut) Also, the PTR_SANE macro which tries to check if a pointer is invalid (used when printing pointer values in stack traces) gave false negatives on OSX/FreeBSD. On these platforms we now simply check if the pointer is non-null. This also removes a sbrk() deprecation warning when building on OS X. (It was before only disabled with building using XCode). Removed execinfo path of MySQL patch that was already included. sbrk doesn't exist on FreeBSD aarch64. Removed HAVE_BSS_START based detection and replaced with __linux__ as it doesn't exist on OSX, Solaris or Windows. __bss_start exists on mutiple Linux architectures. Tested on FreeBSD and Linux x86_64. Being in FreeBSD ports for 2 years implies a good testing there on all FreeBSD architectures there too. MySQL-8.0.21 code is functionally identical to original commit.
* | | Merge branch '10.2' into 10.3Oleksandr Byelkin2020-03-061-0/+1
|\ \ \ | |/ /
| * | Clean wrong cherry-pick from previous commitAnel Husakovic2020-02-201-1/+0
| | | | | | | | | | | | | | | - Delete variable HAVE_PTHREAD_CONDATTR_SETCLOCK and check - Delete second HAVE_PTHREAD_KEY_DELETE
| * | my_getncpus based on threads availableDaniel Black2020-02-201-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Detecting the cpus based on sysconf of the online CPUs can significantly over estimate the number of cpus available. Wheither via numactl, cgroups, taskset, systemd constraints, docker containers and probably other mechanisms, the number of threads mysqld can be run on can be quite less. As such we use the pthread_getaffinity_np function on Linux and FreeBSD (identical API) to get the number of CPUs. The number of CPUs is the default for the thread_pool_size and a too high default will resulting in large memory usage and high context switching overhead. Closes PR #922
| * | MDEV-21082: isnan/isinf compilation errors, isfinite warnings on MacOSVlad Lesin2019-11-191-11/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The fix consists of three commits backported from 10.3: 1) Cleanup isnan() portability checks (cherry picked from commit 7ffd7fe9627d1f750a3712aebb4503e5ae8aea8e) 2) Cleanup isinf() portability checks Original problem reported by Wlad: re-compilation of 10.3 on top of 10.2 build would cache undefined HAVE_ISINF from 10.2, whereas it is expected to be 1 in 10.3. std::isinf() seem to be available on all supported platforms. (cherry picked from commit bc469a0bdf85400f7a63834f5b7af1a513dcdec9) 3) Use std::isfinite in C++ code This is addition to parent revision fixing build failures. (cherry picked from commit 54999f4e75f42baca484ae436b382ca8817df1dd)
* | | MDEV-19845: Adaptive spin loopsMarko Mäkelä2019-06-271-26/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Starting with the Intel Skylake microarchitecture, the PAUSE instruction latency is about 140 clock cycles instead of earlier 10. On AMD processors, the latency could be 10 or 50 clock cycles, depending on microarchitecture. Because of this big range of latency, let us scale the loops around the PAUSE instruction based on timing results at server startup. my_cpu_relax_multiplier: New variable: How many times to invoke PAUSE in a loop. Only defined for IA-32 and AMD64. my_cpu_init(): Determine with RDTSC the time to run 16 PAUSE instructions in two unrolled loops according, and based on the quicker of the two runs, initialize my_cpu_relax_multiplier. This form of calibration was suggested by Mikhail Sinyavin from Intel. LF_BACKOFF(), ut_delay(): Use my_cpu_relax_multiplier when available. ut_delay(): Define inline in my_cpu.h. UT_COMPILER_BARRIER(): Remove. This does not seem to have any effect, because in our ut_delay() implementation, no computations are being performed inside the loop. The purpose of UT_COMPILER_BARRIER() was to prohibit the compiler from reordering computations. It was not emitting any code.
* | | Merge 10.2 into 10.3Marko Mäkelä2019-05-141-1/+1
|\ \ \ | |/ /
| * | Merge 10.1 into 10.2Marko Mäkelä2019-05-131-1/+1
| |\ \ | | |/
| | * Merge branch '5.5' into 10.1Vicențiu Ciorbaru2019-05-111-1/+1
| | |\
| | | * Update FSF AddressVicențiu Ciorbaru2019-05-111-1/+1
| | | | | | | | | | | | | | | | * Update wrong zip-code
* | | | Merge branch '10.2' into bb-10.3-mergeOleksandr Byelkin2019-02-191-1/+1
|\ \ \ \ | |/ / /
| * | | Merge branch '10.1' into 10.2Oleksandr Byelkin2019-02-191-1/+1
| |\ \ \ | | |/ /
| | * | Don't build aws_key_management plugin by defaultSergei Golubchik2019-02-191-1/+1
| | | |
* | | | Merge 10.2 into 10.3Marko Mäkelä2018-11-061-4/+7
|\ \ \ \ | |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | main.derived_cond_pushdown: Move all 10.3 tests to the end, trim trailing white space, and add an "End of 10.3 tests" marker. Add --sorted_result to tests where the ordering is not deterministic. main.win_percentile: Add --sorted_result to tests where the ordering is no longer deterministic.
| * | | Merge 10.1 into 10.2Marko Mäkelä2018-11-061-4/+7
| |\ \ \ | | |/ /
| | * | cmake: fix ucontext detectionBernd Kuhls2018-10-171-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On some archs uclibc does not provide the ucontext structure despite providing ucontext.h, for details see https://git.buildroot.net/buildroot/commit/?id=f1cbfeea95e6287c7a666aafc182ffa318eff262 This patch improves the detection of ucontext by making sure that HAVE_UCONTEXT_H is only set when makecontext() was found. Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
* | | | Cleanup log2() portability checksSergey Vojtovich2018-05-261-2/+0
| | | |
* | | | Cleanup rint() portability checksSergey Vojtovich2018-05-261-1/+0
| | | |
* | | | Cleanup isnan() portability checksSergey Vojtovich2018-05-261-1/+0
| | | |
* | | | Cleanup isinf() portability checksSergey Vojtovich2018-05-261-10/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Original problem reported by Wlad: re-compilation of 10.3 on top of 10.2 build would cache undefined HAVE_ISINF from 10.2, whereas it is expected to be 1 in 10.3. std::isinf() seem to be available on all supported platforms.
* | | | remove check for finite/isfiniteHoward Su2018-05-241-6/+0
| | | | | | | | | | | | | | | | | | | | finite is not used anymore in code base. isfinite is part of C99 and we assume we only support compilers that support C99.
* | | | MDEV-8743: use mkostemp when available with O_CLOEXECDaniel Black2018-05-211-0/+1
| | | | | | | | | | | | | | | | Closes #639
* | | | MDEV-15583 create_temp_file: remove tempnam implementationDaniel Black2018-05-211-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In the spirit of the man page "Never use this function." lets purge off this implementation. mkstemp is a widely available alternative. Closes #661.
* | | | Merge branch '10.2' into 10.3Sergei Golubchik2018-03-281-0/+3
|\ \ \ \ | |/ / /
| * | | Merge remote-tracking branch 'origin/10.1' into 10.2Vicențiu Ciorbaru2018-03-161-0/+3
| |\ \ \ | | |/ /
| | * | fix ucontext configure checkTimo Teräs2018-03-141-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | musl ships the header for other purposes, but makecontext is not implemented. fix the check to detect if makecontext is implemented before enabling code using it.
* | | | Make possible to use clang on Windows (clang-cl)Vladislav Vaintroub2018-02-201-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | -DWITH_ASAN can be used as well now, on x64 Fix many clang-cl warnings.
* | | | Merge bb-10.2-ext into 10.3Marko Mäkelä2018-02-151-1/+11
|\ \ \ \
| * \ \ \ Merge remote-tracking branch 'origin/10.2' into bb-10.2-extAlexander Barkov2018-02-081-1/+11
| |\ \ \ \ | | |/ / /
| | * | | Merge branch 'github/10.1' into 10.2Sergei Golubchik2018-02-061-1/+11
| | |\ \ \ | | | |/ /
| | | * | Merge branch 'github/10.0' into 10.1Sergei Golubchik2018-02-021-1/+11
| | | |\ \
| | | | * \ Merge remote-tracking branch '5.5' into 10.0Vicențiu Ciorbaru2018-01-241-1/+11
| | | | |\ \ | | | | | |/
| | | | | * MDEV-14229: Stack trace is not resolved for shared objectsVicențiu Ciorbaru2018-01-191-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Resolving a stacktrace including functions in dynamic libraries requires us to look inside the libraries for the symbols. Addr2line needs to be started with the correct binary for each address on the stack. To do this, figure out which library it is using dladdr, then if the addr2line binary was started with a different binary, fork it again with the correct one. We only have one addr2line process running at any point during the stacktrace resolving step. The maximum number of forks for addr2line should generally be around 6. One for server stacktrace code, one for plugin code, one when going back into server code, one for pthread library, one for libc, one for the _start function in the server. More can come up if plugin calls server function which goes back to a plugin, etc.
| | | | | * MDEV-14469 build with cmake -DMYSQL_MAINTAINER_MODE=ON fails: 'readdir_r' is ↵Sergei Golubchik2018-01-151-1/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | deprecated 1. test readdir_r() availability under -Werror 2. don't protect readdir() with mutexes, it's not needed for the way we use readdir()
| * | | | | Cleanup UT_LOW_PRIORITY_CPU/UT_RESUME_PRIORITY_CPUSergey Vojtovich2018-01-131-11/+0
| |/ / / / | | | | | | | | | | | | | | | Server already has HMT_low/HMT_medium.
* | | | | Minor spelling fixes in code comments, docs and outputOtto Kekäläinen2018-01-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | This commit does not touch any variable names or any other actual code, and thus should not in any way affect how the code works.
* | | | | Cleanup UT_LOW_PRIORITY_CPU/UT_RESUME_PRIORITY_CPUSergey Vojtovich2017-11-281-11/+0
| | | | | | | | | | | | | | | | | | | | Server already has HMT_low/HMT_medium.
* | | | | MDEV-13656 10.3 does not build on CentOS 5 x86Sergei Golubchik2017-09-011-1/+2
| | | | | | | | | | | | | | | | | | | | followup for 62139dc2e27
* | | | | MDEV-13656 10.3 does not build on CentOS 5 x86Sergei Golubchik2017-08-281-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Force -march=i686 (just like innodb used to do for years). And disable query_response_time plugin, it fails to compile with /mnt/server/plugin/query_response_time/query_response_time.cc:279: error: unable to find a register to spill in class ‘GENERAL_REGS’ /mnt/server/plugin/query_response_time/query_response_time.cc:279: error: this is the insn: (insn:HI 70 69 71 9 /mnt/server/include/my_atomic.h:194 (parallel [ (set (reg:DI 82) (mem/v:DI (plus:SI (reg/f:SI 79) (reg:SI 78)) [-1 S8 A32])) (set (mem/v:DI (plus:SI (reg/f:SI 79) (reg:SI 78)) [-1 S8 A32]) (unspec_volatile:DI [ (mem/v:DI (plus:SI (reg/f:SI 79) (reg:SI 78)) [-1 S8 A32]) (reg:DI 82) (reg:SI 83) (reg:SI 84) ] 10)) (set (reg:CCZ 17 flags) (compare:CCZ (unspec_volatile:DI [ (mem/v:DI (plus:SI (reg/f:SI 79) (reg:SI 78)) [-1 S8 A32]) (reg:DI 82) (reg:SI 83) (reg:SI 84) ] 11) (reg:DI 82))) ]) 1101 {*sync_double_compare_and_swap_ccdi_pic} (insn_list:REG_DEP_TRUE 68 (insn_list:REG_DEP_TRUE 69 (nil))) (expr_list:REG_DEAD (reg:SI 84) (expr_list:REG_DEAD (reg:SI 83) (nil))))
* | | | | Merge remote-tracking branch 'origin/bb-10.2-ext' into 10.3Alexander Barkov2016-12-301-1/+0
|\ \ \ \ \ | |/ / / /
| * | | | Merge branch '10.1' into 10.2Sergei Golubchik2016-12-291-1/+0
| |\ \ \ \ | | |/ / /
| | * | | Merge branch '10.0' into 10.1Sergei Golubchik2016-12-111-1/+0
| | |\ \ \ | | | |/ /
| | | * | Merge branch '5.5' into 10.0Sergei Golubchik2016-12-091-1/+0
| | | |\ \ | | | | |/
| | | | * MDEV-10293 'setupterm' was not declared in this scopeSergei Golubchik2016-12-051-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Check for readline before checking for curses headers, because MYSQL_CHECK_READLINE fails when curses is not found, but CHECK_INCLUDE_FILES simply remembers the fact and continues. So if there's no curses, MYSQL_CHECK_READLINE will abort, the user will then installs curses and continue the build. Thus, CHECK_INCLUDE_HEADERS will remember that there is no curses, but other checks from MYSQL_CHECK_READLINE will remember that curses are there. It will result in inconsistent HAVE_xxx defines.