NI Linux Real-Time Discussions

cancel
Showing results for 
Search instead for 
Did you mean: 

linuxRT(cRIO 9037) pip install unsuccessful with python 2.7 or 3.3 installed

Solved!
Go to solution
Solution
Accepted by topic author kjiang

Hi BradM,

      I have solved this problem by use the following steps.

1. install python(opkg install python)
2.Download the pip ipk file(python-pip_1.3.1-r0.2_x86_64.ipk) from server I have said in last reply. And copy the ipk file in home/admin folder.
3.Run# opkg install python-pip_1.3.1-r0.2_x86_64.ipk
4.after install successfully, pip still cannot work normally. So I download the newest get-pip.py from https://pip.pypa.io/en/stable/installing/  and put in admin folder.
5.run:# python get-pip.py. The pip can work successfully
6. after finished. I test the pip and it works normally.
 
On other hand, I have installed numpy successfully both by the pip and opkg method. Thanks for your help.

 

 


BradM 已写:

First, since you're using 2016, I would take a look at installing the python-pip package using the already-configured feed repositories.

 

As it stands, there's only one version of python 2 (2.7.9) and one version of python 3 (3.3.3) in the NI feeds for 2016.

 

Also, going back to your original question, there are python packages for many optional packages/eggs/etc. already on the feeds, including numpy.

 

Run opkg update && opkg list | grep python for an idea of what's available without needing to dive in too deeply.


 

0 Kudos
Message 11 of 20
(4,728 Views)

Hi BradM,

 

     For the reason, I want to use our cRIO run python script which may use some third party python tools. Then combine the LV RT program and python script calculate results. So I want to install some third party python software.

 

    Does all the NI feeds in the following link? http://feeds.angstrom-distribution.org/feeds/v2013.12/ipk/eglibc/x86_64/python/

    Are there any other location can I search for?

 


BradM 已写:

As a final thought, wanting to use other feed repos, especially older ones using a different version of the base C runtime (eglibc 2.18 vs. glibc 2.21), let alone differences in how the OE systems setup to build the contents of those repositories very well may work in many cases, but it is also an invitation to a lot of weird, hard-to-diagnose failures or errant behavior, so I would be careful if you intend on using other feeds.

 

tl;dr is "Don't use non-NI feeds unless you really, really need to and accept that you'll need to work out any problems that come from installing software from those feeds"


 

0 Kudos
Message 12 of 20
(4,727 Views)

 

4.after install successfully, pip still cannot work normally.

 

Can you expand on this a bit? What did you see when attempting to use the installed pip? Also, is there any reason you're downloading the .ipk files, transfering them to the target, then installing them instead of just installing them from the target in the first place? Is the target not on the network?

0 Kudos
Message 13 of 20
(4,679 Views)

 

Does all the NI feeds in the following link? http://feeds.angstrom-distribution.org/feeds/v2013.12/ipk/eglibc/x86_64/python/
Are there any other location can I search for?

 

 

http://download.ni.com/ni-linux-rt/feeds/

0 Kudos
Message 14 of 20
(4,678 Views)

BradM 已写:

 

4.after install successfully, pip still cannot work normally.

 

Can you expand on this a bit? What did you see when attempting to use the installed pip? Also, is there any reason you're downloading the .ipk files, transfering them to the target, then installing them instead of just installing them from the target in the first place? Is the target not on the network?



I attempt to use pip command to test the function. However, It generate error. 

I use the ipk file to install, just because I have downloaded it manually.

Thanks.

0 Kudos
Message 15 of 20
(4,651 Views)

Hi BradM,

I also encountered similar problem when I tried to install pip in cRIO-9037 (LV2017). I have successfully installed python2.7.11 and python3.5.1 by using opkg install, however, when I tried to pip with the commad ‘opkg install python-pip’, the following error showed:

admin@NI-cRIO-9036-01C54746:~# opkg install python-pip
Solver encountered 1 problem(s):
Problem 1/1:
- package python-pip-8.1.1-r0.14.core2-64 requires python-modules, but none of the providers can be installed

Solution 1:
- allow deinstallation of python-zip-2.7.11-r1.107.core2-64

Solution 2:
- do not ask to install a package providing python-pip

admin@NI-cRIO-9036-01C54746:~# opkg install python-modules
Solver encountered 1 problem(s):
Problem 1/1:
- package python-modules-2.7.11-r1.130.core2-64 requires python-hotshot, but none of the providers can be installed

Solution 1:
- allow deinstallation of python-zip-2.7.11-r1.107.core2-64

Solution 2:
- do not ask to install a package providing python-modules

admin@NI-cRIO-9036-01C54746:~# opkg install python-hotshot
Solver encountered 1 problem(s):
Problem 1/1:
- package python-hotshot-2.7.11-r1.130.core2-64 requires libpython2 >= 2.7.11, but none of the providers can be installed

Solution 1:
- allow deinstallation of python-zip-2.7.11-r1.107.core2-64

Solution 2:
- do not ask to install a package providing python-hotshot

 

I also tried steps with which kjiang has installed pip successfully on cRIO-9036, but encountered the same problem, so I would like to know whether you have some ideas, thanks.

0 Kudos
Message 16 of 20
(4,638 Views)

If possible, remove python_zip and try installing the full python (and -modules) packages.

0 Kudos
Message 17 of 20
(4,578 Views)

I just got the library installed by using the -force-depends. On a myRIO 1900 

 

 

0 Kudos
Message 18 of 20
(4,547 Views)

Hi. I am trying to install python 3.5 in myRIO. I am only able to install python 2.7 using opkg install python. Can you show me the steps you took to install python 3.5? Thank you.

0 Kudos
Message 19 of 20
(4,380 Views)

Hi ducnguyen,

 

I was able to install it on my target (cRIO-9033, also Linux RT) with opkg install python3. As mentioned above, you might need to do an opkg update first.

Andrew T.
"His job is to shed light, and not to master" - Robert Hunter
Message 20 of 20
(3,618 Views)