2014-10-09 67 views
1

嗨試圖做一個遠程安裝的Node.js的,這之後的指令集hereNode.js的編譯與OpenSSL的支持

wget http://nodejs.org/dist/node-v0.4.10.tar.gz 
tar -zxvf node-v0.4.10.tar.gz 
cd node-v0.x.x 
./configure --prefix=~/node 
make 
make test 
make install 

這應該爲我提供一個~/node的NodeJS下安裝然而,在在./configure --prefix=~/node我遇到這個的依賴性要求:

node-v0.4.10]$ ./configure --prefix=~/node 
Checking for program g++ or c++   : /usr/bin/g++ 
Checking for program cpp     : /usr/bin/cpp 
Checking for program ar     : /usr/bin/ar 
Checking for program ranlib    : /usr/bin/ranlib 
Checking for g++       : ok 
Checking for program gcc or cc   : /usr/bin/gcc 
Checking for program ar     : /usr/bin/ar 
Checking for program ranlib    : /usr/bin/ranlib 
Checking for gcc       : ok 
Checking for library dl     : yes 
Checking for openssl      : not found 
Checking for function SSL_library_init : not found 
Checking for header openssl/crypto.h  : not found 
/opt/server/node-v0.4.10/wscript:341: error: Could not autodetect OpenSSL support. Make sure OpenSSL development packages are installed. Use configure --without-ssl to disable this message. 
[[email protected] node-v0.4.10]$ make 
Project not configured (run 'waf configure' first) 
make: *** [program] Error 1 

我已經檢查了開放的SSL是盒子:

node-v0.4.10]$ openssl version 
OpenSSL 1.0.1e-fips 11 Feb 2013 

~]$ gcc -v 
Using built-in specs. 
Target: x86_64-redhat-linux 
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --with-bugurl=http://bugzilla.redhat.com/bugzilla --enable-bootstrap --enable-shared --enable-threads=posix --enable-checking=release --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-gnu-unique-object --enable-languages=c,c++,objc,obj-c++,java,fortran,ada --enable-java-awt=gtk --disable-dssi --with-java-home=/usr/lib/jvm/java-1.5.0-gcj-1.5.0.0/jre --enable-libgcj-multifile --enable-java-maintainer-mode --with-ecj-jar=/usr/share/java/eclipse-ecj.jar --disable-libjava-multilib --with-ppl --with-cloog --with-tune=generic --with-arch_32=i686 --build=x86_64-redhat-linux 
Thread model: posix 
gcc version 4.4.7 20120313 (Red Hat 4.4.7-4) (GCC) 

不知道還有什麼其他的依賴他們的是,一直在尋找一個配置文件

+1

你真的應該有一個新版本的節點開始,V0.4是古老的。在撰寫本文時,v0.10.32是節點的最新穩定版本。 – mscdex 2014-10-09 04:29:42

+0

任何你無法得到其中一個二進制文件的原因? http://nodejs.org/download/ TLS已經在那裏。你只需要在你的代碼中需要它。 – HeadCode 2014-10-09 05:24:11

+0

我不確定新版本的unix安裝過程./configure返回./configure -bash:./configure:〜/ NodeJS/node-v0.10.32-linux-x64 /內沒有這樣的文件或目錄,和〜/的NodeJS /節點v0.10.32-Linux的64/bin中 – Will 2014-10-09 05:44:18

回答

1

Node.js的已經包裝最流行distributions

如果我的猜測是正確的,你使用CentOS 6的或類似的,下面的命令應該很好地工作:

sudo yum install nodejs npm --enablerepo=epel