R
R
romaro2021-05-10 23:50:57
Redis
romaro, 2021-05-10 23:50:57

Did my Redis compile correctly?

I'm trying to install the latest stable release (6.2.3) from the source archive on Oracle Linux. After unpacking and executing the make command, I get a log in which numbered errors confuse me (I highlighted the lines with them).

[[email protected] tmp]# tar xzf redis-6.2.3.tar.gz
[[email protected] tmp]# cd redis-6.2.3
[[email protected] redis-6.2.3]# make
cd src && make all
make[1]: Entering directory '/tmp/redis-6.2.3/src'
    CC Makefile.dep
rm -rf redis-server redis-sentinel redis-cli redis-benchmark redis-check-rdb redis-check-aof *.o *.gcda *.gcno *.gcov redis.info lcov-html Makefile.dep
rm -f adlist.d quicklist.d ae.d anet.d dict.d server.d sds.d zmalloc.d lzf_c.d lzf_d.d pqsort.d zipmap.d sha1.d ziplist.d release.d networking.d util.d object.d db.d replication.d rdb.d t_string.d t_list.d t_set.d t_zset.d t_hash.d config.d aof.d pubsub.d multi.d debug.d sort.d intset.d syncio.d cluster.d crc16.d endianconv.d slowlog.d scripting.d bio.d rio.d rand.d memtest.d crcspeed.d crc64.d bitops.d sentinel.d notify.d setproctitle.d blocked.d hyperloglog.d latency.d sparkline.d redis-check-rdb.d redis-check-aof.d geo.d lazyfree.d module.d evict.d expire.d geohash.d geohash_helper.d childinfo.d defrag.d siphash.d rax.d t_stream.d listpack.d localtime.d lolwut.d lolwut5.d lolwut6.d acl.d gopher.d tracking.d connection.d tls.d sha256.d timeout.d setcpuaffinity.d monotonic.d mt19937-64.d anet.d adlist.d dict.d redis-cli.d zmalloc.d release.d ae.d crcspeed.d crc64.d siphash.d crc16.d monotonic.d cli_common.d mt19937-64.d ae.d anet.d redis-benchmark.d adlist.d dict.d zmalloc.d release.d crcspeed.d crc64.d siphash.d crc16.d monotonic.d cli_common.d mt19937-64.d
(cd ../deps && make distclean)
make[2]: Entering directory '/tmp/redis-6.2.3/deps'
(cd hiredis && make clean) > /dev/null || true
(cd linenoise && make clean) > /dev/null || true
(cd lua && make clean) > /dev/null || true
(cd jemalloc && [ -f Makefile ] && make distclean) > /dev/null || true
(cd hdr_histogram && make clean) > /dev/null || true
(rm -f .make-*)
make[2]: Leaving directory '/tmp/redis-6.2.3/deps'
(rm -f .make-*)
echo STD=-pedantic -DREDIS_STATIC='' -std=c99 >> .make-settings
echo WARN=-Wall -W -Wno-missing-field-initializers >> .make-settings
echo OPT=-O2 >> .make-settings
echo MALLOC=jemalloc >> .make-settings
echo BUILD_TLS= >> .make-settings
echo USE_SYSTEMD= >> .make-settings
echo CFLAGS= >> .make-settings
echo LDFLAGS= >> .make-settings
echo REDIS_CFLAGS= >> .make-settings
echo REDIS_LDFLAGS= >> .make-settings
echo PREV_FINAL_CFLAGS=-pedantic -DREDIS_STATIC='' -std=c99 -Wall -W -Wno-missing-field-initializers -O2 -g -ggdb   -I../deps/hiredis -I../deps/linenoise -I../deps/lua/src -I../deps/hdr_histogram -DUSE_JEMALLOC -I../deps/jemalloc/include >> .make-settings
echo PREV_FINAL_LDFLAGS=  -g -ggdb -rdynamic >> .make-settings
(cd ../deps && make hiredis linenoise lua hdr_histogram jemalloc)
make[2]: Entering directory '/tmp/redis-6.2.3/deps'
(cd hiredis && make clean) > /dev/null || true
(cd linenoise && make clean) > /dev/null || true
(cd lua && make clean) > /dev/null || true
(cd jemalloc && [ -f Makefile ] && make distclean) > /dev/null || true
(cd hdr_histogram && make clean) > /dev/null || true
(rm -f .make-*)
(echo "" > .make-cflags)
(echo "" > .make-ldflags)
MAKE hiredis
cd hiredis && make static
make[3]: Entering directory '/tmp/redis-6.2.3/deps/hiredis'
cc -std=c99 -pedantic -c -O3 -fPIC   -Wall -W -Wstrict-prototypes -Wwrite-strings -Wno-missing-field-initializers -g -ggdb alloc.c
make[3]: cc: Command not found
<b>make[3]: *** [Makefile:223: alloc.o] Error 127</b>
make[3]: Leaving directory '/tmp/redis-6.2.3/deps/hiredis'
<b>make[2]: *** [Makefile:51: hiredis] Error 2</b>
make[2]: Leaving directory '/tmp/redis-6.2.3/deps'
<b>make[1]: [Makefile:320: persist-settings] Error 2 (ignored)</b>
    CC adlist.o
/bin/sh: cc: command not found
<b>make[1]: *** [Makefile:368: adlist.o] Error 127</b>
make[1]: Leaving directory '/tmp/redis-6.2.3/src'
<b>make: *** [Makefile:6: all] Error 2</b>


After running make test, I also get errors:
[[email protected] redis-6.2.3]# make test
cd src && make test
make[1]: Entering directory '/tmp/redis-6.2.3/src'
    CC Makefile.dep
    CC adlist.o
/bin/sh: cc: command not found
make[1]: *** [Makefile:368: adlist.o] Error 127
make[1]: Leaving directory '/tmp/redis-6.2.3/src'
make: *** [Makefile:6: test] Error 2


Am I missing some library or is there another reason?

Answer the question

In order to leave comments, you need to log in

[[+comments_count]] answer(s)
V
Vasily Bannikov, 2021-05-11
@romaro

/bin/sh: cc: command not found

I
Igor Makhov, 2021-05-11
@Igorgro

You do not have a compiler installed, run:sudo apt install build-essential

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question