Merge remote-tracking branch 'origin/pyjnius-recipe' into daemon-0.30
This commit is contained in:
commit
352000147c
10 changed files with 28 additions and 32 deletions
.travis.yml
app/src
component
page
styles
p4a/pythonforandroid/bootstraps/lbry/build/gradle/wrapper
recipes/pyjnius
|
@ -3,6 +3,8 @@ dist: xenial
|
|||
language: python
|
||||
python:
|
||||
- '3.6'
|
||||
jdk:
|
||||
- oraclejdk8
|
||||
install:
|
||||
- deactivate
|
||||
- export PATH=/usr/bin:$PATH
|
||||
|
|
|
@ -20,7 +20,7 @@ class FloatingWalletBalance extends React.PureComponent<Props> {
|
|||
onPress={() => navigation && navigation.navigate({ routeName: 'WalletStack' })}>
|
||||
{isNaN(balance) && <ActivityIndicator size="small" color={Colors.White} />}
|
||||
<Text style={floatingButtonStyle.text}>
|
||||
{(balance || balance === 0) && (formatCredits(balance, 2) + ' LBC')}
|
||||
{(balance || balance === 0) && (formatCredits(parseFloat(balance), 2) + ' LBC')}
|
||||
</Text>
|
||||
</TouchableOpacity>
|
||||
);
|
||||
|
|
|
@ -19,7 +19,7 @@ class WalletBalance extends React.PureComponent<Props> {
|
|||
<Text style={walletStyle.balanceTitle}>Balance</Text>
|
||||
<Text style={walletStyle.balanceCaption}>You currently have</Text>
|
||||
<Text style={walletStyle.balance}>
|
||||
{(balance || balance === 0) && (formatCredits(balance, 2) + ' LBC')}
|
||||
{(balance || balance === 0) && (formatCredits(parseFloat(balance), 2) + ' LBC')}
|
||||
</Text>
|
||||
</View>
|
||||
);
|
||||
|
|
|
@ -142,7 +142,10 @@ class RewardsPage extends React.PureComponent {
|
|||
|
||||
return (
|
||||
<View style={rewardStyle.container}>
|
||||
<ScrollView style={rewardStyle.scrollContainer} contentContainerStyle={rewardStyle.scrollContentContainer}>
|
||||
<ScrollView
|
||||
keyboardShouldPersistTaps={'handled'}
|
||||
style={rewardStyle.scrollContainer}
|
||||
contentContainerStyle={rewardStyle.scrollContentContainer}>
|
||||
{this.renderVerification()}
|
||||
{this.renderUnclaimedRewards()}
|
||||
{this.renderClaimedRewards()}
|
||||
|
|
|
@ -27,7 +27,7 @@ class WalletPage extends React.PureComponent {
|
|||
}
|
||||
|
||||
return (
|
||||
<ScrollView>
|
||||
<ScrollView keyboardShouldPersistTaps={'handled'}>
|
||||
<WalletBalance />
|
||||
<WalletAddress />
|
||||
<WalletSend />
|
||||
|
|
|
@ -65,8 +65,9 @@ const firstRunStyle = StyleSheet.create({
|
|||
},
|
||||
button: {
|
||||
alignSelf: 'flex-end',
|
||||
marginLeft: 32,
|
||||
marginRight: 32
|
||||
padding: 20,
|
||||
paddingLeft: 32,
|
||||
paddingRight: 32
|
||||
},
|
||||
buttonText: {
|
||||
fontFamily: 'Metropolis-Regular',
|
||||
|
|
|
@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME
|
|||
distributionPath=wrapper/dists
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
zipStorePath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-3.3-all.zip
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-4.6-all.zip
|
||||
|
|
|
@ -1,30 +1,20 @@
|
|||
|
||||
from pythonforandroid.toolchain import CythonRecipe, Recipe, shprint, current_directory, info
|
||||
from pythonforandroid.patching import will_build, check_any
|
||||
from pythonforandroid.recipe import CythonRecipe
|
||||
from pythonforandroid.toolchain import shprint, current_directory, info
|
||||
from pythonforandroid.patching import will_build
|
||||
import sh
|
||||
from os.path import join
|
||||
|
||||
|
||||
class PyjniusRecipe(CythonRecipe):
|
||||
version = 'master'
|
||||
version = '1.1.3'
|
||||
url = 'https://github.com/kivy/pyjnius/archive/{version}.zip'
|
||||
name = 'pyjnius'
|
||||
depends = [('python2', 'python3crystax'), 'genericndkbuild', 'six']
|
||||
depends = [('python2', 'python3crystax'), ('genericndkbuild', 'sdl2', 'sdl'), 'six']
|
||||
site_packages_name = 'jnius'
|
||||
call_hostpython_via_targetpython = False
|
||||
|
||||
patches = [('sdl2_jnienv_getter.patch', will_build('sdl2')),
|
||||
('genericndkbuild_jnienv_getter.patch', will_build('genericndkbuild'))]
|
||||
|
||||
def get_recipe_env(self, arch):
|
||||
env = super(PyjniusRecipe, self).get_recipe_env(arch)
|
||||
target_python = Recipe.get_recipe('python3crystax', self.ctx).get_build_dir(arch.arch)
|
||||
env['PYTHON_ROOT'] = join(target_python, 'python-install')
|
||||
env['CFLAGS'] += ' -I' + env['PYTHON_ROOT'] + '/include/python3.6'
|
||||
env['LDFLAGS'] += ' -L' + env['PYTHON_ROOT'] + '/lib' + ' -lpython3.6m'
|
||||
|
||||
return env
|
||||
|
||||
def postbuild_arch(self, arch):
|
||||
super(PyjniusRecipe, self).postbuild_arch(arch)
|
||||
info('Copying pyjnius java class to classes build dir')
|
||||
|
|
|
@ -16,10 +16,10 @@ index 740510f..0c8e55f 100644
|
|||
+++ b/setup.py
|
||||
@@ -53,7 +53,7 @@ except ImportError:
|
||||
|
||||
if platform == 'android':
|
||||
if PLATFORM == 'android':
|
||||
# for android, we use SDL...
|
||||
- libraries = ['sdl', 'log']
|
||||
+ libraries = ['main', 'log']
|
||||
library_dirs = ['libs/' + getenv('ARCH')]
|
||||
elif platform == 'darwin':
|
||||
- LIBRARIES = ['sdl', 'log']
|
||||
+ LIBRARIES = ['main', 'log']
|
||||
LIBRARY_DIRS = ['libs/' + getenv('ARCH')]
|
||||
elif PLATFORM == 'darwin':
|
||||
import subprocess
|
||||
|
|
|
@ -16,10 +16,10 @@ index 740510f..0c8e55f 100644
|
|||
+++ b/setup.py
|
||||
@@ -53,7 +53,7 @@ except ImportError:
|
||||
|
||||
if platform == 'android':
|
||||
if PLATFORM == 'android':
|
||||
# for android, we use SDL...
|
||||
- libraries = ['sdl', 'log']
|
||||
+ libraries = ['SDL2', 'log']
|
||||
library_dirs = ['libs/' + getenv('ARCH')]
|
||||
elif platform == 'darwin':
|
||||
- LIBRARIES = ['sdl', 'log']
|
||||
+ LIBRARIES = ['SDL2', 'log']
|
||||
LIBRARY_DIRS = ['libs/' + getenv('ARCH')]
|
||||
elif PLATFORM == 'darwin':
|
||||
import subprocess
|
||||
|
|
Loading…
Add table
Reference in a new issue