SEN2COR Install issue on Linux Ubuntu 14.04

Dear all
sorry to ask during the Xmas Holidays, I have not been able to install SEN2COR on an Ubuntu distribution.
There is no rush to answer, I can live without SEN2COR until 2016.

I have anaconda installed, and I added it in the PATH, and I exported the PATH

conda -V
conda 3.18.3

However, python setup.py install fails :

sh: 1: conda: not found
sh: 1: conda: not found
Traceback (most recent call last):
File “setup.py”, line 240, in
copy_file(libOpj2Source, libOpj2Target)
File “/usr/lib/python2.7/distutils/file_util.py”, line 109, in copy_file
“can’t copy ‘%s’: doesn’t exist or not a regular file” % src)
distutils.errors.DistutilsFileError: can’t copy ‘/usr/lib/python2.7/site-packages/sen2cor-2.0.6-py2.7.egg/sen2cor/build/lib.linux-x86_64-2.7/libopenjp2.so’: doesn’t exist or not a regular file

It must be something basic, but I did not find it. If you have any idea, many thanks.
Olivier

I restarted from scratch and it finally worked, without using sudo to install setup.py, and using a --prefix to point where the anaconda distribution is installed. Sorry to have taken your time reading my adventures.

python setup.py install --prefix /path/to/anaconda2

Hi @OHagolle,

Seems like there is still something wrong in your PATH, since python loads stuff from /usr/lib/python2.7.
You probably added anaconda dir to the end of your PATH instead of at the beginning.

Hi Olivier,

I have encountered the same warning message as yours. Could you please give more details about how you fixed this problem? Thank you so much!

PS. I am using Windows instead of Linux.

Best regards, Gao

Hi, my issues were related to confusions between the anaconda python distribution, and the one I had already on my computer. The confusion was really related to linux, I had adapted the environment variables as mentioned in the docs, but I was using “sudo” to make the installation, and on linux “sudo” uses the environment of the superuser, and not the user environment

Not sure it can help with your issue on windows.