armv8编译安装redis-stable

  sre


环境
Ubuntu 16.04.4 LTS
Linux version 3.14.29
gcc version 6.4.1 20171012 (Linaro GCC 6.4-2017.11)
aarch64 aarch64 aarch64 GNU/Linux

apt install libreadline-dev tcl

wget http://download.redis.io/redis-stable.tar.gz
tar zxvf redis-stable.tar.gz

/root/redis-stable/deps/hiredis
ARCH=”
make

cd /root/redis-stable/deps/lua
make linux

cd /root/redis-stable/deps/jemalloc
./configure
make

cd /root/redis-stable
make install

cd /root/redis-stable
mkdir -p /usr/local/redis/etc/
cp redis.conf /usr/local/redis/etc/

vim /usr/local/redis/etc/redis.conf
bind 0.0.0.0
daemonize yes

redis-server /usr/local/redis/etc/redis.conf

###报错
cc: error: ../deps/hiredis/libhiredis.a: No such file or directory
cc: error: ../deps/lua/src/liblua.a: No such file or directory
cc: error: ../deps/jemalloc/lib/libjemalloc.a: No such file or directory
删除/root/redis-stable,重新解压
cd /root/redis-stable/deps/hiredis
make
cc -std=c99 -pedantic -c -O3 -fPIC -Wall -W -Wstrict-prototypes -Wwrite-strings -g -ggdb arm64 net.c
cc: error: arm64: No such file or directory
Makefile:156: recipe for target ‘net.o’ failed
##需要执行ARCH=”
###
In file included from lua.h:16:0,
from lua.c:15:
luaconf.h:275:31: fatal error: readline/readline.h: No such file or directory
##需要apt-get install libreadline-dev
过程中若出现no target 删除目录解压源码重新编译

LEAVE A COMMENT

Captcha Code