IRC channel logs
2025-02-13.log
back to list of logs
<youpi>damo22 : the “vm: Add missing locking” commit I have just pushed will probably with smp correctness <damo22>youpi: it seems to be helping with UP thanks <youpi>damo22: uh? locking does nothing on UP <damo22>hi youpi, master fixed UP compared to unreleased <damo22>i was able to compile gcc and gcj <youpi>the darnassus wiki is coming back, please some more patience :) <youpi>I upload gnumach debian packages to unstable, not unreleased <youpi>good that you got gcc-6 built again, it's be good to have the source .dsc etc. so I can build&upload to unreleased, both on hurd-i386 and hurd-amd64 <youpi>the darnassus wiki is back :) <Pellescours>youpi: in bits/dirents.h I can see that dirent.d_name is defined as "char d_name[1]", with a comment saying it’s actually longer <Pellescours>do you know what define this file (gcc, glibc)? This definition of char[1] trigger compilation errors for coreutils 9.6 as it trigger the errer strict-flex-arrays <youpi>would it work better with [0] or [] ? <youpi>AIUI __flexarr can be used along __glibc_c99_flexarr_available, see e.g. sysdeps/unix/sysv/linux/bits/socket.h <youpi>probably you can fix d_name the same way <Pellescours>youpi: I think in glibc we can just use __flexarr without guarding it like for linux/bits/socket.h, I saw some other places that uses __flexarr without the #ifdef <Pellescours>and do I need copyright assignment for glibc if I want to make a patch for this file? I did it only for gnumach and hurd <youpi>you can put Signed-off-by to avoid a copyright assignment <youpi>these are probably only compatible with gcc anyway <youpi>better do it the clean way anyway <Pellescours>ok, in misc/sys/sysdefs.h there is the definition of the macro and the __flexarr is always defined <Pellescours>if it’s unsupported by the compiler it fall back to "[1]" and the __glibc_* is defined to 0 <youpi>ah __flexarr is always define <youpi>then it will be fine to avoid the #ifdef indeed <Pellescours>ah but this breaks perl building. perl does "if(len > sizeof(dirent->d_name) && sizeof(dirent->d_name) > PTRSIZE)"... <youpi>Pellescours: perhaps you can instead #ifdef __glibc_c99_flexarr_available d_name [0] #else d_name[1] <Pellescours>sizeof assumes that the arrays length is known at compile time, but does posix require d_name to be statically sized? <youpi>The array d_name is of unspecified size <youpi>I don't know if that means that it does necessarily have a size <youpi>using [0] when it is known that it is allowed is stricly better than just using [1] always <youpi>using [] means having to fight with all software that could want to sizeof() it just because most other OSes do set a size <Pellescours>sad that people rather put arbitrary limit (PATH_MAX, …) to make their life easier. This make other people put strong assumption on the existence of theses limits that should not exists <youpi>so making it [] is not really an option <youpi>although most of these are probably just bogus :/ <youpi>we might be better off with making it [255] like others <Pellescours>sad, so the other solution is to do like for linux and put a high value <youpi>there really is a maximum length here due to d_namlen being a char <Pellescours>the commit that added MACRO_BEGIN broke my cross-compilation of gnumach :/ <Pellescours>I need to investiguate but now (glibc master up to date) it fails to compile clock_gettime with error: implicit declaration of function 'MACRO_BEGIN' (TIME_VALUE_TO_64_TIMESPEC) <Pellescours>Ah but it’s really linked to the commit with MACRO_BEGIN addition, I think it’s a missing #include. During the build of glibc, at the step of clock_gettime, it includes <mach/time_value.h> and now it uses the macro, but the macro is undefined (missing include I would say)