* Add BUILD_SHARED_LIBS option to choose between shared and static lib
* Fix build break for Android aarch64
* Install built target
* Set the correct version number
* Don't add include dirs through CFlags. Include dirs are already set as target property
* Install all relevant headers, not just from include dir
* Update note about BUILD_SHARED_LIBS in README.md
* Fix mistake in README.md, option(BUILD_SHARED_LIBS ON) sets the lib to shared by default
* openlibm_fenv.h: fix PowerPC macro for Darwin
* openlibm_fenv_powerpc.h: check if __BYTE_ORDER__ is actually defined
* fpmath.h: fix PowerPC macro for Darwin
* Fix mistake in CMakeLists.txt, only add sources in ld128 if long double isn't the same as double + aarch64
* Update README to mention that cmake build now defaults to shared library
* Add support to build openlibm as a shared library using cmake by not compiling the C implementation when a native one exists
* Add CMake static and shared library build instruction and also added info about support for loongarch64
---------
Co-authored-by: Viral B. Shah <ViralBShah@users.noreply.github.com>
* Add CMakeLists file to build with CMake, tested with MinGW on Windows x64 and Apple Clang on MacOS arm64
* Use regex to ensure 'AppleClang' also passes under Clang
These files are derived from the original fdlibm sin/cos files.
While we do already preserve that license notice in LICENSE.md
(so there's no actual license compliance issue here), it's
cleaner to have the copyright notice in the file as well, in
case somebody copies the file out of the repo.
As discussed in https://github.com/JuliaLang/julia/pull/43786, openlibm's sqrt function is incorrectly rounded for i387. IEEE requires correct rounding for these functions and LLVM relies on it. Fix that by setting the precision in the FPU control word (see e.g. e_ceil.S for similar FPU modifications).
Changes needed for riscv64 support have been added.
Code for openlibm_fenv_riscv.h, riscv_fpmath.h and fenv.c
was taken from https://github.com/freebsd/freebsd
* Another Windows ARM64 fix
include stdint.h to be sure that uint64_t can be used.
This header already had references to uint32_t, so I assumed it was safe to use those typedefs, but a compile error revealed it was not always.
* fix munged whitespace
* aarch64_fpmath.h: deal with LLP64 (Windows ARM64)
use uint64_t instead of unsigned long, as unsigned long is only 32 bits on Windows
* Make.inc: WINNT aarch64 long double is double
Add to list along with Darwin
* add msys2 ci job
* run CI on any branch
* install base-devel on msys2
* remove soname and nodefaultlibs flags from mingw
* avoid soname on Windows
* add OLM_DLLEXPORT to signgam
it needs to be exported from the DLL also
* define IMPORT_EXPORTS on WINNT
While there are function export thunks in the import library that allow the linker to do the right thing for functions even if this is not set, it is required for the linker to do the right thing with variables being imported from a DLL (namely, signgam)
* add OLM_DLLEXPORT to openlibm_fenv_i387.h
seems this whole header was overlooked
* Update openlibm_fenv_i387.h
include openlibm_defs.h for OLM_DLLEXPORT