bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: sys-limits.h on illumos


From: Bruno Haible
Subject: Re: sys-limits.h on illumos
Date: Fri, 04 Jan 2019 06:26:20 +0100
User-agent: KMail/5.1.3 (Linux/4.4.0-141-generic; KDE/5.18.0; x86_64; ; )

Hi,

Andy Fiddaman wrote:
> There's a compatibility problem with the guard definition used in the
> sys-limits.h file that affects illumos (an opensolaris derivative) and most
> likely Solaris too.
> 
> These operating systems have a /usr/include/sys/limits.h file which uses the
> _SYS_LIMITS_H guard. Since the same guard is used in the gnulib sys-limits.h,
> we are finding that as packages update their copies of gnulib, compilation
> breaks (most recently we experienced this with coreutils, grep and tar -
> usually the symptom is that SYS_BUFSIZE_MAX is not defined).
> 
> Would it be possible to replace _SYS_LIMITS_H in sys-limits.h with something
> else in order to resolve this problem?

It affects only the Joyent fork of Illumos, as you can see from
https://github.com/joyent/illumos-joyent/tree/master/usr/src/uts/common/sys
vs.
https://github.com/illumos/illumos-gate/tree/master/usr/src/uts/common/sys

It does NOT affect Solaris 11.4, nor OpenIndiana, since these systems don't
have a /usr/include/sys/limits.h file.


Done:

2019-01-04  Bruno Haible  <address@hidden>

        safe-read, safe-write: Fix conflict with Illumos-Joyent <sys/limits.h>.
        Reported by Andy Fiddaman <address@hidden>.
        * lib/sys-limits.h: Add a '_GL' prefix to the guard symbol.

diff --git a/lib/sys-limits.h b/lib/sys-limits.h
index 2f09bbf..12611b5 100644
--- a/lib/sys-limits.h
+++ b/lib/sys-limits.h
@@ -15,8 +15,8 @@
    You should have received a copy of the GNU General Public License
    along with this program; if not, see <https://www.gnu.org/licenses/>.  */
 
-#ifndef _SYS_LIMITS_H
-#define _SYS_LIMITS_H
+#ifndef _GL_SYS_LIMITS_H
+#define _GL_SYS_LIMITS_H
 
 #include <limits.h>
 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]