Originally, it's Redhat 7.7 with gcc 4.8.5. While do redis6 make, it gives "make: *** [server.io] Error 1" Then offline update gcc version, run gcc -v, it returns "gcc version 7.1.0 (GCC). Make redis6 again, the same error occurs. Wonder why? Appreciate your reply and help.

Comment From: Lynda-Li

Today return to past closed issues, (though my posted question troubles me almost me 2 days,) I then try the 6.2-rc3 version, it makes ok now. Excellent!! I was wondering when to release 6.2 stable version, our project probably goes to production in late March. Hopefully, we can use it. ^_^

Comment From: ShooterIT

For 6.0, gcc version 7.1.0 (GCC) also make errors? Please

make distclean
make

Are your sure your compiler is gcc 7.1.0? you can point your gcc in make, such as make $CC=\7.1.0.gcc.path My PR https://github.com/redis/redis/pull/7707 solved gcc 4.8.5 can't compile redis 6.0, but 7.1.0 always can compile redis 6.0.

Comment From: Lynda-Li

'make distclean, then make' doesn't work, also a lot of errors (mainly formatted in "error: 'struct redisServer' has no member named 'xxx'"). I'm sure my gcc is 7.1.0 (got from "gcc -v" command, though I upgrade it offline).

'make $CC=\opt\gcc-7.1.0' got returns: CC server.o /bin/sh: /opt/gcc-7.1.0: Is a directory make: *** [server.o] Error 126

My PR #7707 solved gcc 4.8.5 can't compile redis 6.0 you mean we can compile redis 6.0 at gcc 4.8.5? If yes, I'm afraid not. My gcc is 4.8.5, and I make redis 6.0.10, the above formatted errors occur.

Comment From: ShooterIT

My bad, please have a try make CC=/opt/gcc-7.1.0/bin/gcc, if your gcc path is that path

Comment From: Lynda-Li

Wonderful, it works! My gcc path is /usr/local/bin/gcc, it makes ok now. Thanks so much~