LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 09-15-2018, 09:41 PM   #1
Zhanpython
LQ Newbie
 
Registered: Sep 2018
Posts: 3

Rep: Reputation: Disabled
Question How to install libreadline.so.7


I'm trying to set up the environment of deepmind/dqn, https://github.com/deepmind/dqn, I run ./install_dependencies.sh to install
  • LuaJIT and Torch 7.0
  • nngraph
  • Xitari
  • AleWrap

first.But I got:

/home/dqn/torch/bin/luajit: error while loading shared libraries: libreadline.so.7: cannot open shared object file: No such file or directory

=> Torch7 has been installed successfully

Installing nngraph ...
/home/dqn/torch/bin/luajit: error while loading shared libraries: libreadline.so.7: cannot open shared object file: No such file or directory
Error. Exiting.

The install_dependencies.sh is:

# Install dependencies for Torch:
sudo apt-get update
sudo apt-get install -qqy build-essential
sudo apt-get install -qqy gcc g++
sudo apt-get install -qqy cmake
sudo apt-get install -qqy curl
sudo apt-get install -qqy libreadline-dev
sudo apt-get install -qqy git-core
sudo apt-get install -qqy libjpeg-dev
sudo apt-get install -qqy libpng-dev
sudo apt-get install -qqy ncurses-dev
sudo apt-get install -qqy imagemagick
sudo apt-get install -qqy unzip
sudo apt-get update


echo "==> Torch7's dependencies have been installed"





# Build and install Torch7
cd /tmp
rm -rf luajit-rocks
git clone https://github.com/torch/luajit-rocks.git
cd luajit-rocks
mkdir -p build
cd build
git checkout master; git pull
rm -f CMakeCache.txt
cmake .. -DCMAKE_INSTALL_PREFIX=$PREFIX -DCMAKE_BUILD_TYPE=Release
RET=$?; if [ $RET -ne 0 ]; then echo "Error. Exiting."; exit $RET; fi
make
RET=$?; if [ $RET -ne 0 ]; then echo "Error. Exiting."; exit $RET; fi
make install
RET=$?; if [ $RET -ne 0 ]; then echo "Error. Exiting."; exit $RET; fi


path_to_nvcc=$(which nvcc)
if [ -x "$path_to_nvcc" ]
then
cutorch=ok
cunn=ok
fi

# Install base packages:
$PREFIX/bin/luarocks install cwrap
$PREFIX/bin/luarocks install paths
$PREFIX/bin/luarocks install torch
$PREFIX/bin/luarocks install nn

[ -n "$cutorch" ] && \
($PREFIX/bin/luarocks install cutorch)
[ -n "$cunn" ] && \
($PREFIX/bin/luarocks install cunn)

$PREFIX/bin/luarocks install luafilesystem
$PREFIX/bin/luarocks install penlight
$PREFIX/bin/luarocks install sys
$PREFIX/bin/luarocks install xlua
$PREFIX/bin/luarocks install image
$PREFIX/bin/luarocks install env

echo ""
echo "=> Torch7 has been installed successfully"
echo ""


echo "Installing nngraph ... "
$PREFIX/bin/luarocks install nngraph
RET=$?; if [ $RET -ne 0 ]; then echo "Error. Exiting."; exit $RET; fi
echo "nngraph installation completed"

echo "Installing Xitari ... "
cd /tmp
rm -rf xitari
git clone https://github.com/deepmind/xitari.git
cd xitari
$PREFIX/bin/luarocks make
RET=$?; if [ $RET -ne 0 ]; then echo "Error. Exiting."; exit $RET; fi
echo "Xitari installation completed"

echo "Installing Alewrap ... "
cd /tmp
rm -rf alewrap
git clone https://github.com/deepmind/alewrap.git
cd alewrap
$PREFIX/bin/luarocks make
RET=$?; if [ $RET -ne 0 ]; then echo "Error. Exiting."; exit $RET; fi
echo "Alewrap installation completed"

echo
echo "You can run experiments by executing: "
echo
echo " ./run_cpu game_name"
echo
echo " or "
echo
echo " ./run_gpu game_name"
echo
echo "For this you need to provide the rom files of the respective games (game_name.bin) in the roms/ directory"
echo


when I test the code ./run_gpu {game_name}, I got:

../torch/bin/luajit: error while loading shared libraries: libreadline.so.7: cannot open shared object file: No such file or directory

when I run ldconfig -p | grep readline

My version is below 6

libreadline.so.6 (libc6,x86-64) => /lib/x86_64-linux-gnu/libreadline.so.6
libreadline.so (libc6,x86-64) => /usr/lib/x86_64-linux-gnu/libreadline.so
libguilereadline-v-18.so.18 (libc6,x86-64) => /usr/lib/x86_64-linux-gnu/libguilereadline-v-18.so.18
libguilereadline-v-18.so (libc6,x86-64) => /usr/lib/x86_64-linux-gnu/libguilereadline-v-18.so

but I cannot install libreadline7 by : sudo apt-get install libreadline7-dev

Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package libreadline7-dev

How could I tackle the installation of libreadline7??

Last edited by Zhanpython; 09-15-2018 at 09:47 PM.
 
Old 09-15-2018, 10:25 PM   #2
Ztcoracat
LQ Guru
 
Registered: Dec 2011
Distribution: Slackware, MX 18
Posts: 9,484
Blog Entries: 15

Rep: Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176
Hi:

Are you running Ubuntu 18.04?

Try running:

Code:
sudo apt-get install libreadline-dev
IF that fails do a Ubuntu Package Search and manually install the pkg.
https://packages.ubuntu.com/search?k...s=libreadline7

Here's the binary pkg here but it's for Ubuntu 18.04:-
https://ubuntu.pkgs.org/18.04/ubuntu...amd64.deb.html
 
Old 09-15-2018, 10:39 PM   #3
Zhanpython
LQ Newbie
 
Registered: Sep 2018
Posts: 3

Original Poster
Rep: Reputation: Disabled
I'm running on Ubuntu 5.4.0-6ubuntu1~16.04.9, so if I run
Code:
sudo apt-get install libreadline-dev
the newest version is libreadline6, then how could I install libreadline7 manually? Thank you so much.
 
Old 09-15-2018, 10:51 PM   #4
Ztcoracat
LQ Guru
 
Registered: Dec 2011
Distribution: Slackware, MX 18
Posts: 9,484
Blog Entries: 15

Rep: Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176
It doesn't look like libreadline7 is available for Ubuntu 16.04 Xenial--
The package that you can manually install is libreadline-dev_6.3-8 ubuntu2-amd64.deb on this page under "Downloadable Files"

https://launchpad.net/ubuntu/xenial/...v/6.3-8ubuntu2

Last edited by Ztcoracat; 09-15-2018 at 11:04 PM.
 
Old 12-08-2018, 11:18 PM   #5
where
LQ Newbie
 
Registered: Dec 2018
Posts: 0

Rep: Reputation: Disabled
Hi, I tested that libreadline7 for Ubuntu 18.04 is also usable for Ubuntu 16.
Try this link:
https://packages.ubuntu.com/bionic/libreadline7
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to install libreadline.so 7 bect3000 Linux - Newbie 2 09-15-2018 09:25 PM
[SOLVED] How do I find out where libreadline.so.5 is being pulled in dugan Slackware 1 04-22-2018 02:17 AM
libreadline yovkoi Linux - Server 1 08-14-2013 09:05 AM
libreadline.so.5 Transition Slackware 3 02-18-2006 04:05 PM
libreadline.so.4 dependency problem Hunter2 Linux - Software 3 05-05-2005 06:32 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 05:02 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration