[PATCH] sunrpc/rpc/types.h: Fix OS X build problem.
Jia Liu
proljc@gmail.com
Fri Sep 6 15:53:00 GMT 2013
Hi Mike,
On Fri, Sep 6, 2013 at 8:55 PM, Mike Frysinger <vapier@gentoo.org> wrote:
> On Friday 06 September 2013 00:00:22 Jia Liu wrote:
>> On Fri, Sep 6, 2013 at 11:30 AM, Mike Frysinger wrote:
>> > On Thursday 05 September 2013 23:23:06 Jia Liu wrote:
>> >> On Fri, Sep 6, 2013 at 9:13 AM, Mike Frysinger wrote:
>> >> > On Thursday 05 September 2013 09:39:00 Jia Liu wrote:
>> >> >> Is this code looks OK?
>> >> >>
>> >> >> #if defined ( __APPLE_CC__ ) || defined( __FreeBSD__ )
>> >> >> # define __u_char_defined
>> >> >> #endif
>> >>
>> >> I modify the code into this:
>> >>
>> >> #if defined __APPLE_CC__ || defined __FreeBSD__
>> >> # define __u_char_defined
>> >> #endif
>> >>
>> >> and made a test, it still get the same error.
>> >
>> > where did you put the code ? it should have been right above the line:
>> > #ifndef __u_char_defined
>> >
>> > you might have to also add in your new snippet:
>> > # define __daddr_t_defined
>>
>> Thank you, I put
>> #if !defined __APPLE_CC__ && !defined __FreeBSD__
>> above
>> #ifndef __u_char_defined
>> will be right.
>
> i think you're still missing the point. why doesn't this code work ?
Hum, yes, I missing the point, thank you for the point.
>
> #include <sys/types.h>
> #endif
>
> +#if defined __APPLE_CC__ || defined __FreeBSD__
> +# define __u_char_defined
> +# define __daddr_t_defined
> +#endif
>
> #ifndef __u_char_defined
> typedef __u_char u_char;
> -mike
Regards,
Jia
More information about the Libc-alpha
mailing list