On Thu, Jun 11, 2015 at 10:26 AM, Hans-Werner Hilse <hwhi...@gmail.com> wrote: > Am 2015-06-11 10:09, schrieb Richard Weinberger: >> On Thu, Jun 11, 2015 at 9:54 AM, Hans-Werner Hilse <hwhi...@gmail.com> >> wrote: >>> About forbidden use of names/identifiers from the stdlib, the C >>> standard >>> is a bit hard for me to grasp fully. However, I think C99 7.1.3 >>> paragraph 1, 3rd point is relevant here: "Each macro name in any of >>> the >>> following subclauses (including the future library directions) is >>> reserved for use as specified if any of its associated headers is >>> included; unless explicitly stated otherwise (see 7.1.4)." >> >> Yeah, but we're talking about structure members. > > Indeed, and I can't find more detail about the "reserved for use as > specified" part. > I think it is saying, though, that those identifiers are macros (and as > such will get expanded). The preprocessor will not care if that's in a > struct member name.
While I think musl could be more user friendly, I fear the easiest solution is really to rename our structure members. glibc does a the user a favor by having a simple "#define stdin stdin". >>> So aside from renaming struct members, another option would be to lift >>> the macro definition by an "#undef" in relevant places. I have a >>> feeling, though, that this faces new problems with the C99 standard, >>> 7.1.3 paragraph 3, which says that "If the program removes (with >>> #undef) >>> any macro definition of an identifier in the first group listed above, >>> the behavior is undefined." >> >> So, what exactly is the build error you're facing and how can I >> reproduce? > > Of course I should have told you in the first place: > > [hw@hilses linux-uml]$ make ARCH=um CC="musl-gcc" Thx! -- Thanks, //richard ------------------------------------------------------------------------------ _______________________________________________ User-mode-linux-devel mailing list User-mode-linux-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/user-mode-linux-devel