LinuxQuestions.org
Share your knowledge at the LQ Wiki.
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 12-15-2017, 12:33 PM   #1
danielswift
LQ Newbie
 
Registered: Dec 2017
Posts: 14

Rep: Reputation: Disabled
Adding Python package to Buildroot


Hi there,

I am running an embedded system on Buildroot. I want to run a Python application on it which requires the PyDrive module.

I tried following this tutorial: https://github.com/maximeh/buildroot...ges-python.txt

and created a make and configuration file for PyDrive but PyDrive does not show up in my target packages. Does anyone know how to do this correctly?

Thanks,

D
 
Old 12-18-2017, 09:13 AM   #2
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,836

Rep: Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308
I don't know this buildroot toolchain, but probably pip will work for you, so you can pip install PyDrive.
 
Old 12-18-2017, 02:03 PM   #3
danielswift
LQ Newbie
 
Registered: Dec 2017
Posts: 14

Original Poster
Rep: Reputation: Disabled
Unfortunately, my distribution does not have pip installed.

Thanks anyways for your help.
 
Old 12-18-2017, 02:04 PM   #4
danielswift
LQ Newbie
 
Registered: Dec 2017
Posts: 14

Original Poster
Rep: Reputation: Disabled
FYI, I don't need help installing pyDrive specifically but any python package into buildroot using menuconfig.
 
Old 12-18-2017, 02:07 PM   #5
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,836

Rep: Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308
You can run pip install on your linux box, not on your embedded device. There are 2 cases - if it compiles something (most probably an so) you will need to recompile it for your embedded system. If not, you only need to pack the result and copy onto your device (but you may need to take care about dependencies too).
 
Old 12-18-2017, 03:17 PM   #6
danielswift
LQ Newbie
 
Registered: Dec 2017
Posts: 14

Original Poster
Rep: Reputation: Disabled
Hi there,

Sorry I am new to the Linux enviorment. How would I accomplish the cross compilation?

Thanks
 
Old 12-18-2017, 03:19 PM   #7
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,836

Rep: Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308
I think buildroot is used to do that
 
Old 12-18-2017, 03:21 PM   #8
danielswift
LQ Newbie
 
Registered: Dec 2017
Posts: 14

Original Poster
Rep: Reputation: Disabled
I am sorry pan64. Could you clarify. I'm not sure if its me or that sentence did not make sense to me.
 
Old 12-18-2017, 03:24 PM   #9
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,836

Rep: Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308
it was your first sentence:
Quote:
I am running an embedded system on Buildroot.
If it was this: https://buildroot.org/, you can use it to compile additional packages too. But probably I have misunderstood.
 
Old 12-18-2017, 03:27 PM   #10
danielswift
LQ Newbie
 
Registered: Dec 2017
Posts: 14

Original Poster
Rep: Reputation: Disabled
Thanks pan64. I was wondering if you knew of any tutorial that taught me to do this or if you knew yourself. I am new to Linux, buildroot .etc and do not know how to cross compile the python package I would like to include.
 
Old 12-19-2017, 04:17 AM   #11
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,836

Rep: Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308
I played a bit with it, and it looks like you will need the following packages (they required by PyDrive):
Quote:
pip install PyDrive
.....
Successfully installed PyDrive PyYAML google-api-python-client oauth2client six uritemplate httplib2 pyasn1 rsa pyasn1-modules
The next question is: which packages are already available at you, because PyDrive itself does not require crosscompilation.

PyDrive is not a regular deb package, but a pip package, so you cannot put it directly into your system.
pip is available as a regular package, probably you will find it as python-pip
 
Old 12-19-2017, 08:17 AM   #12
danielswift
LQ Newbie
 
Registered: Dec 2017
Posts: 14

Original Poster
Rep: Reputation: Disabled
Hi,

I cannot find python-pip in menuconfig for buildroot.

Quote:
but a pip package, so you cannot put it directly into your system.
Does this mean I cannot use PyDrive?

Thanks
 
Old 12-19-2017, 08:21 AM   #13
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,836

Rep: Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308
what OS (distro) do you use at all?
 
Old 12-19-2017, 08:51 AM   #14
danielswift
LQ Newbie
 
Registered: Dec 2017
Posts: 14

Original Poster
Rep: Reputation: Disabled
Linux buildroot 4.1.15 #3 SMP PREEMPT Thu Dec 7 16:50:14 EST 2017 armv7l GNU/Linux
 
Old 12-19-2017, 09:02 AM   #15
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,836

Rep: Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308
I think this is the target os, not the one where you run your build. isn't it?
 
  


Reply

Tags
buildroot, python



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
Adding an extra python repo for 'yum' & finding 'pip' package NikosGr Linux - Newbie 4 06-04-2013 04:25 AM
Adding Package To Buildroot kells Linux From Scratch 1 02-21-2013 10:51 AM
Buildroot m4 package make error parag_opensrc Linux - Embedded & Single-board computer 0 09-19-2009 01:43 AM
Errors while configuring buildroot package. ravi_chobey Linux - Software 1 04-02-2009 07:22 PM
make menuconfig -buildroot error can't open file "package/festival/speech-tool balraj Linux - Newbie 0 09-08-2008 01:05 PM

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

All times are GMT -5. The time now is 04:26 AM.

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