Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2024-01-24Cygwin: posix_getdents: implement per SUS Base Specifications Issue 8 drafttopic/3.6Corinna Vinschen
- Basically maintain a hidden DIR* inside fhandlers. - lseek has to be tweaked to allow basic seeking on the directory descriptor. - the current implementation does not keep the dir positions between duplicated descriptor in sync. In fact, every descriptor keeps its own copy of the DIR* and after dup/fork/exec, the directory position is reset to 0, i. e., to the start of the directory, as if rewinddir() has been called on the new descriptors. While this behaviour isn't yet covered by the Issue 8 draft, a bug report along these lines exists and will probably be picked up for TC1. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2024-01-24Cygwin: devices.h: drop useless mode checkCorinna Vinschen
use IFTODT to generate type from mode. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2024-01-24Cygwin: dirent.h: make definition of struct __DIR opaqueCorinna Vinschen
The content of DIR should never have been exposed into userspace. Move struct __DIR to local dirent.h and only keep forward declaration in exported dirent.h. This allows to tweak the structure in future, for instance, to add thread-safety. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2024-01-24Cygwin: implement fdclosedirCorinna Vinschen
fdclosedir is BSD-only but already present in dirent.h for a couple of years. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2024-01-24Cygwin: implement dirent.d_reclenCorinna Vinschen
This change is in preparation of adding posix_getdents() from the upcoming POSIX Base Specification Issue 8. - Add d_reclen - Add GLibC compatible test macros for dirent members - Bump dirent version - Set d_reclen to the fixed size of the dirent struct We can do that because the size is a multiple of 8, so it fits snugly in the buffer filled by posix_getdents and keep the alignement. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2024-01-24Cygwin: export getlocalename_lCorinna Vinschen
Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2024-01-24getlocalename_l: implement per SUS Base Specifications Issue 8 draftCorinna Vinschen
#include <locale.h> const char *getlocalename_l(int category, locale_t locobj); Most notably, we need a per-thread space to store the string returned if locobj is LC_GLOBAL_LOCALE. No errors are defined for getlocalename_l. So we can't use buffer allocation which might lead to an ENOMEM error. We have to use a "static" buffer in the per-thread state. Note that the feature test macro in locale.h is not quite correct. This needs to be fixed as soon as the Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2024-01-24Cygwin: path: convert symlink_info to classCorinna Vinschen
encapsulate everything Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2024-01-24Cygwin: files: slightly simplify suffix handlingCorinna Vinschen
- drop appending .exe.lnk to files - drop exe_suffixes, it's the same as stat_suffixes for a long time Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2024-01-24Cygwin: bump DLL version to 3.6.0Corinna Vinschen
Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2024-01-23libgloss: merge cr16 into top-level MakefileMike Frysinger
Avoid a recursive make to speed things up a bit. A cr16-elf build shows installed objects & libs produce same code. The test targets were dropped as they didn't actually work -- there is no test.o rule in here.
2024-01-23configure.ac: configurable tooldir install pathNeal Frager
This patch is required to fix how the newlib headers are installed when using a sysroot install directory. The cross compiler expects headers to be in .../host/usr/arm-none-eabi/sysroot/usr/include/newlib.h by default newlib installed the headers into .../host/usr/arm-none-eabi/sysroot/usr/arm-none-eabi/include/newlib.h ${exec_prefix} provides the .../host/usr/arm-none-eabi/sysroot path ${target_noncanonical} provides an extra arm-none-eabi/ that must be removed. With this patch, users can specify the tooldir path that is needed. Signed-off-by: Neal Frager <neal.frager@amd.com> Co-developed-by: Chris Wardman <cjwfirmware@vxmdesign.com>
2024-01-23libgloss: pru: Trim crt0-minrt.oDimitar Dimitrov
Strip a few more instructions from crt0-minrt.S: - Remove "halt" and rely on the infinite loop after main()'s return. - Remove main()'s argc and argv argument initialization. Host loader does not set them, and typical firmware does not use them, either. - Remove the __dso_handle symbol. This should be safe because the default crt0.S is fully standards compliant. Whereas crt0-minrt.S has been documented from the beginning to intentionally miss features in order to reduce firmware size, while still enabling typical PRU firmware to operate. Signed-off-by: Dimitar Dimitrov <dimitar@dinux.eu>
2024-01-23libgloss: merge pru into top-level MakefileDimitar Dimitrov
Avoid a recursive make to speed things up a bit. This change was inspired by the recent similar patch for c6x: https://sourceware.org/pipermail/newlib/2023/020869.html While at it, fork crt0-minrt.S into a separate source file instead of relying on a predefined macro to generate two different object files. This improves clarity, simplifies the build rules, and would allow further optimization in crt0-minrt.S to be implemented more cleanly. Signed-off-by: Dimitar Dimitrov <dimitar@dinux.eu>
2024-01-23Cygwin: seekdir: don't set errnoCorinna Vinschen
Commit 3f3bd1010455 ("* Throughout, use __try/__except/__endtry blocks [...]") introduced setting EINVAL, marked as "Diagnosis". The reason for this is lost in time and space, but looks very much like a debug helper which was supposed to be removed before release. It's rather pointless, so remove it. Fixes: 3f3bd1010455 ("* Throughout, use __try/__except/__endtry blocks [...]") Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
2024-01-23newlib: docs: add "Function " to every function nodeMike Frysinger
When creating a split manual with one-node-per-page, the main index.html ends up getting clobbered by the page for the index() function because it uses "@node index" which, for html, also creates an index.html page. To remedy this, add "Function " to every function node so now we output "Function-index.html" and avoid clobbering. It also namespaces every other function and helps make sure we don't clobber anything else. Otherwise, there isn't really much rendering difference as @node text is mostly internal. Node title text comes from @section instead.
2024-01-23newlib: docs: print the function indexMike Frysinger
The generated function documentation makes sure to include entries for every function in the function index via @findex, but then the manuals forget to actually print the index.
2024-01-23libgloss: doc: unify duplicate copyright/license contentMike Frysinger
Use @copying & @insertcopying directives to define the copyright & license block only once, and then inserted at the same places as it was before.
2024-01-23libgloss: doc: fix dir info entry usageMike Frysinger
Wrapping the dir info with @ifnottex means it's included in all other outputs like html which makes no sense. Switch to @direntry which is specific for this content and is automatically written to the output that makes sense, and omitted from the rest.
2024-01-22Add Dimitar Dimitrov as maintainer for pruJeff Johnston
2024-01-20libgloss: xc16x: drop old stub portMike Frysinger
First off, afaict, xc16x support has never been merged into gcc. Upstream merge isn't strictly required for new ports, but it seems like people should merge eventually in some shape, and considering the libgloss port was merged in 2009, ~14 years seems like plenty of leeway. Which is to say, no one else can seem to build this which makes updating & testing things very difficult. Ignoring that, from what I can tell, this port has only ever built and installed a crt0.o file. It defines libeval.a & libcygmon.a targets, but nothing depends on them. The SCRIPTS & BSP variables are always empty. The original port merge define these in the configure script as substitutes, but never set the vars, so they were always replaced with nothing. I actually broke this build 2 years ago when merging the configure up a level in commit 30f244155b8e82aa948ddcb8f2350654fc1adb92 ("libgloss: merge subdirs that have unique makefile_frags up a level"). I saw that it was exporting a bunch of vars in the configure script, but never set them, so I incorrectly assumed they weren't used. Which means the Makefile has been setting them to invalid values like literal @bsp_list@ and @script_list@. Considering no one has complained, I have to assume no one cares about this port, and we can all stop wasting time on it.
2024-01-20libgloss: merge microblaze into top-level MakefileMike Frysinger
Avoid a recursive make to speed things up a bit. A microblaze-elf build shows installed objects & libs produce same code.
2024-01-20libgloss: microblaze: use port-specific sbrkMike Frysinger
The default search path uses the common sbrk.c over the microblaze one, so add a rule to force the microblaze variant instead.
2024-01-20libgloss: merge tic6x into top-level MakefileMike Frysinger
Avoid a recursive make to speed things up a bit. A tic6x-elf build shows installed objects & libs produce same code.
2024-01-20libgloss: merge sparc_leon into top-level MakefileMike Frysinger
Avoid a recursive make to speed things up a bit. A sparc-elf build shows installed objects & libs produce same code.
2024-01-20libgloss: sparc_leon: workaround newer newlib pthread APIsMike Frysinger
Fix a compile error due to duplicate pthreads types: .../libgloss/sparc_leon/mutex.c:50:8: error: conflicting types for ‘pthread_mutex_t’; have ‘struct pthread_mutex’ 50 | } pthread_mutex_t; In file included from .../newlib/libc/include/sys/types.h:221, from .../libgloss/sparc_leon/mutex.c:26: .../newlib/libc/include/sys/_pthreadtypes.h:154:20: note: previous declaration of ‘pthread_mutex_t’ with type ‘pthread_mutex_t’ {aka ‘long unsigned int’} 154 | typedef __uint32_t pthread_mutex_t; /* identify a mutex */ .../libgloss/sparc_leon/mutex.c:57:8: error: conflicting types for ‘pthread_mutexattr_t’; have ‘struct <anonymous>’ 57 | } pthread_mutexattr_t; ../newlib/libc/include/sys/_pthreadtypes.h:169:3: note: previous declaration of ‘pthread_mutexattr_t’ with type ‘pthread_mutexattr_t’ 169 | } pthread_mutexattr_t;
2024-01-20libgloss: merge sparc into top-level MakefileMike Frysinger
Avoid a recursive make to speed things up a bit. A sparc-elf build shows installed objects & libs produce same code.
2024-01-20libgloss: sparc: always install erc32 sim filesMike Frysinger
These are already compiled for all sparc targets, so we might as well install them all the time so they can be used with the erc32 sim.
2024-01-20libgloss: merge ft32 into top-level MakefileMike Frysinger
Avoid a recursive make to speed things up a bit. A ft32-elf build shows installed objects & libs produce same code. Mention of ft32-elf-common.ld is dropped as it has never existed in the tree, and has been an (ignored) error in the past.
2024-01-20libgloss: ft32: delete unused/invalid assembly fileMike Frysinger
This is a .c file, not assembly, and it's a duplicate (same content) as the existing sim-lseek.c. Delete it since it's unused and doesn't actually compile.
2024-01-20libgloss: merge fr30 into top-level MakefileMike Frysinger
Avoid a recursive make to speed things up a bit. A fr30-elf build shows installed objects & libs produce same code. A lot of code seems like it hasn't been migrated, but that's because it's all disabled/unused (i.e. all the test & mon code). It looks like a lot of copy & paste holdovers from the original port.
2024-01-20libgloss: merge or1k into top-level MakefileMike Frysinger
Avoid a recursive make to speed things up a bit. A or1k-elf build shows installed objects & libs produce same code.
2024-01-20libgloss: merge epiphany into top-level MakefileMike Frysinger
Avoid a recursive make to speed things up a bit. A epiphany-elf build shows installed objects & libs produce same code.
2024-01-20libgloss: xtensa: fix CPPFLAGS clobberingMike Frysinger
No sub-Makefile.inc file should ever set CPPFLAGS directly. That is a global/common variable. Instead, ports should set the per-target CPPFLAGS to include what they need. Further, per-target CPPFLAGS should respect $(AM_CPPFLAGS).
2024-01-20libgloss: merge visium into top-level MakefileMike Frysinger
Avoid a recursive make to speed things up a bit. A visium-elf build shows installed objects & libs produce same code.
2024-01-20libgloss: visium: fix sbrk search pathMike Frysinger
The code was loading the common ../sbrk.c file rather than the visium specific sbrk.c due to VPATH setup. Add an explicit rule for this one file so we make sure the correct one is used.
2024-01-20libgloss: merge m32r into top-level MakefileMike Frysinger
Avoid a recursive make to speed things up a bit. A m32r-elf build shows installed objects & libs produce same code.
2024-01-20libgloss: merge rl78 into top-level MakefileMike Frysinger
Avoid a recursive make to speed things up a bit. A rl78-elf build shows installed objects & libs produce same code.
2024-01-20libgloss: merge rx into top-level MakefileMike Frysinger
Avoid a recursive make to speed things up a bit. A rx-elf build shows installed objects & libs produce same code.
2024-01-20libgloss: merge xstormy16 into top-level MakefileMike Frysinger
Avoid a recursive make to speed things up a bit. A xstormy16-elf build shows installed objects & libs produce same code.
2024-01-20libgloss: merge nds32 into top-level MakefileMike Frysinger
Avoid a recursive make to speed things up a bit. A nds32le-elf build shows installed objects & libs produce same code.
2024-01-20libgloss: merge mcore into top-level MakefileMike Frysinger
Avoid a recursive make to speed things up a bit. A mcore-elf build shows installed objects & libs produce same code.
2024-01-20libgloss: merge mn10200 into top-level MakefileMike Frysinger
Avoid a recursive make to speed things up a bit. Untested, but follows the same pattern as mn10300, but simpler.
2024-01-20libgloss: merge mn10300 into top-level MakefileMike Frysinger
Avoid a recursive make to speed things up a bit. A mn10300-elf build shows installed objects & libs produce same code.
2024-01-20libgloss: merge i386 into top-level MakefileMike Frysinger
Avoid a recursive make to speed things up a bit. A i386-elf build shows installed objects & libs produce same code other than a rename from cygmon-gmon.o & cygmon-salib.o to i386_libcygmon_a-*.o due to the use of custom CPPFLAGS in here.
2024-01-20libgloss: merge frv into top-level MakefileMike Frysinger
Avoid a recursive make to speed things up a bit. A frv-elf build shows installed objects & libs produce same code.
2024-01-20libgloss: merge msp430 into top-level MakefileMike Frysinger
Avoid a recursive make to speed things up a bit. A msp430-elf build shows installed objects & libs produce same code.
2024-01-20libgloss: msp430: delete custom .S.o ruleMike Frysinger
This was added to specify -Wa,-gdwarf2 when compiling the assembly files. Considering the size of these .S files, it seems unnecessary overkill and complicates the build system. All but one of these compile down to 6 or fewer lines, and those hardly need extra debug for anyone who is poking msp430 assembly. The 1 file that is larger than that (crt_move_highdata.S) is still <15 insns. This will also simplify merging it into the top-level Makefile.
2024-01-20libgloss: msp430: split up crt0.S sourceMike Frysinger
The build system compiles crt0.S many times to produce independent object files by defining different -DLxxx symbols for each. This complicates the build, and has led to some bugs in the source and build (see the previous cleanup commits in here). The crt_bss.S file has also been duplicated with crt0.S leading to confusion as to which one is the "real" one. The only reason to keep them in one file is to make management of the section numbers when calling START_CRT_FUNC a little easier, but that seems trivial to check with a quick grep across all the files. Considering how complicated the build is now, and the bugs we've had as a result, split the crt0.S file up into multiple source files so we don't have to compile it multiple times. This will also simplify merging it into the top-level Makefile.
2024-01-20libgloss: msp430: delete stub crt_init.oMike Frysinger
This object is created by compiling crt0.S with -DLinit, but there has never been an "#if Linit" check in crt0.S, so this has always produced a stub object file. Drop compiling it entirely.