3

I am trying to do a prefixed install of Erlang R16B02 on shared server space that is running Ubuntu 13.04. As this is shared space, I don't have root privileges. The system has OpenSSL 1.0.1c installed.

After unpacking the tarball, I run configure like this:

./configure --prefix=/home/myname/software --with-ssl=/usr/lib/ssl/

The system compains about ncurses:

...
checking whether the child waiter thread should be enabled... yes on SMP build, but not on non-SMP build
checking for kstat_open in -lkstat... (cached) no
checking for tgetent in -lncurses... no
checking for tgetent in -lcurses... no
checking for tgetent in -ltermcap... no
checking for tgetent in -ltermlib... no
configure: error: No curses library functions found
configure: error: /bin/bash '/home/myname/software/otp_src_R16B02/erts/configure' failed for erts

In addition to ncurses (which I could probably live without), I also need libssl-dev (which I can't live without). I tried to do an install without ncurses (using the --without-termcap flag) like this:

./configure --prefix=/home/myname/software --with-ssl=/usr/lib/ssl/ --without-termcap
make

In this case the configure succeeds, but make fails on crypto:

make[2]: Entering directory `/home/myname/software/otp_src_R16B02/lib/crypto'
=== Entering application crypto
make[3]: Entering directory `/home/myname/software/otp_src_R16B02/lib/crypto/src'
make[3]: Nothing to be done for `opt'.
make[3]: Leaving directory `/home/myname/software/otp_src_R16B02/lib/crypto/src'
make[3]: Entering directory `/home/myname/software/otp_src_R16B02/lib/crypto/c_src'
make -f x86_64-unknown-linux-gnu/Makefile TYPE=opt
make[4]: Entering directory `/home/myname/software/otp_src_R16B02/lib/crypto/c_src'
/usr/bin/install -c -d ../priv/obj/x86_64-unknown-linux-gnu
gcc -c -o ../priv/obj/x86_64-unknown-linux-gnu/crypto.o -Werror=return-type  -Wall -Wstrict-prototypes -Wmissing-prototypes -Wdeclaration-after-statement  -DUSE_THREADS -D_THREAD_SAFE -D_REENTRANT -DPOSIX_THREADS -D_POSIX_THREAD_SAFE_FUNCTIONS -g -O2 -I/home/myname/software/otp_src_R16B02/erts/x86_64-unknown-linux-gnu   -fno-tree-copyrename  -D_GNU_SOURCE -fPIC -DHAVE_DYNAMIC_CRYPTO_LIB -I/usr/lib/ssl//include -I/home/myname/software/otp_src_R16B02/erts/emulator/beam -I/home/myname/software/otp_src_R16B02/erts/include -I/home/myname/software/otp_src_R16B02/erts/include/x86_64-unknown-linux-gnu -I/home/myname/software/otp_src_R16B02/erts/include/internal -I/home/myname/software/otp_src_R16B02/erts/include/internal/x86_64-unknown-linux-gnu -I/home/myname/software/otp_src_R16B02/erts/emulator/sys/unix crypto.c
crypto.c:36:33: fatal error: openssl/opensslconf.h: No such file or directory
compilation terminated.
make[4]: *** [../priv/obj/x86_64-unknown-linux-gnu/crypto.o] Error 1
make[4]: Leaving directory `/home/myname/software/otp_src_R16B02/lib/crypto/c_src'
make[3]: *** [opt] Error 2
make[3]: Leaving directory `/home/myname/software/otp_src_R16B02/lib/crypto/c_src'
make[2]: *** [opt] Error 2
make[2]: Leaving directory `/home/myname/software/otp_src_R16B02/lib/crypto'
make[1]: *** [opt] Error 2
make[1]: Leaving directory `/home/myname/software/otp_src_R16B02/lib'
make: *** [libs] Error 2

If I had root priviliges, I could resolve this with apt-get:

sudo apt-get libncurses5-dev
sudo apt-get libssl-dev

but I don't know how/where to get the source for these without apt-get. Can someone please help?

Ampers4nd
  • 787
  • 1
  • 11
  • 20
  • There's some info on the ubuntu stack exchange about installing packages as a non root user: http://askubuntu.com/questions/339/how-can-i-install-a-package-without-root-access – kjw0188 Oct 17 '13 at 16:53
  • Thanks. I ended up going with better hosting. I shouldn't be doing anything without root access anyway:-) – Ampers4nd Oct 23 '13 at 14:39

1 Answers1

0

You can compile the ssl libraries in you home to use with your code. Download the SSL and ncurses libraries (or use apt-get source) and something like this:

./configure --prefix=$HOME/opt/libssl
make && make install

If you are using Debian or Ubuntu it's going to be easier because you can do this:

apt-get source libssl
cd libssl
./configure --prefix=$HOME/opt/libssl
make && make install

After that, you can configure R16B02 to get the libraries in this location:

./configure --with-ssl=$HOME/opt/libssl
Manuel Rubio
  • 114
  • 2
  • 9