Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Configure Error: Snipped NDROID_NDK variable #84

Closed
arky opened this issue Dec 12, 2011 · 13 comments
Closed

Configure Error: Snipped NDROID_NDK variable #84

arky opened this issue Dec 12, 2011 · 13 comments

Comments

@arky
Copy link
Contributor

arky commented Dec 12, 2011

$make fails with following error.
Error:
Adding client.mk options from /home/arky/src/B2G/gecko/mozconfig:
MOZ_OBJDIR=$(TOPSRCDIR)/objdir-prof-android
MOZ_MAKE_FLAGS=-s -j16
cd /home/arky/src/B2G/gecko/objdir-prof-android
/home/arky/src/B2G/gecko/configure
Adding configure options from /home/arky/src/B2G/gecko/mozconfig:
--with-android-sdk=NDROID_SDK/platforms/android-13
--with-android-ndk=NDROID_NDK
--with-android-toolchain=NDROID_NDK/toolchains/arm-linux-androideabi-4.4.3/prebuilt/linux-x86
--with-android-platform=NDROID_NDK/platforms/android-5/arch-arm
--target=arm-linux-androideabi
--with-endian=little
--enable-raw
--enable-application=b2g
--disable-elf-hack
--enable-debug-symbols
--enable-profiling
--with-ccache
loading cache ./config.cache
checking host system type... i686-pc-linux-gnu
checking target system type... arm-linux-android
checking build system type... i686-pc-linux-gnu
checking for mawk... mawk
checking for perl5... no
checking for perl... /usr/bin/perl
configure: error: The path in --with-android-sdk isn't valid (source.properties hasn't been found).
*** Fix above errors and then restart with "make -f client.mk build"
make[3]: *** [configure] Error 1
make[2]: *** [/home/arky/src/B2G/gecko/objdir-prof-android/Makefile] Error 2
make[1]: *** [build] Error 2
make: *** [gecko] Error 2

mozconfig

$ cat gecko/mozconfig
mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/objdir-prof-android

XXX our build system doesn't seem to respect toplevel -j ...

hard-coding this sucks

mk_add_options MOZ_MAKE_FLAGS="-s $MAKE_FLAGS"

XXX need a plan for toolchain and multi-dev-platform support

topdir="pwd/../.."
gonk="$topdir/glue/gonk"
sys=uname -s | tr "[[:upper:]]" "[[:lower:]]"

XXX need to figure out how to deal with SDKs ... this sucks.

ac_add_options --with-android-sdk="$ANDROID_SDK/platforms/$ANDROID_SDK_PLATFORM"
ac_add_options --with-android-ndk="$ANDROID_NDK"
ac_add_options --with-android-toolchain="$ANDROID_NDK/toolchains/arm-linux-androideabi-4.4.3/prebuilt/linux-x86"
ac_add_options --with-android-platform="$ANDROID_NDK/platforms/android-5/arch-arm"
ac_add_options --target=arm-linux-androideabi
ac_add_options --with-endian=little
ac_add_options --enable-raw

ac_add_options --enable-application=b2g
ac_add_options --disable-elf-hack

ac_add_options --enable-debug-symbols
ac_add_options --enable-profiling
ac_add_options --with-ccache
arky@Arky-Think:/src/B2G$ echo $ANDROID_NDK
/opt/android-ndk-r7/
arky@Arky-Think:
/src/B2G$ echo $ANDROID_SDK
/opt/android-sdk-linux/

@arky
Copy link
Contributor Author

arky commented Dec 12, 2011

$ cat local.mk
ANDROID_SDK="$ANDROID_SDK"
ANDROID_NDK="$ANDROID_NDK"
WIDGET_BACKEND=gonk

@arky
Copy link
Contributor Author

arky commented Dec 12, 2011

Workaround

$ cat local.mk
ANDROID_SDK="/opt/android-sdk-linux"
ANDROID_NDK="/opt/android-ndk-r7"
WIDGET_BACKEND=gonk

@jlebar
Copy link
Contributor

jlebar commented Dec 12, 2011

Try

 ANDROID_SDK="${ANDROID_SDK}"

? I bet something like that is your problem.

@michaelwu
Copy link
Collaborator

Which backend are you building? If you're building gonk as WIDGET_BACKEND=gonk suggests, ANDROID_?DK variables shouldn't matter at all and shouldn't even be listed. Are you using the right mozconfig?

@benfrancis
Copy link
Collaborator

Oh, do you not need ANDROID_SDK and ANDROID_NDK set to build gonk? That might be my fault as I added them in the INSTALL file because I thought it failed for me when they weren't set.

Can someone confirm that the Gonk back end will build without those variables being set? (it makes sense that this should work)

@michaelwu
Copy link
Collaborator

Gonk never used them in the first place.

@arky
Copy link
Contributor Author

arky commented Dec 14, 2011

I was just following the INSTALL file, building the qemu for starter. In that case the INSTALL file needs to be update with the proper information.

@jlebar
Copy link
Contributor

jlebar commented Dec 14, 2011

Does qemu even work right now?

@arky
Copy link
Contributor Author

arky commented Dec 14, 2011

@jlebar

Using ANDROID_SDK="${ANDROID_SDK}" fails for recursive reference error.
local.mk:1: *** Recursive variable `ANDROID_SDK' references itself (eventually). Stop.

Currently qemu build fails with XML error.

AndroidManifest.xml:54: error: Error parsing XML: mismatched tag
make[7]: *** [R.java] Error 1
make[6]: *** [libs] Error 2
make[5]: *** [libs_tier_platform] Error 2
make[4]: *** [tier_platform] Error 2
make[3]: *** [default] Error 2
make[2]: *** [realbuild] Error 2
make[1]: *** [build] Error 2
make: *** [gecko] Error 2

@jlebar
Copy link
Contributor

jlebar commented Dec 14, 2011

Can you please just put an absolute path in there?

@arky
Copy link
Contributor Author

arky commented Dec 14, 2011

Absolute path works, see my comment above. Looks like we need to update the docs and the make files.

@jlebar
Copy link
Contributor

jlebar commented Dec 14, 2011

Pull requests are welcome.

@arky
Copy link
Contributor Author

arky commented Dec 14, 2011

Of course, waiting for finishing my first successful B2G build !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants