Re: [dev] [sbase] [patch] Add strlcpy()/strlcat() + refactor recurse()

From: Bobby Powers <bobbypowers_AT_gmail.com>
Date: Thu, 30 Jan 2014 09:38:23 -0800

Hello,

sin wrote:
> This is in preparation to moving tar(1) over to recurse()
> instead of ftw().

On MacOS 10.9, strlcat and strncat are defined as macros, and adding
them to sbase breaks the builds. I'm not sure what the easy/nice
solution is. Error is below.

yours
Bobby

~~~~

CC util/afgets.c

In file included from util/afgets.c:7:

util/../util.h:23:8: error: expected parameter declarator

size_t strlcat(char *, const char *, size_t);

       ^

/usr/include/secure/_string.h:111:44: note: expanded from macro 'strlcat'

  __builtin___strlcat_chk (dest, src, len, __darwin_obsz (dest))

                                           ^

/usr/include/secure/_common.h:39:62: note: expanded from macro '__darwin_obsz'

#define __darwin_obsz(object) __builtin_object_size (object,
_USE_FORTIFY_LEVEL > 1 ? 1 : 0)

                                                             ^

/usr/include/secure/_common.h:30:32: note: expanded from macro
'_USE_FORTIFY_LEVEL'

# define _USE_FORTIFY_LEVEL 2

                               ^
Received on Thu Jan 30 2014 - 18:38:23 CET

This archive was generated by hypermail 2.3.0 : Thu Jan 30 2014 - 18:48:09 CET