MatthewBooth / OTAUpdates

Over-The-Air Updates for Android ROMs from ICS to Lollipop
http://ultimarom.com/
73 stars 109 forks source link

Error when compiling from source #72

Closed timschumi closed 8 years ago

timschumi commented 8 years ago

When I try to compile my ROM with your App's source included, I get the following error:

make: *** No rule to make target »/media/timschumi/Toshiba_2TB_1/development/cyanogenmod/cm-11.0/out/target/product/cs02/obj/SHARED_LIBRARIES/libc++_intermediates/export_includes«, 
  needed by »/media/timschumi/Toshiba_2TB_1/development/cyanogenmod/cm-11.0/out/target/product/cs02/obj/SHARED_LIBRARIES/libbypass_intermediates/import_includes«.

Is there something I'm missing?

timschumi commented 8 years ago

Note: I'm using CM 11 sources

timschumi commented 8 years ago

I fixed the problem by creating the libc++_intermediates directory and the export_include file manually, but is there any other way to fix this automatically?

timschumi commented 8 years ago

Now I get this error additionally:

make: *** No rule to make target »/media/timschumi/Toshiba_2TB_1/development/cyanogenmod/cm-11.0/out/target/product/cs02/obj/lib/libc++.so«, 
  needed by »/media/timschumi/Toshiba_2TB_1/development/cyanogenmod/cm-11.0/out/target/product/cs02/obj/SHARED_LIBRARIES/libbypass_intermediates/LINKED/libbypass.so«.
MatthewBooth commented 8 years ago

I'm not entirely sure. It seems to be having an issue compiling the bypass library. You may need some additional libraries to compile parts of the boost library included in the app.

timschumi commented 8 years ago

How do I find those additional libraries?

timschumi commented 8 years ago

I found that libc++.so is alredy built by cm, so the Android.mk of your app is called to early, before libc++.so is being built. If I build it manually after doing a full build without the App source included, I get this error:

target thumb C++: libbypass <= packages/apps/OTAUpdates/jni/android/bypass.cpp
In file included from packages/apps/OTAUpdates/jni/android/bypass.cpp:1:0:
packages/apps/OTAUpdates/jni/src/parser.h:20:20: fatal error: iostream: No such file or directory
compilation terminated.
make: *** [/media/timschumi/Toshiba_2TB_1/development/cyanogenmod/cm-11.0/out/target/product/cs02/obj/SHARED_LIBRARIES/libbypass_intermediates/android/bypass.o] Error 1

Seems to be an issue with the compiler. Do you use gcc or g++?

MatthewBooth commented 8 years ago

You may want to look at how the JDC group are compiling theirs as I know they're not having any issue bundling this in AOSP and CM builds, or AOSP-JF.

Failing that you could bundle the apk. I'm still in the process of rewriting the app and I'll be rewriting the AOSP branch in the process.

timschumi commented 8 years ago

What JDC Group? Can you send me a link or something? If I can't fix it, I'll wait for the rewrite of the App. Should I keep this issue open, for the case if it still doesn't work after the rewrite?

MatthewBooth commented 8 years ago

This is the JDC Team: https://github.com/JDCTeam

And yeah if you can't get it compiling you may want to hold on, or just use the precompiled app.

timschumi commented 8 years ago

Precompiled download link doesn't work, as it results in a 404 Error Code

timschumi commented 8 years ago

I'm currently trying to Compile the app from source in eclipse. Maybe you should mention that the ADT Plugin has to be installed manually, since Android Studio is the official program for making Android apps

timschumi commented 8 years ago

I made a fork of this App where I fixed building with Android Studio: https://github.com/TimSchumi/OTAUpdates libbypass is somehow not compiled correctly. But I just found your App on Google Play, so I maybe just will use the APK from there

Thanks for all your help! I can't wait for the new Version of the App