Not include directory in Python 3.6 with virtualenv - virtualenv

I am creating two virtual environments named as "venv35" and "venv36" for Python 3.5 and 3.6, respectively. The sub-directory "include" is missing in "venv36", thus "Python.h" cannot found at this environment (Python 3.6). Any ideas about it?
$ virtualenv -p python3.5 venv35
$ virtualenv -p python3.6 venv36
$ ls -la venv35 venv36
venv35:
total 28
.
..
bin
include
lib
pip-selfcheck.json
share
venv36:
total 24
.
..
bin
lib
pip-selfcheck.json
share

If a virtual environment is created with "venv", we get:
$ /usr/bin/python3.6 -m venv py36
$ ls -la py36/
total 32
.
..
bin
include
lib
lib64 -> lib
pip-selfcheck.json
pyvenv.cfg
share
The "include" folder is still empty so the solution seems to be the creation of a symbolic link to the original "include" folder location.
ln -s /usr/include/python3.6/ py36/include/python3.6

You might need to install the headers for Python 3.6:
sudo apt install python3.6-dev

Related

Steps to install perl version 5.26.3 in Solaris 11 Host

I would like to install perl version 5.26.3 in host running with Solaris 11 using service account. The installation has to be done in Application file system or in user directory.
Please could someone share with the steps to install ?
Please note that perl 5.26 version is already installed at OS level , but we want to have our own perl installation in application folder rather than using OS level perl interpreter
Thanks.
Here is an example of installing from source using the defaults. If you want to modify the defaults, have a look at the INSTALL document.
$ wget https://www.cpan.org/src/5.0/perl-5.26.3.tar.bz2
$ bunzip2 perl-5.26.3.tar.bz2
$ tar xvf perl-5.26.3.tar
$ cd perl-5.26.3
$ sh Configure -de -Dprefix='/some/dir' # Where to install
$ make
$ make test
$ make install
Then edit the PATH environment variable to include /some/dir/bin such that the shell can find the new perl.

cannot activate virtualenv: No such file or directory

I have problem with activating virtualenv.
I'm working on the server and using SSH secure shell.
My final goal is to activate virtualenv and run the latest version of tensorflow
The following is the command lines:
jeonguyoang#vision6:~$ python3 -m venv tfenv
The virtual environment was not created successfully because ensurepip is not
available. On Debian/Ubuntu systems, you need to install the python3-venv
package using the following command.
apt-get install python3-venv
You may need to use sudo with that command. After installing the python3-venv
package, recreate your virtual environment.
jeonguyoang#vision6:~$ source tfenv/bin/activate
-bash: tfenv/bin/activate: No such file or directory
jeonguyoang#vision6:~$ cd tfenv
jeonguyoang#vision6:~/tfenv$ ls
bin include lib lib64 pyvenv.cfg
jeonguyoang#vision6:~/tfenv$ cd bin
jeonguyoang#vision6:~/tfenv/bin$ ls
python python3
captured image of the commands
I think that there is no activate file.
Maybe re-installing virtualenv is the answer, but I cannot interrupt server settings..
Check if you have python 2 versions of pip and python (python-all & python-pip packages). Venv installs both v2 and v3 versions of python & pip (regardless of python version of venv).

How to install CouchDB plugin/daemon like couchperuser

How can one install a CouchDB plugin/daemon like couchperuser?
Install any dependencies. couchperuser requires rebar, e.g.
$ brew install rebar
Ensure the plugin directory exists, e.g.
$ mkdir /usr/local/Cellar/couchdb/1.6.0_1/lib/couchdb/plugins
Clone (download) the repo:
$ git clone https://github.com/etrepum/couchperuser.git
Move the plugin files:
$ mv couchperuser /usr/local/Cellar/couchdb/1.6.0_1/lib/couchdb/plugins
Build the plugin files:
$ cd /usr/local/Cellar/couchdb/1.6.0_1/lib/couchdb/plugins/couchperuser
$ make
Restart couchdb

Octave docs not present

octave:1> doc fflush
info: /usr/local/Cellar/octave/3.6.3/share/info/octave.info: No such file or directory
I'm not sure what I've done wrong with my installation, but I get the msg above when attempting to find the documentation (help fflush works fine). Does anyone know how to fix this issue?
I had the same problem and solved it with manually decompressing the corresponding deb archive to the respective place of the brew installation:
Download the deb from here : http://packages.ubuntu.com/de/quantal/all/octave-info/download
cd ~/Downloads
mkdir doc
cd doc
ar -x ../octave-info_3.6.2-5_all.deb
tar xzf data.tar.gz
cd usr
find . -name '*.gz' -type f -exec gunzip "{}" \;
cd ..
cp -r share /usr/local/Cellar/octave/3.6.4/
cd ~/Downloads
rm -r doc
You have to adjust the octave version numbers to match the most recent and your brew cellar of course.
I don't know about Mac OSC. If you had built it yourself, could have been that you disabled the documentation at build time. With a package manager... you already checked that it does not have a separate octave-doc package.
There's a bunch of other package managers for Mac that have Octave. See Octave's wiki. Taking a quick look at the other package managers, it seems that they all have separate packages for docs.

Installing LuaMongo on Ubuntu 11.10

I have researched and viewed the post to install luamongo- http://groups.google.com/group/luamongo/browse_thread/thread/1eaa56974614dc90/c91c842e241aa4de#c91c842e241aa4de
But the installation will not work. I already have mongodb-10gen version 2.0.3 and lua5.1 version 5.1.4.10 installed.
How do I download luamongo from https://github.com/moai/luamongo and install it and get it working as an import statement in a lua script to be able to write to a mongo db? Any suggestions would be helpful, nothing I have tried so far or read has been able to help. If more information is needed I will post it. Thanks in advance.
I got this script from a friend of mine which should be helpful:
# Download mongodb and driver
wget http://downloads.mongodb.org/cxx-driver/mongodb-linux-x86_64-v2.0-latest.tgz
wget http://fastdl.mongodb.org/linux/mongodb-linux-x86_64-2.0.2.tgz
# Extract each
tar xvzf mongodb-linux-x86_64-2.0.2.tgz
tar xvzf mongodb-linux-x86_64-v2.0-latest.tgz
# Add mongo bin to PATH
export PATH=$PATH:~/mongodb-linux-x86_64-2.0.2/bin
# Grab dev tools and dependencies (May need to run apt-get update to download all)
sudo apt-get -y install tcsh scons libpcre++-dev libboost-dev libreadline-dev libboost-program-options-dev libboost-thread-dev libboost-filesystem-dev libboost-date-time-dev gcc g++ git lua5.1-dev make
# Grab latest luamongo (will need to add your github ssh key)
git clone git#github.com:moai/luamongo
# Compile mongo driver
cd mongo-cxx-driver-v2.0
sudo scons install
# Install where lua can load it
sudo cp libmongoclient.* /usr/lib