<s> from pythonforandroid . toolchain import Recipe , shprint , current_directory , ArchARM <EOL> from os . path import exists , join , realpath <EOL> from os import uname <EOL> import glob <EOL> import sh <EOL> class FreetypeRecipe ( Recipe ) : <EOL> version = '<STR_LIT>' <EOL> url = '<STR_LIT>' <EOL> depends = [ '<STR_LIT>' ] <EOL> def should_build ( self , arch ) : <EOL> if exists ( join ( self . get_build_dir ( arch . arch ) , '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' ) ) : <EOL> return False <EOL> return True <EOL> def build_arch ( self , arch ) : <EOL> env = self . get_recipe_env ( arch ) <EOL> harfbuzz_recipe = Recipe . get_recipe ( '<STR_LIT>' , self . ctx ) <EOL> env [ '<STR_LIT>' ] = '<STR_LIT:U+0020>' . join ( <EOL> [ env [ '<STR_LIT>' ] , <EOL> '<STR_LIT>' . format ( join ( harfbuzz_recipe . get_build_dir ( arch . arch ) , '<STR_LIT:src>' , '<STR_LIT>' ) ) ] ) <EOL> with current_directory ( self . get_build_dir ( arch . arch ) ) : <EOL> configure = sh . Command ( '<STR_LIT>' ) <EOL> shprint ( configure , '<STR_LIT>' , <EOL> '<STR_LIT>' . format ( realpath ( '<STR_LIT:.>' ) ) , <EOL> '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' , <EOL> _env = env ) <EOL> shprint ( sh . make , '<STR_LIT>' , _env = env ) <EOL> shprint ( sh . cp , '<STR_LIT>' , self . ctx . libs_dir ) <EOL> recipe = FreetypeRecipe ( ) </s>
