Skip to content

Commit

Permalink
Avoid attempting to redefine z_const in zconf.h.
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexisWilke authored and madler committed Oct 14, 2024
1 parent 6419111 commit 6d3a66a
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 12 deletions.
10 changes: 6 additions & 4 deletions zconf.h
Original file line number Diff line number Diff line change
Expand Up @@ -235,10 +235,12 @@
# endif
#endif

#if defined(ZLIB_CONST) && !defined(z_const)
# define z_const const
#else
# define z_const
#ifndef z_const
# ifdef ZLIB_CONST
# define z_const const
# else
# define z_const
# endif
#endif

#ifdef Z_SOLO
Expand Down
10 changes: 6 additions & 4 deletions zconf.h.cmakein
Original file line number Diff line number Diff line change
Expand Up @@ -237,10 +237,12 @@
# endif
#endif

#if defined(ZLIB_CONST) && !defined(z_const)
# define z_const const
#else
# define z_const
#ifndef z_const
# ifdef ZLIB_CONST
# define z_const const
# else
# define z_const
# endif
#endif

#ifdef Z_SOLO
Expand Down
10 changes: 6 additions & 4 deletions zconf.h.in
Original file line number Diff line number Diff line change
Expand Up @@ -235,10 +235,12 @@
# endif
#endif

#if defined(ZLIB_CONST) && !defined(z_const)
# define z_const const
#else
# define z_const
#ifndef z_const
# ifdef ZLIB_CONST
# define z_const const
# else
# define z_const
# endif
#endif

#ifdef Z_SOLO
Expand Down

0 comments on commit 6d3a66a

Please sign in to comment.