Skip to content

Commit

Permalink
build: centos/RHEL 7 ships with an older gcc and zlib
Browse files Browse the repository at this point in the history
GCC 4.8.5 is the default system compiler on centos7/RHEL7.
This version requires -std=c99 to enable c99 support.

zlib 1.2.7 on centos7/rhel7 lacks uncompress2().

Signed-off-by: David Aguilar <davvid@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
  • Loading branch information
davvid authored and gitster committed Jan 16, 2022
1 parent a4bbd13 commit ffb9f29
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions config.mak.uname
Expand Up @@ -63,6 +63,11 @@ ifeq ($(uname_S),Linux)
PROCFS_EXECUTABLE_PATH = /proc/self/exe
HAVE_PLATFORM_PROCINFO = YesPlease
COMPAT_OBJS += compat/linux/procinfo.o
# centos7/rhel7 provides gcc 4.8.5 and zlib 1.2.7.
ifneq ($(findstring .el7.,$(uname_R)),)
BASIC_CFLAGS += -std=c99
NO_UNCOMPRESS2 = YesPlease
endif
endif
ifeq ($(uname_S),GNU/kFreeBSD)
HAVE_ALLOCA_H = YesPlease
Expand Down

0 comments on commit ffb9f29

Please sign in to comment.