linux - Figuring out __only_inline C macro used on BSD -
i'm trying port openbsd make linux i'm confused use of __only_inline macro. macro comes /usr/include/sys/cdefs.h defines follows:
/* * __only_inline makes compiler use function definition * inlining; references can't inlined left * external references instead of generating local copy. * matching library should include simple extern definition * function handle references. c.f. ctype.h */ #ifdef __gnuc__ # if __gnuc_prereq__(4, 2) #define __only_inline extern __inline __attribute__((__gnu_inline__)) # else #define __only_inline extern __inline # endif #else #define __only_inline static __inline #endif
can explain purpose of macro? it's used in openbsd make in targ.h:
isn't comment clear enough? __only_inline
definition used can inlined. definition must exist somewhere else uses cannot inlined.
you might want have @ bmake
netbsd/pkgsrc. similar make has been autoconf'ed , portable gnu/linux. can find latest version here: bmake
in general though can ignore entirely (i.e. remove it), or convert extern inline
.
if email marc can tell why used in case.
Comments
Post a Comment