[Rpm-maint] [rpm] fixes for OS X (#57)

Neal Gompa (ニール・ゴンパ) notifications at github.com
Tue Feb 9 06:01:18 UTC 2016


> @@ -86,20 +90,7 @@ char * stpncpy(char * dest, const char * src, size_t n);
>  #define xstrdup(_str) rstrdup((_str))
>  #define _free(_ptr) rfree((_ptr))
>  
> -/* Retrofit glibc __progname */
> -#if defined __GLIBC__ && __GLIBC__ >= 2
> -#if __GLIBC_MINOR__ >= 1
> -#define	__progname	__assert_program_name
> -#endif
> -#define	setprogname(pn)
> -#else
> -#define	__progname	program_name
> -#define	setprogname(pn)	\
> -  { if ((__progname = strrchr(pn, '/')) != NULL) __progname++; \
> -    else __progname = pn;		\
> -  }
> -#endif
> -extern const char *__progname;
> +#define __progname getprogname()

This function is not present on Linux systems, only Solaris, BSD, and OS X. It doesn't look like you handle compatibility for Linux well with the `__progname` changes.

---
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/pull/57/files#r52270457
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rpm.org/pipermail/rpm-maint/attachments/20160208/53d20dd0/attachment.html>


More information about the Rpm-maint mailing list