<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <div class="moz-cite-prefix">Hi Ray,<br>
      <br>
      I thought that I would have a go building the tools with your
      script so that I begin to understand the changes but I ran into a
      couple of problems:<br>
      <br>
      1/  python build fails because /usr/bin/x86_64-linux-gnu-ar does
      not exist on my system - not an issue for me because I already
      have python on my system so I removed the python build and got
      further.<br>
      <br>
      2/  now I am stuck "Building armeabi,armeabi-v7a gabi++
      binaries..." and get an error <br>
      /tmp/necessitas/android-qt-ndk/ndk/build/tools/build-gabi++.sh:
      93: local: -mthumb: bad variable name<br>
      ERROR: Could not build gabi++!<br>
      <br>
      In parallel I am building with your released ndk and making some
      progress.. but it would be nice to know why I cant build the tools
      myself.<br>
      <br>
      Peter.<br>
      <br>
      On 29/08/12 18:53, Peter Saunderson wrote:<br>
    </div>
    <blockquote cite="mid:503E5704.2020602@gmail.com" type="cite">
      <meta content="text/html; charset=ISO-8859-1"
        http-equiv="Content-Type">
      <div class="moz-cite-prefix">Thanks for that, it will save me
        time.  By the way I noticed when I pulled the QtCreator from git
        the .gitignore seems to have ignore of lib/* and in
        lib/qtcomponents there seem to be a few files that are not
        created in the build process..  Perhaps the .gitignore is not
        correct for<a moz-do-not-send="true" rel="nofollow"
          class="external free"
          href="git://anongit.kde.org/android-qt-creator.git">
          git://anongit.kde.org/android-qt-creator.git</a> ?<br>
        <br>
        Peter<br>
        <br>
        <br>
        <br>
          On 29/08/12 18:00, Ray Donnelly wrote:<br>
      </div>
      <blockquote
cite="mid:CAOYw7ds_ZwmcdeKMo5zPyiECgoy2oCfPNDR0AEJCZGeNEi5ZyA@mail.gmail.com"
        type="cite">
        <pre wrap="">Oh we also use Gold 2.22.52 by default which is very up to date and much faster.

On Wed, Aug 29, 2012 at 5:57 PM, Ray Donnelly <a moz-do-not-send="true" class="moz-txt-link-rfc2396E" href="mailto:mingw.android@gmail.com"><mingw.android@gmail.com></a> wrote:
</pre>
        <blockquote type="cite">
          <pre wrap="">As I said, using Google's NDK will not work for building android qt (
relocations error and libgnustl_static error -
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://code.google.com/p/android/issues/detail?id=36472">http://code.google.com/p/android/issues/detail?id=36472</a> ).

Rather than building your own NDK from Google's code (and thus ending
up with the same bugs) you should either use mine (it's the one we
supply and use with Necessitas):

<a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://mingw-and-ndk.googlecode.com/files/android-ndk-r8b-ma-windows.7z">http://mingw-and-ndk.googlecode.com/files/android-ndk-r8b-ma-windows.7z</a>
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://mingw-and-ndk.googlecode.com/files/android-ndk-r8b-ma-linux-x86.7z">http://mingw-and-ndk.googlecode.com/files/android-ndk-r8b-ma-linux-x86.7z</a>
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://mingw-and-ndk.googlecode.com/files/android-ndk-r8b-ma-darwin-x86.7z">http://mingw-and-ndk.googlecode.com/files/android-ndk-r8b-ma-darwin-x86.7z</a>

...or else build mine using the script we use:

<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:git@git.kde.org:necessitas-tools.git">git@git.kde.org:necessitas-tools.git</a> (master branch)

look at build_ndk.sh in that repo.

for building android qt, look at build_sdk.sh which calls
android/androidconfigbuild.sh

On Wed, Aug 29, 2012 at 5:44 PM, Peter Saunderson <a moz-do-not-send="true" class="moz-txt-link-rfc2396E" href="mailto:peteasa@gmail.com"><peteasa@gmail.com></a> wrote:
</pre>
          <blockquote type="cite">
            <pre wrap="">Hi Ray,

Thanks for the warnings!

I am using Googles android-ndk-r8b NDK, with the latest compilers (v4.6)
because I wanted to use the same NDK I used for OpenCV that I also am using
on the same project - in theory it should keep things simple.  Thanks for
the answers also about using "android:" to selective configure stuff.  I
will look out for the failures that you mention.. I might end up building
the Google compiler and linker at this rate..

Peter.


On 29/08/12 17:33, Ray Donnelly wrote:
</pre>
            <blockquote type="cite">
              <pre wrap="">Hi Peter,

Which NDK are you using? Ours or Google's? Google's won't work for 2
reasons, their libgnustl_static.a has it's symbols invisible and also
their linker has a bug in it to do with a specific relocation type.

Also are you using the unstable branch of the Qt sources?

Only libQtCore4.so gets linked to libgnustl_static.a:

from qt-src\src\corelib\corelib.pro

android: {
     #add whole gnu_stl library to QtCore
     LIBS_PRIVATE += -Wl,--whole-archive
$$ANDROID_SOURCES_CXX_STL_LIBDIR/libgnustl_static.a
-Wl,--no-whole-archive
}

On android libstdc++ is just a few small support functions for C++.

On Wed, Aug 29, 2012 at 4:14 PM, Peter Saunderson <a moz-do-not-send="true" class="moz-txt-link-rfc2396E" href="mailto:peteasa@gmail.com"><peteasa@gmail.com></a>
wrote:
</pre>
              <blockquote type="cite">
                <pre wrap="">Hi,

I am building from source and plan to run on an android 4.1.1.  I am
using
Ubuntu 64bit machine for the build and am using android-ndk-r8b.

I find errors such as
obj/release/JSBase.o:(.ARM.extab.text.JSReportExtraMemoryCost+0x0):
undefined reference to `__gxx_personality_v0'

that are fixed by adding to the .pro file
QMAKE_LIBS += -lgnustl_shared

because in android the shared library file is named "libgnustl_shared.so"
instead of "libstdc++.so" as on other platforms (see
CPLUSPLUS-SUPPORT.html).

I tried to make this change in mkspecs/android-g++/qmake.conf but had
other
errors.  Is there a construct that I can use in the .pro files such as
neon:*-g++* { ... }
that will make this change for just android builds of Qt? Is there a
better
way to fix this linker problem in necessitas?

Thanks

Peter.
_______________________________________________
Necessitas-devel mailing list
<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:Necessitas-devel@kde.org">Necessitas-devel@kde.org</a>
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="https://mail.kde.org/mailman/listinfo/necessitas-devel">https://mail.kde.org/mailman/listinfo/necessitas-devel</a>
</pre>
              </blockquote>
            </blockquote>
            <pre wrap="">
</pre>
          </blockquote>
        </blockquote>
      </blockquote>
      <br>
    </blockquote>
    <br>
  </body>
</html>