Hello All,
I am new with programming for Android and could use some help compiling someone else's code I have as I am attempting to test a older App for educational use and debugging experience. I have not yet been able to get the code to run, and I have done some searches and tried a few approaches already without luck so I am just hoping someone may point me in to the right direction of what I am missing.
I believe most of my issues may lie in versioning of old dependencies so I have been trying to compile with older version of Android Studio (as well as current version initially) along with matching versions of Gradle and React-Native, all without luck. Here are the version details I can see from the code...
From looking at the code I know it is using:
React-Native 0.53.3
Yarn Package Manager
Gradle 2.2.3
From Top level build.gradle:
dependencies {
classpath 'com.android.tools.build:gradle:2.2.3'
....
repositories {
mavenLocal()
jcenter()
maven {
// All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
url "$rootDir/../node_modules/react-native/android"
From sub level build.gradle:
android {
compileSdkVersion 23
buildToolsVersion "23.0.1"
From gradle-wrapper.properties:
distributionUrl=https\://services.gradle.org/distributions/gradle-2.14.1-all.zip
At this point I have multiple copies of the code that I have tried different gradle versions and react-native versions along with current and older Android studio with a plethora of different compile issues with each setup that I have not been able to solve so I think it may be best for me to start again with a clean version of the code as a new AS project, and I hope some of you more experienced guys might be able to point me in the right direction for setting this up to get it to compile.
Should I try again to match the original AS version, Gradle Version, and React Native version the code was written for? Is their anything I am missing or just try to compile from there and debug errors that arise?
I just did a Quick test on Studio 2.3.3 - I select import gradle and select the build.gradle from the source code.
Error79, 0) Could not read script 'C:\...\node_modules\react-native\react.gradle' as it does not exist."
I then run npm install in project root directory
Sync Gradle Build and run I get:
"Unable to load script from assets 'index.android.bundle' Make sure your bundle is package correctly or your running a packager server"
Build errors on Studio 3.3.1:
> "ERROR: Could not get unknown property 'mergeResourcesProvider' for
> object of type
> com.android.build.gradle.internal.api.ApplicationVariantImpl."
Any help and suggestions are truly appreciated!
Related
I am getting an "Unfortunately Has Stopped" message in my release version that does not occur in the debug version. This happens both on my S4 mini and on the Samsung RTL devices. The debug version works on all of these devices plus on the Genymotion emulators. The error occurs using Jsoup when i tap my menu choice which activates Jsoup.connect.
So far i have determined that the problem is most likely caused by ProGuard, in the minify process. The release program does run if i set minifyEnabled to false but i would prefer to un-apply it just where necessary. So i need to know a few things ...
1. what is the syntax for the proguard statement to eliminate org.jsoup.* from being minified
2. which file is this statement to be added to, proguard-android.txt or proguard-rules.pro
3. how do i initiate a stack trace? It must be simple but my searches have not turned up a step by step procedure for this. I believe that with a stack trace i could identify which specific Jsoup modules need to be eliminated from minify rather than minifying the complete lib
It seems that these are very basic questions. Virtually every post that i have read on these subjects assumes that you know these things. Hope you can help.
Mick
OK, making a little progress.
Found this example -keep class org.joda.time. { ; }** so I substituted jsoup in place of joda, put it into the proguard-rules.pro file and my release build now runs
I found the -s or --stacktrace option and where to set it in the IDE. However I am lost about where to find the actual stacktrace when I run the program. I would appreciate any help i can get on how to get a stack trace, especially while running a release version of the program
About the project
This is a Asp.Net Core Web Api endpoint providing a replica of the Huawei API to get the recovery / update service to actually work.
It works using a local DNS server to redirect the phones traffic to the local API offering the desired firmware infos.
I only tested it against the PRA-LX1 right now but it should be the same for every Huawei phone.
A basic guide and the code are available at the GitHub repository.
Looking for a Linux human helping me adding a startup service executing a script with some commands!
Also need a macOS user to help me write a Installation guide for that system. A Hackintosh just isnt the same.
GitHub repository:
https://github.com/Iocere/HuaweiWebApi
Windows installation guide
Things I'm working on
Spoofing the other endpoints
True independence of the official recovery servers
Adding a GUI if when .NET Core finally get XAML support or make use of Electron or a local website but I cant be arsed :/
Ease of use
Changelog
07.12.2017 | Resivion 6
- Added a preconfigured VirtualBox Image containing Ubuntu Server with recovery server. You can find it on the GitHub.
- Added a proper Wiki and a better(?) guide to get it running on windows with use of the VirtualBox image.
06.12.2017 | Resivion 5
- Removed static IP address from the DNS server and moved it to the configuration file. Sorry!
- Updated the guide to fit to the changes.
Feel free to contribute.
Just got phone today and I'm PRA-LX1C432B115 firmware no updates when search out the box , but firmware finder says higher build B191 yet when check compatibility says not for device,
What does this do force updates or summit? Thanks
Sent from my PRA-LX1 using Tapatalk
With this you can force the update yes. The default version in this application is B110. After you restored to that one you can update normally to B182.
Or you try a different one like B191 but i cant guarantee that it's working. Our device in the files from huawei is also listed as L11 or something.
Edit: Found a bug. Updated the repo.
Hi there.
I have successfully built my application under gradle against android auto aosp. Now I want to integrate it via soong blueprint.
During integration, i faced with a few code reorganizations issues:
1) For instrumentation tests I had instrumentation integrated in my package however AOSP seems to suggest to separate it from my package with own bp and manifest that is basically mentioned here:
Self-Instrumenting Tests Example | Android Open Source Project
source.android.com
am I correct to do so or I could somehow remain my package structure?
2) I faced with rather small issue:
Code:
Attribute [email protected] value=(false) from AndroidManifest.xml:12:18-51
is also present at AndroidManifest.xml:19:47-79 value=(true).
Suggestion: add 'tools:replace="android:extractNativeLibs"' to <application> element at AndroidManifest.xml:12:5-24:19 to override.
?
But once I tried to fix it via suggested tools:replace and added
Code:
xmlns:tools="http://schemas.android.com/tools"
and
tools:replace="android:extractNativeLibs"
i obtained another errors like
Code:
error: '' is incompatible with attribute type (attr) enum [linear=0, radial=1, sweep=2].
error: '' is incompatible with attribute startX (attr) float.
seems AOSP doesn't understand xmlns:tools anymore... Has anyone faced with this issue?
Hi there. What option in Gradle
corresponds to next one from soong build system in AOSP:
certificate: "platform",
I want to find an appropriate one so when I'm installing the application via gradle in android studio and do the same via 'mm' in AOSP i want to obtain one package in a build system.
Hello all,
Wondering if I'm the only one with this issue. I'm trying to generate a signed APK using Android Studio (Build->Generate Signed Bundle / APK...).
However, during the process, an exception is thrown:
Code:
2022-07-19 14:57:49,526 [ 337069] ERROR - intellij.openapi.progress.Task - sun/misc/BASE64Encoder
java.lang.NoClassDefFoundError: sun/misc/BASE64Encoder
This is with the JRE that ships with Android Studio.
I dug into this a bit and found in places that this is a problem caused by running Java 11, since this class was deprecated in Java 9. However, when I run Android Studio with Java 8, it won't load since it complains about needing a later version of Java.
Does anybody else have this problem? Any suggested work-around/hacks for this?
Incidentally - I'm running on Ubuntu, and tried it with the OpenJDK version 8. Haven't tried with the Oracle version of Java yet.
Thanks!