summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Cygwin: Testsuite Makefile cleanupJon Turney2020-11-181-13/+2
| | | | | | Drop unused variables CC_FOR_TARGET, GCC_INCLUDE, ALL_CFLAGS Stop exporting CC, CFLAGS Drop unused, empty targets force, dll_ofiles, all_target
* Cygwin: Fix 'make check' in utilsJon Turney2020-11-183-10/+12
| | | | | | | | | | | | | | This has a test of the path translation code used in various utilities (mount, cygpath, strace). MOUNT_BINARY is replaced with the absence of MOUNT_TEXT since 26e0b37e. The issys member of mnt_t struct was removed in b677a99b. > $ make check [...] > total tests: 63 > pass : 63 (100.0%) > fail : 0 (0.0%)
* Cygwin: Drop duplicate C++ flags used to build utilsJon Turney2020-11-181-1/+1
| | | | | | '-fno-exceptions -fno-rtti' are already present in the compile command COMPILE.cc set by Makefile.common, so we don't need to add them to CXXFLAGS as well.
* Cygwin: Use grep in text mode to look for version stringsJon Turney2020-11-181-1/+1
| | | | | | | Invoke grep in text mode when looking for version strings inside the cygwin DLL, so it outputs something more informative than: Binary file ../cygwin/cygwin0.dll matches
* RISC-V: Add machine-specific implementation for lrint[f], lround[f], ↵Kito Cheng2020-11-1810-3/+503
| | | | llrint[f] and llround[f].
* RISC-V: Add machine-specific implementation for isnan[f] and copysign[f]Kito Cheng2020-11-186-3/+237
|
* RISC-V: Add missing compile rule for s_finite.c, sf_finite.c, s_isinf.c and ↵Kito Cheng2020-11-182-3/+33
| | | | sf_isinf.c
* malloc/nano-malloc: correctly check for out-of-bounds allocation reqsCorinna Vinschen2020-11-173-2/+31
| | | | | | | | | | | | The overflow check in mEMALIGn erroneously checks for INT_MAX, albeit the input parameter is size_t. Fix this to check for __SIZE_MAX__ instead. Also, it misses to check the req against adding the alignment before calling mALLOc. While at it, add out-of-bounds checks to pvALLOc, nano_memalign, nano_valloc, and Cygwin's (unused) dlpvalloc. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
* Fix return type of __locale_ctype_ptr_l()Sebastian Huber2020-11-161-1/+1
| | | | | | | This prevents warnings like this: ctype.h:118:9: warning: return discards 'const' qualifier from pointer target type
* Cygwin: testsuite: fix insecure usage of printf in libltpCorinna Vinschen2020-11-161-1/+1
| | | | Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
* libc/include/newlib.h: Fix C++ compilation issueJoel Sherrill2020-11-161-2/+2
|
* Cygwin: path_conv::eq_worker: add NULL pointer checksKen Brown2020-11-161-2/+4
| | | | | | | Don't call cstrdup on NULL pointers. This fixes a crash that was observed when cloning an fhandler whose path_conv member had freed its strings.
* Cygwin: Fix testsuite tmpdir creation with non-default cygdrive prefixJon Turney2020-11-122-5/+7
|
* Cygwin: fhandler_fifo: reduce sizeKen Brown2020-11-092-9/+14
| | | | | | | | | | Replace the 'WCHAR pipe_name_buf[48]' class member by 'PWCHAR pipe_name_buf', and allocate space for the latter as needed. Change the default constructor to accommodate this change, and add a destructor that frees the allocated space. Also change get_pipe_name and clone to accommodate this change.
* Cygwin: Ensure temporary directory used by tests existsJon Turney2020-11-083-4/+15
| | | | | | | | | | | | | | | By default, libltp tests will create temporary files in a subdirectory of /tmp, which will (nowadays) be located relative to the test DLL (by assuming that it is in /bin). This will evaluate to the directory $target_builddir/winsup/tmp, which doesn't exist. The location used for these temporary files can be explicitly controlled by setting the TDIRECTORY env var. Arrange to set that env var to the /cygdrive path of a tmp subdirectory of the build directory. Unfortunately, libltp doesn't clean the temporary directory if TDIRECTORY is set, and some tests assume they are started in a clean directory, so we need to do that in tcl.
* Cygwin: Set PATH for tests to pick up cygwin0.dllJon Turney2020-11-081-0/+2
| | | | | | Set the PATH so that tests can pick up cygwin0.dll. Looks like this was dropped by accident in 2e488e95 ("Don't rely on in-build tools"), so restore it as it was prior to 9d89f634.
* Cygwin: Check exit code of a test, rather than stdoutJon Turney2020-11-081-7/+13
| | | | | In winsup.exp, don't consider a command failed if it produced any output (e.g. if the compiler produced warnings). Instead check the exit code.
* Cygwin: Use absolute path to libltp includesJon Turney2020-11-081-1/+1
| | | | | Use an absolute path to libltp includes, to allow for the fact that we'll be compiling tests in a subdirectory.
* Cygiwn: Detect and use MinGW compilers for testsuite wrappersJon Turney2020-11-084-4/+255
| | | | | | | Drop MINGW_FE, which I can't find any trace of, and instead detect and use MinGW compilers. This requires adding AC_CANONICAL_TARGET, to set $target_cpu.
* Cygwin: Define target_builddir autoconf and Makefile variablesJon Turney2020-11-083-0/+10
| | | | | | | | | This is now required as cygwin_build is defined in terms of target_builddir. (Note that in other subdirectories, the autoconf variable target_builddir is AC_SUBST-ed as a side-effect of using a macro from winsup/acinclude.m4, which is perhaps less than ideal)
* Cygwin: Move adding libltp to VPATH after Makefile.commonJon Turney2020-11-081-2/+2
| | | | Move adding libltp to the VPATH after Makefile.common, which sets VPATH.
* Cygwin: Avoid 'Makefile.in seems to ignore the --datarootdir setting' warningJon Turney2020-11-081-0/+1
| | | | | Avoid a 'Makefile.in seems to ignore the --datarootdir setting' warning when configuring in testsuite directory.
* Cygwin: Add rule to testsuite Makefile to regenerate it when neededJon Turney2020-11-081-0/+3
|
* Cygwin: Always configure in testsuite subdirectoryJon Turney2020-11-083-18/+4
| | | | | Doing this properly using AC_CONFIG_SUBDIRS is necessary to get the correct paths in flags given to the compiler specified in CC/CXX.
* Cygwin: Add testsuite directory to autogen.shJon Turney2020-11-083-832/+5
| | | | Also remove unneeded aclocal.m4 for an old aclocal version.
* Cygwin: FIFO: update_my_handlers: fix handle leakKen Brown2020-11-061-0/+1
|
* Fix 32-bit integer overflow when calculating TZ rulesIvan Grokhotov2020-11-041-1/+1
|
* Cygwin: Drop passing '-c' compiler flag into gentls_offsetsJon Turney2020-11-021-1/+1
| | | | | That script appends a '-E', since we only use $(CC) to preprocess, and thus adding '-c' is having no effect.
* Cygwin: Remove rules for building libcygwin_s.aJon Turney2020-11-022-76/+0
| | | | Untouched since added in 66a83f3e, and described as 'non-working'.
* Cygwin: Remove Makefile contents conditional on PREPROCESS, which is never ↵Jon Turney2020-11-021-7/+0
| | | | defined
* Cygwin: Drop autoconf variable all_hostJon Turney2020-11-025-54/+2
| | | | | | | | The autoconf variable all_host is used to make building of the stub library used by the testsuite conditional on not cross-compiling. Make it unconditional, so we will notice if it's broken when cross-compiling.
* Cygwin: Remove autoconf variable DLL_NAMEJon Turney2020-11-023-9/+2
| | | | | Remove autoconf variable DLL_NAME, which has a constant value which is only used in one place.
* Cygwin: Drop AC_SUBST(build_exeext)Jon Turney2020-11-021-2/+0
| | | | | The autoconf variable build_exeext isn't defined, and (since the doc subdirectory doesn't build any executables) it's value isn't used.
* Cygwin: Remove intro2man.stamp on cleanJon Turney2020-11-021-2/+3
|
* Revert "Cygwin: gendef generates sigfe.s and cygwin.def"Jon Turney2020-10-301-2/+5
| | | | | | | This reverts commit 74a164f1c162645f4389bbd9edb2f89a630853af. Shame we can't use '&:' for a grouped target here, since that requires GNU make 4.3
* RISC-V: Fix wrong including file in s_isinf.cKito Cheng2020-10-291-1/+1
|
* RISC-V: NaN should return 0 for finite[f]Kito Cheng2020-10-292-2/+2
|
* Cygwin: Restore setting CC and CXX Makefile variablesJon Turney2020-10-283-0/+10
| | | | | | | | | | | b55e3f19 was a bit too aggressive in dropping, rather than just un-exporting these Makefile variables. We need to set these to the configured host compiler if we are cross-compiling, otherwise they default to the build compiler. Also export CC to the mkvers.sh script (which requires it since 4eca5e6a). It's unclear why we can't just cause windres to use the build 'cpp' as the pre-processor there.
* libc/sys/rtems/include/machine/_types.h: Define daddr_t to be 64 bits for RTEMSJoel Sherrill2020-10-281-0/+3
| | | | | This type needs to be able to represent a position on a disk or file system.
* Cygwin: fix return value of sqrtl on negative infinityKen Brown2020-10-272-2/+8
| | | | | | | | | | | | The return value is now -NaN. This fixes a bug in the mingw-w64 code that was imported into Cygwin. The fix is consistent with Posix and Linux. It is also consistent with the current mingw-w64 code, with one exception: The mingw-w64 code sets errno to EDOM if the input is -NaN, but this appears to differ from Posix and Linux. Addresses: https://cygwin.com/pipermail/cygwin/2020-October/246606.html
* Cygwin: pty: Disable ResizePseudoConsole() if stdout is redirected.Takashi Yano via Cygwin-patches2020-10-273-2/+8
| | | | | | | | - Calling ResizePseudoConsole() generates some escape sequences. Due to this behaviour, if the output of non-cygwin app is piped to less, screen is sometimes distorted when the screen is resized. With this patch, ResizePseudoConsole() is not called if stdout is redirected.
* RISC-V: Implment finite and fpclassifyKito Cheng2020-10-279-3/+421
|
* RISC-V: Add fabs[f], fmax[f] and fmin[f].Kito Cheng2020-10-278-3/+345
|
* Define RB_SET_PARENT to do all assignmentsdougm2020-10-261-30/+28
| | | | | | | | | | | | | | | to rb parent pointers. Define RB_SWAP_CHILD to replace the child of a parent with its twin, and use it in 4 places. Use RB_SET in rb_link_node to remove the only linuxkpi reference to color, and then drop color- and parent-related definitions that are defined and used only in rbtree.h. This is intended to be entirely cosmetic, with no impact on program behavior, and leave RB_PARENT and RB_SET_PARENT as the only ways to read and write rb parent pointers. Reviewed by: markj, kib Tested by: pho Differential Revision: https://reviews.freebsd.org/D25264
* In concluding RB_REMOVE_COLOR, in the case whendougm2020-10-261-15/+11
| | | | | | | | | | | | the sibling of the root of the too-short tree is black and at least one of the children of that sibling is red, either one or two rotations finish the rebalancing. In the case when both of the children are red, the current implementation uses two rotations where only one is necessary. This change removes that extra rotation, and in that case also removes a needless black-to-red-to-black recoloring. Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D25335
* Linuxkpi uses the rb-tree structuresdougm2020-10-261-148/+137
| | | | | | | | | without using their interfaces, making them break when the representation changes. Revert changes that eliminated the color field from rb-trees, leaving everything as it was before. Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D25250
* Fixup r361997 by balancing parens. Duh.dougm2020-10-261-1/+1
|
* Restore an RB_COLOR macro, for the benefit ofdougm2020-10-261-0/+6
| | | | | | | | a bit of DIAGNOSTIC code that depends on it. Reported by: rpokala, mjguzik Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D25204
* To reduce the size of an rb_node, drop the colordougm2020-10-261-138/+143
| | | | | | | | | | | | | | field. Set the least significant bit in the pointer to the node from its parent to indicate that the node is red. Have the tree rotation macros leave the old-parent/new-child node red and the new-parent/old-child node black. This change makes RB_LEFT and RB_RIGHT no longer assignable, and RB_COLOR no longer defined. Any code that modifies the tree or examines a node color would have to be modified after this change. Reviewed by: markj Tested by: pho Differential Revision: https://reviews.freebsd.org/D25105
* Remove from RB_REMOVE_COLOR some null checksdougm2020-10-261-26/+20
| | | | | | | | | where the pointer checked is provably never null. Restructure the surrounding code just enough to make the non-nullness obvious. Reviewed by: markj Tested by: pho Differential Revision: https://reviews.freebsd.org/D25089