forked from blackberry/Python
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
46 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,43 @@ | ||
This repository holds the BlackBerry 10 port of Python-3.2.2. | ||
|
||
Our intent with this repository is: | ||
1. Fulfill any license requirements by publishing any of our source code changes | ||
2. To enable the larger community to build their own binaries which will run on BlackBerry 10 / PlayBook devices | ||
3. To prepare and formalize our patch-set, in preparation for a push to the upstream Python.org repository. Community assistance with this effort will be greatly appreciated, as internal commitments have most RIM employees tied up right now :) | ||
|
||
Build notes | ||
1. Install BlackBerry 10 NDK tools and make sure environment variables are set up | ||
2. Seems we need a case-sensitive build environment (partition accordingly on OSX, or create a DMG to build in) | ||
3. May need to install Mercurial (Hg) | ||
4. May need an existing host-native python installation | ||
## BlackBerry 10 Python port | ||
|
||
### Current status | ||
|
||
* Python 3.2.2 from BlackBerry building and working fine in the [Berrymuch](https://github.com/berryamin/berrymuch) prefix | ||
|
||
### Roadmap | ||
|
||
* Adapt the patchset for Python 3.4 | ||
* Bundle into Berrymuch | ||
|
||
### Development | ||
|
||
#### Cross-compilation for ARM | ||
|
||
* Get an OS supported by the BlackBerry Native SDK (we recommend [32-bit Ubuntu 16.04](http://releases.ubuntu.com/16.04/ubuntu-16.04.6-desktop-i386.iso)) | ||
* Install the [BlackBerry Native SDK](https://developer.blackberry.com/native/download/) | ||
* Install a few other packages: | ||
``` | ||
sudo apt install mercurial python | ||
``` | ||
* Clone this repository and run: | ||
``` | ||
source ~/path/to/bbndk/bbndk_env.sh | ||
cd Python-3 | ||
./host.build | ||
./nto-armv7.build | ||
``` | ||
|
||
#### Running on Berrymuch | ||
|
||
* Package it up: | ||
``` | ||
cd nto-armv7/accounts/1000/shared/documents/clitools | ||
zip -yr python-3.2.zip . | ||
``` | ||
* Transfer the package to your Berrymuch device and install with `pbpkgadd` | ||
* Add to your `~/.profile`: | ||
``` | ||
export PYTHONPATH="/accounts/1000/shared/documents/clitools/lib/python3.2:/accounts/1000/shared/documents/clitools/lib/python3.2/lib-dynload" | ||
``` | ||
* Enjoy | ||
|