[ANN] IOS support for Kivy

4,346 views
Skip to first unread message

Mathieu Virbel

unread,
Mar 11, 2012, 6:08:55 PM3/11/12
to kivy...@googlegroups.com, kivy-...@googlegroups.com
Hi everyone,

We are glad to announce the IOS support for Kivy. The instructions are available at: 


This support is the result of a work started almost one year ago, including a research done by Christopher.
The current implementation have been tested only on an IPad2. We don't have any information about other ipad / iphone.

Kivy demos on iPad2 are a lot smoother than the Motorola Xoom :) As we said 2 weeks ago, Apple already accepted the first Kivy-based application: Deflectouch. There is no issues with Python embed, etc, on this platform.

This is a new step in the life of Kivy, supporting 5 platforms without changing a single line of your application. We hope you'll publish more applications based on Kivy, and help us to make this toolkit a valuable alternative to create applications and games.

Enjoy,

Mathieu

Arnaud Waels

unread,
Mar 12, 2012, 10:36:29 PM3/12/12
to kivy-...@googlegroups.com
That 's freaking kicking ass news !!

2012/3/11 Mathieu Virbel <m...@kivy.org>

Tim Henning

unread,
Mar 13, 2012, 2:43:59 PM3/13/12
to kivy-...@googlegroups.com, kivy...@googlegroups.com
Hey!
Very good news! But now I need to find someone who publishes my app for me, because 99$ per year is way too much for a student like me :-(
Or is there some way to get around this fee? Could we build an app for a jailbreaked iOS device for free?
Tim

Christopher Allick

unread,
Mar 13, 2012, 2:46:19 PM3/13/12
to kivy-...@googlegroups.com
You're University can have an account you don't pay for.  I believe you can publish apps from it.  Not 100% you can charge for them though.

- chris allick

YEU-JIUN WANG

unread,
Mar 14, 2012, 6:29:18 AM3/14/12
to kivy-...@googlegroups.com, kivy...@googlegroups.com
Hi,

This is really amazing. I have successfully run the kivy app on my iPhone 3gs. Is there a plan to have gstreamer support on iOS?


Eugene

Mathieu Virbel

unread,
Mar 14, 2012, 6:37:44 AM3/14/12
to kivy-...@googlegroups.com
Did it run out of the box without any changes?
Because at least, the xcode project by default stick for ipad.

Can you share the process?

Dunno about gstreamer on ios, i see ios is wrote in the changelog, but never tested it. If it's just for reading video/audio, i'm going to commit a build-ffmpeg as well, then Kivy will have limited Video support.

YEU-JIUN WANG

unread,
Mar 14, 2012, 10:18:10 PM3/14/12
to kivy-...@googlegroups.com
Hi,

I encountered some problems at the beginning to build on my Xcode 4.2.1. I must mention that I am not quite familiar with the Xcode environment. The target destination in the Xcode project always shows iOS device. I find no way to add new destination like iPhone or iPad simulators. When I run the build, the message always shows that I need to have the provision license to run the device or something. Therefore, I decided to apply for a iOS developer license to deployed to my iPhone3gs. After I got the license activation code, I follow the activation process and generate the keys and the device provision profile for my 3gs and also add to the organizer in Xcode. The only thing I changed is changing the target device from iPad to iPhone. When I connect my 3gs into my air, it automatically shows up in the destination and then I could run the build and deploy to my device. 
I don't know how to add simulator into the destination when the project is created through the script provided. Anybody knows how could help on this? For the gstreamer part I mentioned, I don't know much about the kivy build process. Could you just let videoplayer.py sample run on iOS and share with us. That would be very helpful.

Eugene

Mathieu Virbel

unread,
Mar 16, 2012, 5:26:51 AM3/16/12
to kivy-...@googlegroups.com
Hi,

Building for the simulator is currently not supported within the toolchain. This might be changing in the future. Right now, you need a device connected to make it works :)

Mathieu
Message has been deleted
Message has been deleted

CptRedbeard

unread,
Apr 21, 2012, 2:22:15 AM4/21/12
to kivy-...@googlegroups.com
So far some extra steps I had to use were to download and build HG (mercurial), SDL 1.2.4 and SDL 2.0.0 (http://www.libsdl.org/hg.php)

But now I'm stuck shortly after
"Generating configuration files for vorbisdec, please wait....
  aclocal -I /usr/local/share/aclocal
  glibtoolize --automake
  autoheader
  automake --add-missing
  autoconf"

with the lines

"./configure: line 11441: PKG_PROG_PKG_CONFIG: command not found
./configure: line 11446: syntax error near unexpected token `OGG,'
./configure: line 11446: `  PKG_CHECK_MODULES(OGG, ogg >= 1.0, HAVE_OGG=yes, HAVE_OGG=no)'"

CptRedbeard

unread,
Apr 21, 2012, 5:12:46 PM4/21/12
to Kivy users support
Alright I got everything running on the iPhone and iPad now. Although
the touch input on the iPhone is in the wrong places, but this may be
a quick fix somewhere.

The steps I used were to install macports (http://www.macports.org/)
and
"sudo port install" anything which seemed to be missing, which at this
step was libogg (sudo port install libogg), libvorbis, that I
remember, but there was probably something else.

After this the build-all script still errored with the same error, but
I installed SDL 2.0 also because trying to build sdl_mixer by itself
complained about missing SDL 2.

Perhaps all these steps (building SDL 2, sdl_mixer independently,
using macports for the lib ogg's) were unneccessary however, because
when instead of running "build-all" i ran "build-kivy" it had
everything it needed at that point to create libkivy.a and the
subsequent xcode project created using the provided script included
all the libraries I needed. (perhaps it was unneccessary that I also
copied some random libs into /usr/lib/)

I'm glad I got everything working as it would be sweet to write an app
once and deploy it simeltaneously on android, iphone, and a multi-
touch table that I am using. However, would it not be possible to
post online an XCode project which includes all the required libraries
in their built states? Similar to eosgarden's iOS openCV project:
http://www.eosgarden.com/en/opensource/opencv-ios/download/

tl;dr: Hooray
Message has been deleted

Dominique Burnand

unread,
Apr 22, 2012, 4:15:19 AM4/22/12
to kivy-...@googlegroups.com
I stuck on the same part.
With building different version of pkgconfig I somehow got over this first error but now I'm stuck on:
checking for OGG... checking for Ogg... cross compiling; assumed OK... 
yes
checking for oggpack_writealign... no
configure: error: Ogg >= 1.0 required !

However, CptRedbeard: How did you build kivy successfully?
(I run this on a fresh installed OSX10.7 with XCode 4.2)
Did you install something additionally? It always fails on this:
arm-apple-darwin10-llvm-gcc-4.2: kivy/graphics/opengl.c: No such file or directory
arm-apple-darwin10-llvm-gcc-4.2: no input files
 error: command '/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/arm-apple-darwin10-llvm-gcc-4.2' failed with exit status 1

And I agree with CptRedbeard an XCode project which includes all libraries in their built state would make the life might easier.

Mathieu Virbel

unread,
Apr 22, 2012, 8:00:12 AM4/22/12
to kivy-...@googlegroups.com
The macport part for SDL / ogg is not needed, because SDL is shipped
already in macports.

I'll try to see what's wrong with ogg anyway.

Mathieu Virbel

unread,
Apr 22, 2012, 8:47:59 AM4/22/12
to kivy-...@googlegroups.com
For that one, you need cython installed

Mathieu Virbel

unread,
Apr 22, 2012, 8:51:09 AM4/22/12
to kivy-...@googlegroups.com
Ok, this issue is fixed.

Just for explaining, when you install a library with brew, it will be
compiled for your system. Installating SDL-*, libogg is no-sense here,
because kivy-ios are downloading them, and compile for ARM architecture.

You are the early testers, and i did'nt get a chance to test the whole
build toolchain from a clean / empty environment. This was a mistake on
my part :/

Tell me if the fix works for you (git pull, git clean -dxf (save your
app project before!), and tool/build-all.sh)

Regards,

Mathieu


On 21/04/2012 23:12, CptRedbeard wrote:

Dominique Burnand

unread,
Apr 22, 2012, 9:27:06 AM4/22/12
to kivy-...@googlegroups.com
Thanks this is working fine now! (the ogg thing)

Compiling Kivy is still my problem.
I've downloaded Cython-0.16 and installed it typing: sudo python setup.py install
Also when I type into the terminal "cython -V" it response with: Cython version 0.16

Here are some of the lines when I try building it: http://paste.pocoo.org/show/585573/

I think I'm doing here generally something wrong?

Mathieu Virbel

unread,
Apr 23, 2012, 3:25:12 AM4/23/12
to kivy-...@googlegroups.com
It really look like you have an issue with your cython installation.
Maybe try to remove every cython package installed on your computer,
then reinstall only one ? Maybe this is due to a mix between 2
differents cython version.

Traceback (most recent call last):
File "/usr/local/bin/cython", line 8, in <module>
main(command_line = 1)

-> directly from the cython binary :)

Dominique Burnand

unread,
Apr 23, 2012, 8:07:59 AM4/23/12
to kivy-...@googlegroups.com
Thanks for your help so far, now I got it finally to work.
After several re-installing Cython2.6 without success I tried with Cython2.5.1 - this one works!

But now I stuck on something else:
If I try to compile (run) the App in Xcode some errors are popping up:

Additional info (might mater?):
- I built all with an installed Xcode version 4.2 (Because the folder /Developer is now(Xcode4.3) in the Xcode.app)
- My iPad's iOS version is 5.1, so I needed Xcode 4.3. - (I'm try compiling the App now with Xcode4.3)

Any thoughts what went wrong here?

Dominique Burnand

unread,
Apr 23, 2012, 9:30:30 AM4/23/12
to kivy-...@googlegroups.com
I tried this on another mac, which didn't had SDL installed so far.
With macports (libsdl) installed, all is working perfect!

Thanks for all your help!

Mathieu Virbel

unread,
Apr 23, 2012, 9:51:30 AM4/23/12
to kivy-...@googlegroups.com
Again, this is very weird, SDL shoudn't been required for it :/

xhuang

unread,
Apr 25, 2012, 8:05:54 PM4/25/12
to kivy-...@googlegroups.com, kivy...@googlegroups.com
I tried this out and it works after fixing a few minor issues. this is awesome! 

The only concern/complaint I have is the loading time takes too long. There must be at least 6-7 seconds of black screen before anything else happens. What if anything can I do to speed this up? 

Wilson

CptRedbeard

unread,
May 6, 2012, 5:33:16 AM5/6/12
to Kivy users support
I would like to cross compile another python library for use with Kivy
iOS, this is the pyo library from: http://code.google.com/p/pyo/wiki/Installation

I've tried to modify its setup.py to include some extra flags I get an
error of unrecognized gcc command line options.

So far I have tried -march=armv7 -arch armv7 and others along these
lines. Any suggestions?

Thanks

Mathieu Virbel

unread,
May 7, 2012, 9:39:24 PM5/7/12
to kivy-...@googlegroups.com
Well, best would be to provide the full log of the compilation :)
Normally, under kivy-ios, you could see how we are doing for others libraries (check build-lxml.sh):

# build lxml
OLD_CC="$CC"
OLD_LDFLAGS="$LDFLAGS"
OLD_LDSHARED="$LDSHARED"
export CC="$ARM_CC -I$BUILDROOT/include -I$TMPROOT/libxslt-$XSLT_VERSION"
export LDFLAGS="$ARM_LDFLAGS -L$TMPROOT/libxslt-$XSLT_VERSION/libxslt/.libs"
export LDFLAGS="$LDFLAGS -L$TMPROOT/libxslt-$XSLT_VERSION/libexslt/.libs"
export LDFLAGS="$LDFLAGS -L$TMPROOT/libxml2-$XML2_VERSION/.libs"
export LDSHARED="$KIVYIOSROOT/tools/liblink"

pushd $TMPROOT/lxml-$LXML_VERSION
HOSTPYTHON=$TMPROOT/Python-$PYTHON_VERSION/hostpython
try $HOSTPYTHON setup.py build_ext
try $HOSTPYTHON setup.py install -O2 --root iosbuild
popd

export CC="$OLD_CC"
export LDFLAGS="$OLD_LDFLAGS"
export LDSHARED="$OLD_LDSHARED"

ARM_CC etc are the one to use, and preconfigured with the right flags.

Mathieu 

CptRedbeard

unread,
May 8, 2012, 3:26:13 AM5/8/12
to Kivy users support
Thanks for the tip, I've made definite progress. I have built the
libpyo.a, but when I try to build my project in XCode I run into many
errors about undefined symbols referenced from pyo (shown at bottom).
Do you think it is possible to get this library running on the iPad/
iPhone? It can be used with many different audio frameworks such as
portaudio, port midi, and core audio. I figured if I built pyo with
its --core-audio flag that this may work, but now I don't know. I am
using Pyo to create Sine waves of certain frequencies with a user
generated beat and some filters to play audio. This has been
succesful on Windows and MacOSX thus far.

Thanks for the help

Undefined symbols for architecture armv7:
"_Pa_CloseStream", referenced from:
_Server_pa_deinit in libpyo.a(_pyo.so.o)
"_Pa_GetDefaultHostApi", referenced from:
_portaudio_get_default_host_api in libpyo.a(_pyo.so.o)
"_Pa_GetDefaultInputDevice", referenced from:
_portaudio_get_default_input in libpyo.a(_pyo.so.o)
_Server_pa_init in libpyo.a(_pyo.so.o)
"_Pa_GetDefaultOutputDevice", referenced from:
_portaudio_get_default_output in libpyo.a(_pyo.so.o)
_Server_pa_init in libpyo.a(_pyo.so.o)
"_Pa_GetDeviceCount", referenced from:
_portaudio_get_input_devices in libpyo.a(_pyo.so.o)
_portaudio_get_output_devices in libpyo.a(_pyo.so.o)
_portaudio_list_devices in libpyo.a(_pyo.so.o)
_portaudio_count_devices in libpyo.a(_pyo.so.o)
_Server_pa_init in libpyo.a(_pyo.so.o)
"_Pa_GetDeviceInfo", referenced from:
_portaudio_get_default_output in libpyo.a(_pyo.so.o)
_portaudio_get_default_input in libpyo.a(_pyo.so.o)
_portaudio_get_input_devices in libpyo.a(_pyo.so.o)
_portaudio_get_output_devices in libpyo.a(_pyo.so.o)
_portaudio_list_devices in libpyo.a(_pyo.so.o)
_Server_pa_init in libpyo.a(_pyo.so.o)
"_Pa_GetErrorText", referenced from:
_portaudio_get_default_output in libpyo.a(_pyo.so.o)
_portaudio_get_default_host_api in libpyo.a(_pyo.so.o)
_portaudio_get_default_input in libpyo.a(_pyo.so.o)
_portaudio_list_host_apis in libpyo.a(_pyo.so.o)
_portaudio_count_host_apis in libpyo.a(_pyo.so.o)
_portaudio_get_input_devices in libpyo.a(_pyo.so.o)
_portaudio_get_output_devices in libpyo.a(_pyo.so.o)

Mathieu Virbel

unread,
May 8, 2012, 11:54:55 AM5/8/12
to kivy-...@googlegroups.com
pa = portaudio. Dunno if portaudio is compatible for iOS.
Maybe you'll need to write another backend using coreaudio for ios...

Even if it's not official, you might be interested by:
https://github.com/kivy/audiostream

CptRedbeard

unread,
May 9, 2012, 4:25:30 AM5/9/12
to Kivy users support
I had tried that previously but only made it up to:
gcc -fno-strict-aliasing -fPIC -fno-common -dynamic -arch i386 -arch
x86_64 -g -O2 -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -I/usr/
local/include/SDL -I/usr/local/include -I/Library/Frameworks/
SDL_mixer.framework/SDL_mixer.framework/Versions/Current/Headers/ -I/
Library/Frameworks/Python.framework/Versions/2.7/include/python2.7 -c
audiostream/core.c -o build/temp.macosx-10.5-intel-2.7/audiostream/
core.o -ggdb -O2
i686-apple-darwin11-llvm-gcc-4.2: audiostream/core.c: No such file or
directory
i686-apple-darwin11-llvm-gcc-4.2: no input files
i686-apple-darwin11-llvm-gcc-4.2: audiostream/core.c: No such file or
directory
i686-apple-darwin11-llvm-gcc-4.2: no input files
lipo: can't figure out the architecture type of: /var/tmp//
cctWsFzc.out

Mathieu Virbel

unread,
May 9, 2012, 7:20:56 AM5/9/12
to kivy-...@googlegroups.com
You need to have cython installed and avaibable with the python version
you're using

G

unread,
Jun 22, 2012, 10:23:26 AM6/22/12
to kivy-...@googlegroups.com
Hi there,

I seem to be a little less lucky then you, having the same error ;)
for days I am getting closer to the end of the chain, but I really feel stuck here.
please help me get this done too..

here's the last piece of my log:

++ try mkdir -p /Users/TSdisplay/kivy-ios/build
++ mkdir -p /Users/TSdisplay/kivy-ios/build
++ try mkdir -p /Users/TSdisplay/kivy-ios/build/include
++ mkdir -p /Users/TSdisplay/kivy-ios/build/include
++ try mkdir -p /Users/TSdisplay/kivy-ios/build/lib
++ mkdir -p /Users/TSdisplay/kivy-ios/build/lib
++ try mkdir -p /Users/TSdisplay/kivy-ios/.cache
++ mkdir -p /Users/TSdisplay/kivy-ios/.cache
++ try mkdir -p /Users/TSdisplay/kivy-ios/tmp
++ mkdir -p /Users/TSdisplay/kivy-ios/tmp
+ pushd /Users/TSdisplay/kivy-ios/tmp
~/kivy-ios/tmp ~/kivy-ios
+ '[' '!' -f SDL ']'
+ ln -s /Users/TSdisplay/kivy-ios/src/SDL SDL
ln: SDL/SDL: File exists
+ '[' '!' -d SDL_mixer ']'
+ '[' '!' -d libtremor ']'
+ '[' '!' -d libogg ']'
+ '[' '!' -f libogg/src/.libs/libogg.a ']'
+ '[' '!' -f libtremor/tremor/.libs/libvorbisidec.a ']'
+ try cd libtremor/tremor
+ cd libtremor/tremor
+ echo
+ CC=' /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/arm-apple-darwin10-llvm-gcc-4.2'
+ AR=/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/ar
+ LDFLAGS='-isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.1.sdk -miphoneos-version-min=5.1'
+ CFLAGS='-march=armv7 -mcpu=arm176jzf -mcpu=cortex-a8 -pipe -no-cpp-precomp -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.1.sdk -miphoneos-version-min=5.1 -O3'
+ OGG_CFLAGS=-I../../libogg/include
+ OGG_LDFLAGS=-L../../libogg/src/.libs
+ PKG_CONFIG_LIBDIR=../../libogg
+ ACLOCAL_FLAGS='-I /usr/local/share/aclocal'
+ ./autogen.sh --disable-shared --host=arm-apple-darwin --enable-static=yes --enable-shared=no
checking for autoconf... 
-n checking for automake... 
yes
-n checking for libtool... 
libtoolize
Generating configuration files for vorbisdec, please wait....
  aclocal -I /usr/local/share/aclocal
  libtoolize --automake
  autoheader
  automake --add-missing 
Useless use of /d modifier in transliteration operator at /usr/local/share/automake-1.11/Automake/Wrap.pm line 58.
configure.in:9: installing `./config.guess'
configure.in:9: installing `./config.sub'
configure.in:14: installing `./install-sh'
configure.in:14: installing `./missing'
Makefile.am: installing `./depcomp'
  autoconf
configure: WARNING: If you wanted to set the --build type, don't use --host.
    If a cross compiler is detected then cross compile mode will be used.
checking build system type... i386-apple-darwin11.4.0
checking host system type... arm-apple-darwin
checking target system type... arm-apple-darwin
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for arm-apple-darwin-strip... no
checking for strip... strip
checking for a thread-safe mkdir -p... ./install-sh -c -d
checking for gawk... no
checking for mawk... no
checking for nawk... no
checking for awk... awk
checking whether make sets $(MAKE)... yes
checking whether to enable maintainer-specific portions of Makefiles... yes
checking for arm-apple-darwin-gcc...  /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/arm-apple-darwin10-llvm-gcc-4.2
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables... 
checking whether we are cross compiling... yes
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether  /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/arm-apple-darwin10-llvm-gcc-4.2 accepts -g... yes
checking for  /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/arm-apple-darwin10-llvm-gcc-4.2 option to accept ISO C89... none needed
checking for style of include used by make... GNU
checking dependency style of  /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/arm-apple-darwin10-llvm-gcc-4.2... gcc3
checking how to run the C preprocessor...  /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/arm-apple-darwin10-llvm-gcc-4.2 -E -traditional-cpp
checking for a sed that does not truncate output... /usr/bin/sed
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for fgrep... /usr/bin/grep -F
checking for ld used by  /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/arm-apple-darwin10-llvm-gcc-4.2... /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/llvm-gcc-4.2/libexec/gcc/arm-apple-darwin10/4.2.1/ld
checking if the linker (/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/llvm-gcc-4.2/libexec/gcc/arm-apple-darwin10/4.2.1/ld) is GNU ld... no
checking for BSD- or MS-compatible name lister (nm)... no
checking for arm-apple-darwin-dumpbin... no
checking for arm-apple-darwin-link... no
checking for dumpbin... no
checking for link... link -dump -symbols
configure: WARNING: using cross tools not prefixed with host triplet
checking the name lister (link -dump -symbols) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 196608
checking whether the shell understands some XSI constructs... yes
checking whether the shell understands "+="... yes
checking for /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/llvm-gcc-4.2/libexec/gcc/arm-apple-darwin10/4.2.1/ld option to reload object files... -r
checking for arm-apple-darwin-objdump... no
checking for objdump... no
checking how to recognize dependent libraries... pass_all
checking for arm-apple-darwin-ar... /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/ar
checking for arm-apple-darwin-strip... strip
checking for arm-apple-darwin-ranlib... no
checking for ranlib... ranlib
checking command to parse link -dump -symbols output from  /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/arm-apple-darwin10-llvm-gcc-4.2 object... failed
checking for arm-apple-darwin-dsymutil... no
checking for dsymutil... dsymutil
checking for arm-apple-darwin-nmedit... no
checking for nmedit... nmedit
checking for arm-apple-darwin-lipo... no
checking for lipo... lipo
checking for arm-apple-darwin-otool... no
checking for otool... otool
checking for arm-apple-darwin-otool64... no
checking for otool64... no
checking for -single_module linker flag... yes
checking for -exported_symbols_list linker flag... yes
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for dlfcn.h... yes
checking for objdir... .libs
checking if  /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/arm-apple-darwin10-llvm-gcc-4.2 supports -fno-rtti -fno-exceptions... no
checking for  /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/arm-apple-darwin10-llvm-gcc-4.2 option to produce PIC... -fno-common -DPIC
checking if  /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/arm-apple-darwin10-llvm-gcc-4.2 PIC flag -fno-common -DPIC works... yes
checking if  /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/arm-apple-darwin10-llvm-gcc-4.2 static flag -static works... no
checking if  /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/arm-apple-darwin10-llvm-gcc-4.2 supports -c -o file.o... yes
checking if  /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/arm-apple-darwin10-llvm-gcc-4.2 supports -c -o file.o... (cached) yes
checking whether the  /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/arm-apple-darwin10-llvm-gcc-4.2 linker (/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/llvm-gcc-4.2/libexec/gcc/arm-apple-darwin10/4.2.1/ld) supports shared libraries... yes
checking dynamic linker characteristics... darwin dyld
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... no
checking whether to build static libraries... yes
checking for ld used by  /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/arm-apple-darwin10-llvm-gcc-4.2... (cached) /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/llvm-gcc-4.2/libexec/gcc/arm-apple-darwin10/4.2.1/ld
checking if the linker (/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/llvm-gcc-4.2/libexec/gcc/arm-apple-darwin10/4.2.1/ld) is GNU ld... (cached) no
checking for memory.h... (cached) yes
./configure: line 10652: PKG_PROG_PKG_CONFIG: command not found
./configure: line 10657: syntax error near unexpected token `OGG,'
./configure: line 10657: `  PKG_CHECK_MODULES(OGG, ogg >= 1.0, HAVE_OGG=yes, HAVE_OGG=no)'
+ try make
+ make
make: *** No targets specified and no makefile found.  Stop.
+ exit -1
+ exit -1
Dev-Mini:kivy-ios TSdisplay$



Op zaterdag 21 april 2012 23:12:46 UTC+2 schreef CptRedbeard het volgende:

Mathieu Virbel

unread,
Jul 7, 2012, 5:10:34 PM7/7/12
to kivy-...@googlegroups.com
Hi guys,

Sorry for the long late, but i finally get a macbook with a "clean" env under my hand, and resolved all the issues from the kivy-ios project.

Best is to restart all the commands from the start. Check the packaging documentation, you should have new instructions, specially for installing dependencies. Then some scripts have been updated. 

http://kivy.org/docs/guide/packaging-ios.html (will be updated by the builder in the next 5 minutes normally)

Tell me if it's working for you!

Mathieu

Mathieu Virbel

unread,
Jul 7, 2012, 6:20:04 PM7/7/12
to kivy-...@googlegroups.com
I got that error when pkg-config wasn't installed from brew
Are you sure it's ok ?

Patorikku

unread,
Jul 16, 2012, 6:20:08 AM7/16/12
to kivy-...@googlegroups.com, kivy...@googlegroups.com

Awesome! Thanks Mathieu and Christopher and team who made this happened!

Now after much trouble of setting up Xcode 4.2 on Snow Leopard and get kivy-ios compiled successfully as a newbie, I am so excited to run my first Kivy app on an old 1st gen iPad... until I got an error at the loading stage after building my code.

Output from the debugger:

GNU gdb 6.3.50-20050815 (Apple version gdb-1708) (Fri Sep 16 06:56:50 UTC 2011)

Copyright 2004 Free Software Foundation, Inc.

GDB is free software, covered by the GNU General Public License, and you are

welcome to change it and/or distribute copies of it under certain conditions.

Type "show copying" to see the conditions.

There is absolutely no warranty for GDB.  Type "show warranty" for details.

This GDB was configured as "--host=i386-apple-darwin --target=arm-apple-darwin".tty /dev/ttys002

target remote-mobile /tmp/.XcodeGDBRemote-56459-53

Switching to remote-macosx protocol

mem 0x1000 0x3fffffff cache

mem 0x40000000 0xffffffff none

mem 0x00000000 0x0fff none

[Switching to process 7171 thread 0x1c03]

[Switching to process 7171 thread 0x1c03]

sharedlibrary apply-load-rules all

2012-07-16 20:06:11.608 mypaint[12234:707] PythonHome is: /var/mobile/Applications/ECB4BFC4-066D-4BF4-8D36-EA91818F7D89/mypaint.app

2012-07-16 20:06:11.619 mypaint[12234:707] Initializing python

2012-07-16 20:06:11.924 mypaint[12234:707] Running main.pyo: (null)

2012-07-16 20:06:11.928 mypaint[12234:707] Unable to open main.pyo, abort.

2012-07-16 20:06:11.942 mypaint[12234:707] Leaving


Still frustrated as I have no cue about what went wrong. I think I might have made a mistake in the Xcode project configure but not sure where to look at.

Also there are warnings from building the app in Xcode but it said successfully built at the end:

32-bit absolute address out of range (0x1001EFC88 max is 4GB): from _usedpools + 0x00000004 (0x001EFC90) to 0x1001EFC88

32-bit absolute address out of range (0x1001EFC88 max is 4GB): from _usedpools + 0x00000000 (0x001EFC90) to 0x1001EFC88


Is it because the 1st gen iPad is not supported?

Also I use the option "Run" in Xcode to let it load the app onto the iPad - is it a right way to do it?

Thanks!

Pat

G

unread,
Jul 16, 2012, 8:43:05 AM7/16/12
to kivy-...@googlegroups.com
Thank you so much for the reply,
This got me another step in the right direction; forward.

Alas, I'm now stuck at building kivy-extensions.
 - I followed the new instructions on kivy.org for a clean build starting-point, and added the missing pkg-config. 
 - I also had to download the kivy package manually, because of a missing kivy/graphics/opengl.c error.
 - now I am missing the file kivy/core/image/img_imageio.c, just as a Russian developer here: http://translate.google.nl/translate?hl=nl&sl=ru&tl=en&u=http%3A%2F%2Fhabrahabr.ru%2Fqa%2F21027%2F
 - I found the file on the SDL site, and tried to build it again (lowercased), other log, still an error.

Am I doing something wrong structurally? I can't understands how it can run instantly elsewhere, while it leaves me stuck, hoping for the next step..
Here's my latest log http://codepaste.net/ihe2a9

Thanks in advance!

G

Op zondag 8 juli 2012 00:20:04 UTC+2 schreef Mathieu Virbel het volgende:

aldous99

unread,
Jul 16, 2012, 5:13:08 PM7/16/12
to kivy-...@googlegroups.com
Hi all.  I tried to follow the ios build steps here---


---but ran into error when building the build_all.sh.

One thing that did not work for me was installing cython using homebrew.  (No available formula for cython)  So instead I installed python, then pip, then used pip to install cython.  This is the last thing I see in the output when running the build script.

+ try make
+ make
make  all-am
/bin/sh ./libtool --tag=CC   --mode=compile /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/arm-apple-darwin10-llvm-gcc-4.2 -DHAVE_CONFIG_H -I. -I./ -I../../libogg/include    -O2 -D_ARM_ASSEM_ -fsigned-char -march=armv7 -mcpu=arm176jzf -mcpu=cortex-a8 -pipe -no-cpp-precomp -isysroot /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.0.sdk -miphoneos-version-min=5.0 -O3 -D_REENTRANT -DUSE_MEMORY_H -MT mdct.lo -MD -MP -MF .deps/mdct.Tpo -c -o mdct.lo mdct.c
mv -f .deps/mdct.Tpo .deps/mdct.Plo
mv: rename .deps/mdct.Tpo to .deps/mdct.Plo: No such file or directory
make[1]: *** [mdct.lo] Error 1
make: *** [all] Error 2
+ exit -1
+ exit -1

D


Mathieu Virbel

unread,
Jul 18, 2012, 5:00:23 AM7/18/12
to kivy-...@googlegroups.com
Did you retry to build from a clean clone of the project ?
Just to be sure that the error you got is not due to a half/build tree.

Mathieu
> - I followed the new instructions on kivy.org <http://kivy.org> for
> a clean build starting-point, and added the missing pkg-config.
> - I also had to download the kivy package manually, because of a
> missing kivy/graphics/opengl.c error.
> - now I am missing the file kivy/core/image/img_imageio.c, just as a
> Russian developer here:
> http://translate.google.nl/translate?hl=nl&sl=ru&tl=en&u=http%3A%2F%2Fhabrahabr.ru%2Fqa%2F21027%2F
> <http://translate.google.nl/translate?hl=nl&sl=ru&tl=en&u=http%3A%2F%2Fhabrahabr.ru%2Fqa%2F21027%2F>
> - I found the file on the SDL site, and tried to build it again
> (lowercased), other log, still an error.
>
> Am I doing something wrong structurally? I can't understands how it
> can run instantly elsewhere, while it leaves me stuck, hoping for
> the next step..
> Here's my latest log http://codepaste.net/ihe2a9
> <http://codepaste.net/ihe2a9>
>
> Thanks in advance!
>
> G
>
> Op zondag 8 juli 2012 00:20:04 UTC+2 schreef Mathieu Virbel het
> volgende:
>
> I got that error when pkg-config wasn't installed from brew
> Are you sure it's ok ?
>
>
> Le 22 juin 2012 � 16:23, G a �crit :
>
> --
>
>
>

Patorikku

unread,
Jul 18, 2012, 6:34:02 AM7/18/12
to kivy-...@googlegroups.com, kivy...@googlegroups.com
Ok got to the bottom of this finally, it was my fault when using tools/create_xocde_project.sh, I supplied the .py file rather than the directory contains it, so no .pyo can be compiled :/

And then... I still can't execute the app :(
Output from GDB:

GNU gdb 6.3.50-20050815 (Apple version gdb-1708) (Fri Sep 16 06:56:50 UTC 2011)

Copyright 2004 Free Software Foundation, Inc.

GDB is free software, covered by the GNU General Public License, and you are

welcome to change it and/or distribute copies of it under certain conditions.

Type "show copying" to see the conditions.

There is absolutely no warranty for GDB.  Type "show warranty" for details.

This GDB was configured as "--host=i386-apple-darwin --target=arm-apple-darwin".tty /dev/ttys002

target remote-mobile /tmp/.XcodeGDBRemote-685-33

Switching to remote-macosx protocol

mem 0x1000 0x3fffffff cache

mem 0x40000000 0xffffffff none

mem 0x00000000 0x0fff none

[Switching to process 7171 thread 0x1c03]

[Switching to process 7171 thread 0x1c03]

sharedlibrary apply-load-rules all

2012-07-18 19:15:41.983 paint[347:707] PythonHome is: /var/mobile/Applications/C819DB72-16E4-4E2D-94C0-A72378B3C728/paint.app

2012-07-18 19:15:41.990 paint[347:707] Initializing python

2012-07-18 19:15:42.335 paint[347:707] Running main.pyo: /var/mobile/Applications/C819DB72-16E4-4E2D-94C0-A72378B3C728/paint.app/YourApp/main.pyo

RuntimeError: Bad magic number in .pyc file

2012-07-18 19:15:42.339 paint[347:707] Application quit abnormally!

2012-07-18 19:15:42.353 paint[347:707] Leaving

The bad magic number seems to be related to the Python version, as I can see the kivy-ios is currently using Python 2.7.1 to build everything.
So I delete and checkout the kivy-ios again,
and with Python 2.7.1 installed (via .pkg from python.org) on my Mac OS X 10.6.8 just to be sure,

Also with:
Cython 0.15 (as 0.16 breaks the -t option)

Via brew install:
SDL 1.2.15 (libSDL_ttf can't be built without it)
autoconf 2.69
automake 1.12.2
libtool 2.4.2
mercurial 2.2.2
pkg-config 0.25

But still having the bad magic number issue. My app is simply the paint.py from the example section, and I didn't enforce any Python or Kivy version in the code.
I tried with a very simple hello world script and had the same result.

Any suggestions that I have missed something? Thanks...

Mathieu Virbel

unread,
Jul 18, 2012, 6:52:18 AM7/18/12
to kivy-...@googlegroups.com
What "python -V" output in your shell?
Same question for "which python"
> *RuntimeError: Bad magic number in .pyc file*
>
> 2012-07-18 19:15:42.339 paint[347:707] Application quit abnormally!
>
> 2012-07-18 19:15:42.353 paint[347:707] Leaving
>
> The bad magic number seems to be related to the Python version, as I can
> see the kivy-ios is currently using Python 2.7.1 to build everything.
> So I delete and checkout the kivy-ios again,
> and with Python 2.7.1 installed (via .pkg from python.org
> <http://python.org/>) on my Mac OS X 10.6.8 just to be sure,
> *2012-07-16 20:06:11.608 mypaint[12234:707] PythonHome is:
> /var/mobile/Applications/ECB4BFC4-066D-4BF4-8D36-EA91818F7D89/mypaint.app*
>
> *2012-07-16 20:06:11.619 mypaint[12234:707] Initializing python*
>
> *2012-07-16 20:06:11.924 mypaint[12234:707] Running main.pyo: (null)*
>
> *2012-07-16 20:06:11.928 mypaint[12234:707] Unable to open main.pyo,
> abort.*
>
> *2012-07-16 20:06:11.942 mypaint[12234:707] Leaving*
>
>
> Still frustrated as I have no cue about what went wrong. I think I
> might have made a mistake in the Xcode project configure but not
> sure where to look at.
>
> Also there are warnings from building the app in Xcode but it said
> successfully built at the end:
>
> 32-bit absolute address out of range (0x1001EFC88 max is 4GB): from
> _usedpools + 0x00000004 (0x001EFC90) to 0x1001EFC88
>
> 32-bit absolute address out of range (0x1001EFC88 max is 4GB): from
> _usedpools + 0x00000000 (0x001EFC90) to 0x1001EFC88
>
>
> Is it because the 1st gen iPad is not supported?
>
> Also I use the option "Run" in Xcode to let it load the app onto the
> iPad - is it a right way to do it?
>
> Thanks!
>
> Pat
>
> --
>
>
>


Patorikku

unread,
Jul 18, 2012, 6:58:56 AM7/18/12
to kivy-...@googlegroups.com
Patricks-MacBook:kivy-ios Patrick$ python -V
Python 2.7.1
Patricks-MacBook:kivy-ios Patrick$ which python
/Library/Frameworks/Python.framework/Versions/2.7/bin/python

I am confused... @.@

Mathieu Virbel

unread,
Jul 18, 2012, 7:24:49 AM7/18/12
to kivy-...@googlegroups.com
Look like somebody already reported the issue:

https://github.com/kivy/kivy-ios/issues/2

Will try to take a look about it this afternoon.

On 18/07/2012 12:58, Patorikku wrote:
> Patricks-MacBook:kivy-ios Patrick$ python -V
> *Python 2.7.1*
> Patricks-MacBook:kivy-ios Patrick$ which python
> */Library/Frameworks/Python.framework/Versions/2.7/bin/python*
> --
>
>
>


Patorikku

unread,
Jul 18, 2012, 8:04:08 AM7/18/12
to kivy-...@googlegroups.com
Thanks Mathieu!

aldous99

unread,
Jul 18, 2012, 12:22:55 PM7/18/12
to kivy-...@googlegroups.com
I just got a new Macbook Air so thought this would be a good chance to follow the installation recipe from scratch.  There are the steps I've executed...

  1. Install homebrew
  2. Run "brew doctor" 
    1. Requires XCode
  3. Download XCode from app store
  4. Run XCode; go to "Preferences..." and "downloads" tab
  5. Install "Command Line Tools" ad one or more optional packages (IOS simulator is a good idea)
  6. Reboot Mac (for superstitious reasons)
  7. Run "brew doctor" and system is raring to brew
  8. Run "brew install cython autoconf automake libtool pkg-config mercurial"
At this point I get this error: No available formula for cython

This is the same error I ran into on my old, dirty machine.  

Devin

Thomas Hansen

unread,
Jul 18, 2012, 1:16:30 PM7/18/12
to kivy-...@googlegroups.com
Once you have a c compiler installed, you can just pip install cython. 

Sent from my iPhone
--
 
 
 

aldous99

unread,
Jul 18, 2012, 2:03:40 PM7/18/12
to kivy-...@googlegroups.com
I've been down that road on my old machine, could not get kivy-ios to build after installing cython through pip.  I was hoping a clean start would produce excellent results.  I'll keep at it...

Patorikku

unread,
Jul 19, 2012, 12:00:50 AM7/19/12
to kivy-...@googlegroups.com
What's the error message?

I faced the same issue before so I remove the cython via pip uninstall, download the Cython 0.15 source (not the latest 0.16) and install it via "python setup.py install".

Did you instal Python 2.7.1 by yourself or using the stock one from Mac?

G

unread,
Jul 19, 2012, 8:47:31 AM7/19/12
to kivy-...@googlegroups.com
Starting form a clean osX worked for me!

I mean, after installing cython-0.15 and homebrew manually and them using: brew install autoconf automake libtool pkg-config mercurial.
It seams that the combination of macports installing stuff, together with brew was not favorable...

@patorikku: I used the stock python for mac to install cython.

now I run into a "rm: /Users/dev/kivy-ios/app-test/YourApp: No such file or directory" error while Building.
Let's see how to get that fixed..

Good luck to you all!


Op donderdag 19 juli 2012 06:00:50 UTC+2 schreef Patorikku het volgende:

Patorikku

unread,
Jul 19, 2012, 9:00:14 AM7/19/12
to kivy-...@googlegroups.com
The populate-project.sh script is doing that: it copies all files from the source directory to the app-test/YourApp in order to build.

But for the first time the directory doesn't exist so it failed. In my Xcode it is not fatal so it allows me to build successfully.

Alternatively you can create app-test/YourApp to remove the error.

Logan Rosen

unread,
Dec 5, 2012, 3:20:18 PM12/5/12
to kivy-...@googlegroups.com
Are there any updates on getting Kivy apps to run in the iOS Simulator? I'd love to test out mine in the simulator, but I unfortunately do not have a provisioning profile for my phone.

On Friday, March 16, 2012 5:26:51 AM UTC-4, Mathieu Virbel wrote:
Hi,

Building for the simulator is currently not supported within the toolchain. This might be changing in the future. Right now, you need a device connected to make it works :)

Mathieu

Le jeudi 15 mars 2012 03:18:10 UTC+1, eugene a écrit :
Hi,

I encountered some problems at the beginning to build on my Xcode 4.2.1. I must mention that I am not quite familiar with the Xcode environment. The target destination in the Xcode project always shows iOS device. I find no way to add new destination like iPhone or iPad simulators. When I run the build, the message always shows that I need to have the provision license to run the device or something. Therefore, I decided to apply for a iOS developer license to deployed to my iPhone3gs. After I got the license activation code, I follow the activation process and generate the keys and the device provision profile for my 3gs and also add to the organizer in Xcode. The only thing I changed is changing the target device from iPad to iPhone. When I connect my 3gs into my air, it automatically shows up in the destination and then I could run the build and deploy to my device. 
I don't know how to add simulator into the destination when the project is created through the script provided. Anybody knows how could help on this? For the gstreamer part I mentioned, I don't know much about the kivy build process. Could you just let videoplayer.py sample run on iOS and share with us. That would be very helpful.

Eugene



On Wed, Mar 14, 2012 at 6:37 PM, Mathieu Virbel <m...@kivy.org> wrote:
Did it run out of the box without any changes?
Because at least, the xcode project by default stick for ipad.

Can you share the process?

Dunno about gstreamer on ios, i see ios is wrote in the changelog, but never tested it. If it's just for reading video/audio, i'm going to commit a build-ffmpeg as well, then Kivy will have limited Video support.

Le 14 mars 2012 à 11:29, YEU-JIUN WANG a écrit :

Hi,

This is really amazing. I have successfully run the kivy app on my iPhone 3gs. Is there a plan to have gstreamer support on iOS?


Eugene

xavier Nieves

unread,
Apr 15, 2014, 7:09:25 PM4/15/14
to kivy-...@googlegroups.com, kivy...@googlegroups.com
Hey guys DO any of you know how to access  pictures with kivy in iOS ?

Noob Saibot

unread,
Apr 15, 2014, 7:17:32 PM4/15/14
to kivy-...@googlegroups.com, kivy...@googlegroups.com
If you mean the photo album, then this is not supported. You can try tweaking pyobjus to get it.

xavier Nieves

unread,
Apr 16, 2014, 1:54:33 PM4/16/14
to kivy-...@googlegroups.com, kivy...@googlegroups.com
Ok Thank you 

Frank Mata

unread,
Sep 28, 2014, 6:57:50 PM9/28/14
to kivy-...@googlegroups.com, logat...@gmail.com
I was able to get the simluator working to test iAd integration in kivy. I have some sample projects and scripts here: https://github.com/matafc/hachimaru-blog . Basically I just merged in the iphonesimluator branch from kivy-ios, and it works well. I pinged the kivy-ios developers to accept hansent's pull request, so hopefully it will be included in the master branch soon.

Bruce Cropley

unread,
Sep 29, 2014, 2:39:07 AM9/29/14
to kivy-...@googlegroups.com, logat...@gmail.com
Great, thanks :)
Reply all
Reply to author
Forward
0 new messages