在http://fbredex.com/的 Redex 页面中有一个非常好的说明。
我按照说明进行操作,但有两个步骤出现问题。
1.我对第一个命令的运行没有问题(我的操作系统是Ubuntu)
sudo apt-get install \
g++ \
automake \
autoconf \
autoconf-archive \
libtool \
libboost-all-dev \
libevent-dev \
libdouble-conversion-dev \
libgoogle-glog-dev \
libgflags-dev \
liblz4-dev \
liblzma-dev \
libsnappy-dev \
make \
zlib1g-dev \
binutils-dev \
libjemalloc-dev \
libssl-dev \
libiberty-dev
我在笔记本电脑的某个地方克隆了愚蠢的回购
我去目录
$ cd android/projects/folly/folly/
我跑了
git submodule update --init
,但什么也没发生。我什至在其中运行此命令,$ cd android/projects/folly/
但也没有任何反应。我跑
autoreconf -ivf && ./configure && make && make install
。似乎有效,因为我看到过程大约需要一两分钟,并且打印出很多 og 消息。我将示例 .apk 文件复制/粘贴到我的桌面并运行
redex ~/Desktop/my_android_app.apk -o ~/Desktop/my_android_app-redexed.apk
. 但是,我在终端上收到此消息。未找到命令“redex”,您的意思是:来自包“redet”(universe)的命令“redet”redex:找不到命令
当我在/home/hesam/android/projects/folly/folly
or中时,我运行了上面的命令/home/hesam/android/projects/folly/
。但我得到相同的输出。
更新
我克隆了 Redex repo 并遵循了 Bert 的指示。它有效,我可以通过运行看到正在发生的事情git submodule update --init
。所以感谢伯特。但是,我在autoreconf -ivf && ./configure && make && make install
命令结束时出错。
请查看以下输出:
Making all in unit
make[3]: Entering directory `/home/hesam/android/projects/redex/test/unit'
make[3]: Nothing to be done for `all'.
make[3]: Leaving directory `/home/hesam/android/projects/redex/test/unit'
make[2]: Leaving directory `/home/hesam/android/projects/redex/test'
make[1]: Leaving directory `/home/hesam/android/projects/redex'
Making install in third-party/folly/folly
make[1]: Entering directory `/home/hesam/android/projects/redex/third-party/folly/folly'
Making install in .
make[2]: Entering directory `/home/hesam/android/projects/redex/third-party/folly/folly'
make[3]: Entering directory `/home/hesam/android/projects/redex/third-party/folly/folly'
/bin/mkdir -p '/usr/local/lib'
/bin/bash ./libtool --mode=install /usr/bin/install -c libfolly.la libfollybenchmark.la '/usr/local/lib'
libtool: install: /usr/bin/install -c .libs/libfolly.so.57.0.0 /usr/local/lib/libfolly.so.57.0.0
/usr/bin/install: cannot create regular file '/usr/local/lib/libfolly.so.57.0.0': Permission denied
make[3]: *** [install-libLTLIBRARIES] Error 1
make[3]: Leaving directory `/home/hesam/android/projects/redex/third-party/folly/folly'
make[2]: *** [install-am] Error 2
make[2]: Leaving directory `/home/hesam/android/projects/redex/third-party/folly/folly'
make[1]: *** [install-recursive] Error 1
make[1]: Leaving directory `/home/hesam/android/projects/redex/third-party/folly/folly'
make: *** [install-recursive] Error 1
hesam: redex (master) $ redex ~/Desktop/my_android_app.apk -o ~/Desktop/my_android_app-redexed.apk
No command 'redex' found, did you mean:
Command 'redet' from package 'redet' (universe)
redex: command not found
hesam: redex (master) $