[Q]"cannot find symbol" when trying to build package. - Java for Android App Development

Hi, basically a n00b to Java, and now I have these errors in front of me
I was (and still am) trying to compile ProvisionMod (https://github.com/Provision-Team) [Branch: ICS] for my device. The problem is that everything goes on well, until it starts building the packages. This particular package named ControlPanel (source found here) is causing exactly 14 errors, which is causing the compilation to stop.
Error Log:
Code:
packages/apps/ControlPanel/src/com/provision/customizer/fragment/Clock.java:33: cannot find symbol
symbol : variable CLOCK_USE_SECOND
location: class android.provider.Settings.System
cSecond = new SettingCheckBoxManager(p, "clock_use_second", Settings.System.CLOCK_USE_SECOND, false);
^
packages/apps/ControlPanel/src/com/provision/customizer/fragment/Clock.java:34: cannot find symbol
symbol : variable CLOCK_COLOR
location: class android.provider.Settings.System
cColor = new SettingColorManager(p, "clock_color", Settings.System.CLOCK_COLOR, getResources().getColor(android.R.color.holo_blue_light));
^
packages/apps/ControlPanel/src/com/provision/customizer/fragment/Clock.java:35: cannot find symbol
symbol : variable CLOCK_STYLE
location: class android.provider.Settings.System
cStyle = new SettingListManager(p, "clock_style", Settings.System.CLOCK_STYLE, 0);
^
packages/apps/ControlPanel/src/com/provision/customizer/fragment/GeneralUI.java:28: cannot find symbol
symbol : variable USE_CUSTOM_CARRIER
location: class android.provider.Settings.System
cCarrier = new SettingCheckBoxManager(p, "use_custom_carrier", Settings.System.USE_CUSTOM_CARRIER, false);
^
packages/apps/ControlPanel/src/com/provision/customizer/fragment/GeneralUI.java:29: cannot find symbol
symbol : variable CUSTOM_CARRIER_TEXT
location: class android.provider.Settings.System
eText = new SettingEditManager(p, "custom_carrier_text", Settings.System.CUSTOM_CARRIER_TEXT, "PROVISION");
^
packages/apps/ControlPanel/src/com/provision/customizer/fragment/Navigation.java:104: cannot find symbol
symbol : variable NAVBAR_EDIT
location: class android.provider.Settings.System
Settings.System.putInt(getContentResolver(), Settings.System.NAVBAR_EDIT, on ? 1 : 0);
^
packages/apps/ControlPanel/src/com/provision/customizer/fragment/Navigation.java:105: cannot find symbol
symbol : variable NAVBAR_SAVE
location: class android.provider.Settings.System
Settings.System.putInt(getContentResolver(), Settings.System.NAVBAR_SAVE, save ? 1 : 0);
^
packages/apps/ControlPanel/src/com/provision/customizer/fragment/Navigation.java:207: cannot find symbol
symbol : variable NAVIGATION_BAR_TRANSPARENCY
location: class android.provider.Settings.System
Settings.System.putFloat(getContentResolver(), Settings.System.NAVIGATION_BAR_TRANSPARENCY, (float)(t / 255.0f));
^
packages/apps/ControlPanel/src/com/provision/customizer/fragment/Navigation.java:215: cannot find symbol
symbol : variable NAVIGATION_BAR_COLOR
location: class android.provider.Settings.System
cBkg = new SettingColorManager(root, "navbar_background_color", Settings.System.NAVIGATION_BAR_COLOR, Color.BLACK);
^
packages/apps/ControlPanel/src/com/provision/customizer/fragment/Navigation.java:216: cannot find symbol
symbol : variable NAVIGATION_BUTTON_COLOR
location: class android.provider.Settings.System
cBtn = new SettingColorManager(root, "navbar_color", Settings.System.NAVIGATION_BUTTON_COLOR, Color.WHITE);
^
packages/apps/ControlPanel/src/com/provision/customizer/fragment/Navigation.java:217: cannot find symbol
symbol : variable NAVIGATION_BAR_GLOW_COLOR
location: class android.provider.Settings.System
cGlw = new SettingColorManager(root, "navbar_glow_color", Settings.System.NAVIGATION_BAR_GLOW_COLOR, getResources().getColor(
^
packages/apps/ControlPanel/src/com/provision/customizer/fragment/Navigation.java:220: cannot find symbol
symbol : variable NAVIGATION_BAR_TRANSPARENCY
location: class android.provider.Settings.System
eTrans.setText(String.valueOf((int)(Settings.System.getFloat(getContentResolver(), Settings.System.NAVIGATION_BAR_TRANSPARENCY, 0.6f)) * 255));
^
packages/apps/ControlPanel/src/com/provision/customizer/fragment/NotiPanel.java:26: cannot find symbol
symbol : variable USE_WIDGETBOARD
location: class android.provider.Settings.System
cWeather = new SettingCheckBoxManager(p, "use_weather", Settings.System.USE_WIDGETBOARD, false);
^
packages/apps/ControlPanel/src/com/provision/customizer/fragment/StatusBar.java:31: cannot find symbol
symbol : variable SHOW_IME_SWITCHER
location: class android.provider.Settings.System
cIME = new SettingCheckBoxManager(p, "show_ime_switcher", Settings.System.SHOW_IME_SWITCHER, true);
^
14 errors
make: *** [out/target/common/obj/APPS/ControlPanel_intermediates/classes-full-debug.jar] Error 41
make: *** Waiting for unfinished jobs....
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
DroidDoc took 12 sec. to write docs to out/target/common/docs/api-stubs
Note that the "^" points towards the end of the package name, and beginning of variable name. Example:
Code:
packages/apps/ControlPanel/src/com/provision/customizer/fragment/Clock.java:33: cannot find symbol
symbol : variable CLOCK_USE_SECOND
location: class android.provider.Settings.System
cSecond = new SettingCheckBoxManager(p, "clock_use_second", Settings.System.CLOCK_USE_SECOND, false);
^
Link to the "packages/apps/ControlPanel/src/com/provision/customizer/fragment" folder on GitHub: https://github.com/Provision-Team/android_packages_apps_ControlPanel/tree/ics/src/com/provision/customizer/fragment
Note: I tried using make clean; make update-api; . build/envsetup.sh; brunch pico -j5, but still doesn't work
What could be the cause of this error? Any changes that I need to make, or any variables that I need to pre-initialise, or any libraries to import?

What could be the causes for the error?
Do I need to import android.provider.Settings.System; first?
and/or do i need to initialise those variables first?

vineethraj49 said:
Do I need to import android.provider.Settings.System; first?
and/or do i need to initialise those variables first?
Click to expand...
Click to collapse
What happens if you import it?
Try it.

no use :\
nikwen said:
What happens if you import it?
Try it.
Click to expand...
Click to collapse
I added those lines, along with those import lines usually found on top of the file's contents. still getting the error.
p.s. java -version has anything to do with this?

a few hours of diggin'.
vineethraj49 said:
I added those lines, along with those import lines usually found on top of the file's contents. still getting the error.
p.s. java -version has anything to do with this?
Click to expand...
Click to collapse
Could it be that if the resources, example SHOW_CLOCK etc, are declared private, and the other files can't access it?
i mean, java, i have heard about classes, public, private, etc. so, jus' curious

Cloning from Github. Will look into it.
---------- Post added at 12:11 PM ---------- Previous post was at 12:10 PM ----------
Do you use the Jellybean or ics branch?
EDIT: I saw that you use the ICS branch.
---------- Post added at 12:34 PM ---------- Previous post was at 12:11 PM ----------
Trying to compile the JellyBean version, I got many errors like this one:
Code:
android_packages_apps_ControlPanel\res\layout-land\lockscreen_targets.xml:24: error: Error: No resource found that matches the given name (at 'pointDrawable' with value '@*android:drawable/ic_lockscreen_glowdot').
---------- Post added at 12:41 PM ---------- Previous post was at 12:34 PM ----------
Getting your errors on the ICS branch, too.
Sorry, I do not have an idea.
Did you send an email to the developer? He should be able to help you.
(And please post the solution. )

The problem is: The ROM's old
nikwen said:
Cloning from Github. Will look into it.
---------- Post added at 12:11 PM ---------- Previous post was at 12:10 PM ----------
Do you use the Jellybean or ics branch?
EDIT: I saw that you use the ICS branch.
---------- Post added at 12:34 PM ---------- Previous post was at 12:11 PM ----------
Trying to compile the JellyBean version, I got many errors like this one:
Code:
android_packages_apps_ControlPanel\res\layout-land\lockscreen_targets.xml:24: error: Error: No resource found that matches the given name (at 'pointDrawable' with value '@*android:drawable/ic_lockscreen_glowdot').
---------- Post added at 12:41 PM ---------- Previous post was at 12:34 PM ----------
Getting your errors on the ICS branch, too.
Sorry, I do not have an idea.
Did you send an email to the developer? He should be able to help you.
(And please post the solution. )
Click to expand...
Click to collapse
As I said, the ROM is around 8 months old. And, it was made for specific devices. Even though the Jellybean sources are more *updated* (sort of), I am surprised that even they give errors.
And, not many releases on XDA either. All are released here: http://www.provisionmod.com/download
Their latest release was last month, but, all the repositories were updated 7-8 months ago.
I contacted Vista ([email protected]) using info from this thread: http://forum.xda-developers.com/showthread.php?t=1691519.
And, the video review shows that the customizer is the coolest feature in ICS :crying:
Still waiting for his reply. Will sure inform as soon as I get the reply :silly:

Ok i have a similar issue started at 260 errors now down to 3 errors, from what i can see the issues you are facing are very similar to mine
heres one of yours
packages/apps/ControlPanel/src/com/provision/customizer/fragment/Navigation.java:215: cannot find symbol
symbol : variable NAVIGATION_BAR_COLOR
location: class android.provider.Settings.System
cBkg = new SettingColorManager(root, "navbar_background_color", Settings.System.NAVIGATION_BAR_COLOR, Color.BLACK);
Click to expand...
Click to collapse
NOTE it is pointing to location: class android.provider.Settings.System
For this issue, i would personally start looking at the location <source_dir>/frameworks/base/core/java/android/provider
open Settings.java and find this line cBkg = new SettingColorManager(root, "navbar_background_color", Settings.System.NAVIGATION_BAR_COLOR, Color.BLACK);
if it is not there, quick search of "NAVIGATION_BAR_COLOR" should list all of the matches
then it needs to be added, easiest way to do this assuming you are on linux is install meld diff viewer and compare the Settings.java file with the one from the original Framework repository
sorry i have not worded this very good, i find it hard to explain this sorta stuff if you have no luck, pm me and i will download the source into my tree and help you

Bad luck... they removed the entire source a couple of weeks ago and I too don't have a copy of it (lost it as it was in my old computer and I frequently repartition it)
Anyways, thanks for trying to help
Sent from my HTC Explorer A310e using xda app-developers app

Related

[Q] Changing smali using apktool gives problem with r.Java

I've been stuck for a while now, trying to add some new functionality (day counter) to an existing apk (widget).
What I've done so far:
- unpacked the apk using apktool (using apktool d -d)
- start new project in netbeans with the specific source
- adding the java class to the existing package
The java code introduces some new parameters. I've added the parameters to different xml's. When I try to rebuild I keep getting the message:
cannot find symbol
symbol : variable layout
location: class fr.gdi.android.news.R
remoteViews = new RemoteViews(context.getPackageName(), R.layout.main);
Can anyone give me a hint what to do?
some additional info. This is the class I'm trying to add:
Code:
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package fr.gdi.android.news;
/**
*
* @author John
*/
import java.util.Calendar;
import java.util.Date;
import java.util.GregorianCalendar;
import java.util.Timer;
import java.util.TimerTask;
import android.appwidget.AppWidgetManager;
import android.appwidget.AppWidgetProvider;
import android.content.ComponentName;
import android.content.Context;
import android.widget.RemoteViews;
public class CountDays extends AppWidgetProvider {
@Override
public void onUpdate(Context context, AppWidgetManager appWidgetManager,
int[] appWidgetIds) {
Timer timer = new Timer();
timer.scheduleAtFixedRate(new MyTime(context, appWidgetManager), 1, 60000);
}
private class MyTime extends TimerTask {
RemoteViews remoteViews;
AppWidgetManager appWidgetManager;
ComponentName thisWidget;
public MyTime(Context context, AppWidgetManager appWidgetManager) {
this.appWidgetManager = appWidgetManager;
remoteViews = new RemoteViews(context.getPackageName(), R.layout.main);
thisWidget = new ComponentName(context, CountDays.class);
}
@Override
public void run() {
Date date1 = new Date();
Calendar calendar = new GregorianCalendar(2010, 11,25);
long days = (((calendar.getTimeInMillis()- date1.getTime())/1000))/86400;
remoteViews.setTextViewText(R.id.days,""+ days);
appWidgetManager.updateAppWidget(thisWidget, remoteViews);
}
}
}
1. Apktool does not support writing your code in Java right now. Whole story is here: http://code.google.com/p/android-apktool/issues/detail?id=88 . If you want to use Java, it's possible, but you will have to use a workaround. It's not that hard to implement, but requires you to understand, how Java/javac/bytecode works. Workaround is described in above link, if you don't want to read full story, instructions start at "My script is here".
2. I think (but maybe I'm wrong) that you misunderstand, how R references work. These R.drawables.xxx strings aren't magically converted to resIDs at compile or run time. To use them you have to generate proper R class using SDK. If you use Eclipse or Netbeans, you don't have to do that, cause IDE regenerates R.java file each time you modify something in resources, so you can use R references in your code whenever you want.
In app decoded by apktool you have to manage resIDs manually. It's caused by the fact, that if you want to use some resources in smali, you can't let SDK generate ids for these resources automatically, cause resIDs are stored in smali in numerical form, i.e. "const v0, 0x7f012345", not something like "const v0, R.drawables.xxx". So if you would add e.g. "const v0, 0x7f012345" line to smali and resIDs would be regenerated, your line might reference other resource, that you want.
Of course that's not the case if you want to use resources from Java code, but as I said, this feature isn't fully supported by apktool. Also I think it would be good to add possibility to generate resIDs automatically, even for smali code, cause managing resIDs manually is very inconvenient. But that's future.
For now if you want to add new resource and use it from your Java/smali code, you have to modify public.xml file, add that resource with next free resID and then use that resID from your code.
If you want to know more, you could read this: http://forum.xda-developers.com/showthread.php?p=7380557#post7380557
@Brut.all: Thanks for your extensive answer! I will read the stuff you mention and get back at it.
@Brut.all: I think you're right about me not understanding R.java completely. But what I understand from your story is this. When I want a new resource to use in a new class and to be used in the existing xml, I would have to do the following:
- add a line to the res/values/ids.xml, for example:
Code:
<item type="id" name="main">false</item>
- add a line to the res/values/public.xml, for example:
Code:
<public type="id" name="main" id="0x7f0a0034" />
- add a line to the R$id.java and R$layout.java (don't exactly know which one)
Code:
.field public static final main:I = 0x7f0a0034
first: is this correct? second: How can I refer to the newly added resource in my new class. R.layout.main doesn't work, R$layout.main doesn't work.
Code:
remoteViews = new RemoteViews(context.getPackageName(), R$layout.main);
john37 said:
- add a line to the res/values/ids.xml, for example:
Code:
<item type="id" name="main">false</item>
Click to expand...
Click to collapse
You don't have to do that. If you add new drawable, XML or @+id/something value, then it's ok.
john37 said:
- add a line to the res/values/public.xml, for example:
Code:
<public type="id" name="main" id="0x7f0a0034" />
Click to expand...
Click to collapse
Yes.
john37 said:
- add a line to the R$id.java and R$layout.java (don't exactly know which one)
Code:
.field public static final main:I = 0x7f0a0034
Click to expand...
Click to collapse
No ;-)
If you want to use these resources in smali, then you could use them as is, e.g.: "const v0, 0x7f0a0034".
If you want to use my workaround to work in Java, then you could do the same, as above, e.g.:
Code:
int id = 0x7f0a0034;
or you could do this cleaner and generate R class manually: remove all existing R*.java classes (they aren't used) and create single R.java file:
Code:
public final class R {
public static final class id {
public static final int main = 0x7f0a0034;
}
}
and then you could use it as "R.id.main" in your code.
But first you have to implement workaround to use any Java code.
@Brut.all: thanks again for your reply. I think I didn't understand your previous story fully. I am 'developing' on windows, so your workaround is going to be tricky. Do you know if anyone has ported your script to windows?
Some additional info: I don't want to use a new resource in the existing smali code. What I want is a new resource, say @id/main, to be used in the xml files and in a java class, which describes the method that should be invoked when the widget updates.
What I've done now is that I've made a new R$main class with the resources I want to use. I also made the java class with the method and it refers to the resources mentioned in the R$main class. This way I can build it without problems in Netbeans. But when I want to use apktool, I keep getting the message:
Code:
I: Checking whether sources has changed...
I: Smaling...
Exception in thread "main" java.lang.NullPointerException
at org.jf.util.PathUtil.getRelativeFile(Unknown Source)
at org.jf.smali.smaliFlexLexer.getSourceName(Unknown Source)
at org.jf.smali.smaliFlexLexer.getErrorHeader(Unknown Source)
at org.jf.smali.smaliFlexLexer.nextToken(Unknown Source)
at org.antlr.runtime.CommonTokenStream.fillBuffer(Unknown Source)
at org.antlr.runtime.CommonTokenStream.LT(Unknown Source)
at org.jf.smali.smaliParser.smali_file(Unknown Source)
at brut.androlib.mod.SmaliMod.assembleSmaliFile(Unknown Source)
at brut.androlib.src.DexFileBuilder.addSmaliFile(Unknown Source)
at brut.androlib.src.SmaliBuilder.buildFile(Unknown Source)
at brut.androlib.src.SmaliBuilder.build(Unknown Source)
at brut.androlib.src.SmaliBuilder.build(Unknown Source)
at brut.androlib.Androlib.buildSourcesSmali(Unknown Source)
at brut.androlib.Androlib.buildSources(Unknown Source)
at brut.androlib.Androlib.build(Unknown Source)
at brut.androlib.Androlib.build(Unknown Source)
at brut.apktool.Main.cmdBuild(Unknown Source)
at brut.apktool.Main.main(Unknown Source)
Maybe I'm completely on the wrong track...
Sometimes I get NullPointerException instead of real smali errors, when I'm doing "apktool b". I think it's a bug in the apktool. Try to smali "smali" dir normally, without apktool to see errors.
But I don't really see much sense in adding any Java classes, because they just can't work without additional steps. What my script does, is:
javac all files from brut.iface
javac all files from brut.src against compiled brut.iface
convert compiled brut.src to smali. This is done in two steps:
dx them to classes.dex
baksmali them using baksmali or apktool
Most of commands from my script (javac, dx, apktool/baksmali) should work on a Windows. File operations, i.e. mkdir, rm, cp should be easily portable. I don't know, how to replace "find" command.
You could try to use Cygwin - then you should be able to run my script on a Windows.
To do this properly, I'm installing Linux now, so my next reply could take a while...

[Q] Compile CM7 from Source for Galaxy Tab - Case Study

Im trying to compile cm7 to learn how to and I'm getting an error on compile.
I've found on XDA some topics with same issue but without solution and I don't know if this thread is valid.
But its very annoying send PM to ask about this and I prefer make this public.
I'm getting this error on build:
make: *** No rule to make target `otapackage'. Stop.
following this tutorial: Build_CyanogenMod_for_Samsung_GalaxyTab
and specifically at this line:
make -j`grep 'processor' /proc/cpuinfo | wc -l` CYANOGEN_WITH_GOOGLE=true otapackage
can someone help on this ?
I have no idea how to proceed.
thanks in advance.
You're missing something. Check that you have no unresolved dependencies. also try it without CYANOGEN_WITH_GOOGLE=true and see what, if any, error it throws.
the error is the same i've compared all lines.
take a look on complete output :
http://pastebin.com/2QfpbdV0
any ideas?
It looks like your build environment is off.
sudo apt-get/aptitude update
sync android again
Make sure you have the appropriate libraries for your architecture (32/64)
Also, if you're using Ubuntu, make sure you have the right Java repositories for your version.
On Ubuntu 10.10+ you need to add repositories to get Sun Java (or Oracle Java, I suppose). I don't think the open JDK stuff works properly. I may be wrong
i think my ubuntu is configured because i'm able to compile p1000 kernel with it.
there's another thing to verify?
I've ran repo sync again, buildmodules from galaxytab/tools but the same problem...
hello
Galaxy Tab P1000 to my device
pit = P1_add_hidden
pda = P1000XWJMI-REV03-ALL-CL869777.tar
phone = MODEM_P1000XXJMA.tar
csc = GT-P1000-CSC-SERJM4.tar
has failed my first installation on pc
whether the pit again, when I successfully finished the installation
but when the tab restart
GALAXY TAB
SAMSUNG
article remains
Can you help
(downloading part of the input device is able to, the same problem I tried to install the older roms)
Can you help to have a very short time to
please
bilal
ivannw said:
i think my ubuntu is configured because i'm able to compile p1000 kernel with it.
there's another thing to verify?
Click to expand...
Click to collapse
Not really. This sort of resource issue is so specific and unique to each computer/build environment that someone would almost have to be standing over your shoulder following along to tell you EXACTLY what is going wrong... Unless they have had an identical issue, and I haven't. If everything checks out as per above, I would reinstall everything starting with linux and find a more complete guide for the specific task you are undertaking and try again.
Failing that, you can download a copy of the Gentoo Linux install (compile it yourself, not with the GUI version) and use their guide step by step. Once that is done, grab the Android SDK and head over to hackaday and follow thier Android 101 guide to its end. Do this, and you'll be a pro at compiling from source and the basics of android. You will have learned more than you would have in any 200 level undergrad course and it wont even take you more than three or four days. After that, try again and it's likely that you'll spot the problem before it even crops up again.
spacemoose1, thanks for your help.
I'll create a new VM with your considerations to study more and more.
BTW, I got a new status, now the make stops on this error;
Code:
target Java: MagicSmokeWallpapers (out/target/common/obj/APPS/MagicSmokeWallpapers_intermediates/classes)
packages/apps/CMParts/src/com/cyanogenmod/cmparts/activities/PowerWidgetActivity.java:20: package com.android.wimax does not exist
import com.android.wimax.WimaxConstants;
^
target Java: Music3 (out/target/common/obj/APPS/Music3_intermediates/classes)
target Java: Nfc (out/target/common/obj/APPS/Nfc_intermediates/classes)
Note: frameworks/base/tests/LocationTracker/src/com/android/locationtracker/TrackerService.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
target Java: NinePatchLab (out/target/common/obj/APPS/NinePatchLab_intermediates/classes)
packages/apps/CMParts/src/com/cyanogenmod/cmparts/activities/PowerWidgetActivity.java:140: cannot find symbol
symbol : variable WimaxConstants
location: class com.cyanogenmod.cmparts.activities.PowerWidgetActivity
if (!WimaxConstants.isWimaxSupported(this)) {
^
target Java: Pacman (out/target/common/obj/APPS/Pacman_intermediates/classes)
packages/apps/CMParts/src/com/cyanogenmod/cmparts/activities/UIStatusBarActivity.java:53: cannot find symbol
symbol : variable STATUS_BAR_CLOCK
location: class android.provider.Settings.System
Settings.System.STATUS_BAR_CLOCK, 1) == 1));
^
packages/apps/CMParts/src/com/cyanogenmod/cmparts/activities/UIStatusBarActivity.java:55: cannot find symbol
symbol : variable STATUS_BAR_CM_BATTERY
location: class android.provider.Settings.System
Settings.System.STATUS_BAR_CM_BATTERY, 0) == 1));
^
packages/apps/CMParts/src/com/cyanogenmod/cmparts/activities/UIStatusBarActivity.java:65: cannot find symbol
symbol : variable STATUS_BAR_CLOCK
location: class android.provider.Settings.System
Settings.System.putInt(getContentResolver(), Settings.System.STATUS_BAR_CLOCK,
^
packages/apps/CMParts/src/com/cyanogenmod/cmparts/activities/UIStatusBarActivity.java:70: cannot find symbol
symbol : variable STATUS_BAR_CM_BATTERY
location: class android.provider.Settings.System
Settings.System.putInt(getContentResolver(), Settings.System.STATUS_BAR_CM_BATTERY,
^
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
6 errors
packages/apps/Settings/src/com/android/settings/widget/buttons/WimaxButton.java:8: package com.android.wimax does not exist
import com.android.wimax.WimaxSettingsHelper;
^
packages/apps/Settings/src/com/android/settings/widget/buttons/WimaxButton.java:9: package com.android.wimax does not exist
import com.android.wimax.WimaxConstants;
^
packages/apps/Settings/src/com/android/settings/widget/SettingsAppWidgetProvider.java:38: package com.android.wimax does not exist
import com.android.wimax.WimaxConstants;
^
packages/apps/Settings/src/com/android/settings/widget/WidgetSettings.java:5: package com.android.wimax does not exist
import com.android.wimax.WimaxSettingsHelper;
^
packages/apps/Settings/src/com/android/settings/widget/WidgetSettings.java:6: package com.android.wimax does not exist
import com.android.wimax.WimaxConstants;
^
packages/apps/Settings/src/com/android/settings/WirelessSettings.java:37: package com.android.settings.wimax does not exist
import com.android.settings.wimax.WimaxEnabler;
^
packages/apps/Settings/src/com/android/settings/WirelessSettings.java:61: cannot find symbol
symbol : class WimaxEnabler
location: class com.android.settings.WirelessSettings
private WimaxEnabler mWimaxEnabler;
^
make: *** [out/target/common/obj/APPS/CMParts_intermediates/classes-full-debug.jar] Error 41
make: *** Waiting for unfinished jobs....
packages/apps/Settings/src/com/android/settings/widget/buttons/WimaxButton.java:30: cannot find symbol
symbol : class WimaxSettingsHelper
location: class com.android.settings.widget.buttons.WimaxButton.WimaxStateTracker
final WimaxSettingsHelper helper = new WimaxSettingsHelper(context);
^
packages/apps/Settings/src/com/android/settings/widget/buttons/WimaxButton.java:30: cannot find symbol
symbol : class WimaxSettingsHelper
location: class com.android.settings.widget.buttons.WimaxButton.WimaxStateTracker
final WimaxSettingsHelper helper = new WimaxSettingsHelper(context);
^
packages/apps/Settings/src/com/android/settings/widget/buttons/WimaxButton.java:39: cannot find symbol
symbol : class WimaxSettingsHelper
location: class com.android.settings.widget.buttons.WimaxButton.WimaxStateTracker
final WimaxSettingsHelper helper = new WimaxSettingsHelper(context);
^
packages/apps/Settings/src/com/android/settings/widget/buttons/WimaxButton.java:39: cannot find symbol
symbol : class WimaxSettingsHelper
location: class com.android.settings.widget.buttons.WimaxButton.WimaxStateTracker
final WimaxSettingsHelper helper = new WimaxSettingsHelper(context);
^
packages/apps/Settings/src/com/android/settings/widget/buttons/WimaxButton.java:60: package WimaxConstants does not exist
if (!WimaxConstants.WIMAX_ENABLED_CHANGED_ACTION.equals(intent.getAction())) {
^
packages/apps/Settings/src/com/android/settings/widget/buttons/WimaxButton.java:63: cannot find symbol
symbol : variable WimaxConstants
location: class com.android.settings.widget.buttons.WimaxButton.WimaxStateTracker
int wimaxState = intent.getIntExtra(WimaxConstants.CURRENT_WIMAX_ENABLED_STATE, WimaxConstants.WIMAX_ENABLED_STATE_UNKNOWN);
^
packages/apps/Settings/src/com/android/settings/widget/buttons/WimaxButton.java:63: cannot find symbol
symbol : variable WimaxConstants
location: class com.android.settings.widget.buttons.WimaxButton.WimaxStateTracker
int wimaxState = intent.getIntExtra(WimaxConstants.CURRENT_WIMAX_ENABLED_STATE, WimaxConstants.WIMAX_ENABLED_STATE_UNKNOWN);
^
packages/apps/Settings/src/com/android/settings/widget/buttons/WimaxButton.java:74: cannot find symbol
symbol : variable WimaxConstants
location: class com.android.settings.widget.buttons.WimaxButton.WimaxStateTracker
case WimaxConstants.WIMAX_ENABLED_STATE_DISABLED:
^
packages/apps/Settings/src/com/android/settings/widget/buttons/WimaxButton.java:76: cannot find symbol
symbol : variable WimaxConstants
location: class com.android.settings.widget.buttons.WimaxButton.WimaxStateTracker
case WimaxConstants.WIMAX_ENABLED_STATE_ENABLED:
^
packages/apps/Settings/src/com/android/settings/widget/buttons/WimaxButton.java:78: cannot find symbol
symbol : variable WimaxConstants
location: class com.android.settings.widget.buttons.WimaxButton.WimaxStateTracker
case WimaxConstants.WIMAX_ENABLED_STATE_ENABLING:
^
packages/apps/Settings/src/com/android/settings/widget/buttons/WimaxButton.java:80: cannot find symbol
symbol : variable WimaxConstants
location: class com.android.settings.widget.buttons.WimaxButton.WimaxStateTracker
case WimaxConstants.WIMAX_ENABLED_STATE_DISABLING:
^
packages/apps/Settings/src/com/android/settings/widget/SettingsAppWidgetProvider.java:318: package WimaxConstants does not exist
} else if (WimaxConstants.WIMAX_ENABLED_CHANGED_ACTION.equals(intent.getAction())) {
^
packages/apps/Settings/src/com/android/settings/widget/WidgetSettings.java:307: cannot find symbol
symbol : variable WimaxConstants
location: class com.android.settings.widget.WidgetSettings
if (!WimaxConstants.isWimaxSupported(this)) {
^
packages/apps/Settings/src/com/android/settings/WirelessSettings.java:108: cannot find symbol
symbol : class WimaxEnabler
location: class com.android.settings.WirelessSettings
mWimaxEnabler = new WimaxEnabler(this, getSystemService(Context.WIMAX_SERVICE), wimax);
^
packages/apps/Settings/src/com/android/settings/WirelessSettings.java:108: cannot find symbol
symbol : variable WIMAX_SERVICE
location: class android.content.Context
mWimaxEnabler = new WimaxEnabler(this, getSystemService(Context.WIMAX_SERVICE), wimax);
^
packages/apps/Settings/src/com/android/settings/WirelessSettings.java:128: cannot find symbol
symbol : variable RADIO_WIMAX
location: class android.provider.Settings.System
if (toggleable == null || !toggleable.contains(Settings.System.RADIO_WIMAX)) {
^
packages/apps/Settings/src/com/android/settings/WirelessSettings.java:144: cannot find symbol
symbol : variable WIMAX_SERVICE
location: class android.content.Context
if (getSystemService(Context.WIMAX_SERVICE) == null) {
^
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
24 errors
make: *** [out/target/common/obj/APPS/Settings_intermediates/classes-full-debug.jar] Error 41
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
any idea?

[Q] [help] Compile defy CM7 failed about layoutlib

Copying: out/target/common/obj/APPS/TagCanon_intermediates/emma_out/lib/classes-jarjar.jar
Install: out/target/product/jordan/recovery/root/sbin/mke2fs
Install: out/host/linux-x86/lib/libSR_Session.so
Install: out/host/linux-x86/lib/libSR_Recognizer.so
Copying: out/target/common/obj/APPS/ADWLauncher_intermediates/noproguard.classes.dex
Copying: out/target/common/obj/APPS/AccountAndSyncSettings_intermediates/noproguard.classes.dex
target Dex: AndroidTerm
Install: out/target/product/jordan/system/lib/libutils.so
target Dex: javax.obex
target Dex: ApplicationsProvider
frameworks/base/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/android/BridgeTypedArray.java:19: cannot find symbol
symbol : class DeclareStyleableResourceValue
location: package com.android.ide.common.rendering.api
import com.android.ide.common.rendering.api.DeclareStyleableResourceValue;
^
frameworks/base/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/android/BridgeResources.java:243: getParser(java.lang.String) in com.android.ide.common.rendering.api.IProjectCallback cannot be applied to (com.android.ide.common.rendering.api.ResourceValue)
parser = mProjectCallback.getParser(value);
^
frameworks/base/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/android/BridgeContext.java:311: getParser(java.lang.String) in com.android.ide.common.rendering.api.IProjectCallback cannot be applied to (com.android.ide.common.rendering.api.ResourceValue)
parser = mProjectCallback.getParser((ResourceValue) resource);
^
frameworks/base/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/android/BridgeTypedArray.java:218: cannot find symbol
symbol : class DeclareStyleableResourceValue
location: class com.android.layoutlib.bridge.android.BridgeTypedArray
if (styleable instanceof DeclareStyleableResourceValue) {
^
frameworks/base/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/android/BridgeTypedArray.java:219: cannot find symbol
symbol : class DeclareStyleableResourceValue
location: class com.android.layoutlib.bridge.android.BridgeTypedArray
map = ((DeclareStyleableResourceValue) styleable).getAttributeValues(mNames[index]);
^
Note: frameworks/base/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/android/BridgeContentResolver.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
5 errors
make: *** [out/host/common/obj/JAVA_LIBRARIES/layoutlib_intermediates/javalib.jar] Error 41
make: *** Waiting for unfinished jobs....
Thanks~
no com.android.ide.common.rendering.api package
i have grep all the android source code, but no find packet com.android.ide.common.rendering.api

How to build CM9/AOSP?

Hi
I just cloned tpruvot's (Epsylon's?) git tree but I fail to build it.
The errormessage I get is that I have no Nullable object.. what?
I have found this thread http://forum.xda-developers.com/newreply.php?do=newreply&p=21076345 with the same error message
Oogy said:
Code:
host Java: chimpchat (out/host/common/obj/JAVA_LIBRARIES/chimpchat_intermediates/classes)
sdk/chimpchat/src/com/android/chimpchat/core/IChimpDevice.java:26: cannot find symbol
symbol : class Nullable
location: package javax.annotation
import javax.annotation.Nullable;
^
target Dex: apache-xml-hostdex
sdk/chimpchat/src/com/android/chimpchat/core/IChimpDevice.java:61: cannot find symbol
symbol : class Nullable
location: interface com.android.chimpchat.core.IChimpDevice
void reboot(@Nullable String into);
^
sdk/chimpchat/src/com/android/chimpchat/core/IChimpDevice.java:167: cannot find symbol
symbol : class Nullable
location: interface com.android.chimpchat.core.IChimpDevice
void startActivity(@Nullable String uri, @Nullable String action,
^
sdk/chimpchat/src/com/android/chimpchat/core/IChimpDevice.java:167: cannot find symbol
symbol : class Nullable
location: interface com.android.chimpchat.core.IChimpDevice
void startActivity(@Nullable String uri, @Nullable String action,
^
sdk/chimpchat/src/com/android/chimpchat/core/IChimpDevice.java:168: cannot find symbol
symbol : class Nullable
location: interface com.android.chimpchat.core.IChimpDevice
@Nullable String data, @Nullable String mimeType,
^
sdk/chimpchat/src/com/android/chimpchat/core/IChimpDevice.java:168: cannot find symbol
symbol : class Nullable
location: interface com.android.chimpchat.core.IChimpDevice
@Nullable String data, @Nullable String mimeType,
^
sdk/chimpchat/src/com/android/chimpchat/core/IChimpDevice.java:169: cannot find symbol
symbol : class Nullable
location: interface com.android.chimpchat.core.IChimpDevice
Collection<String> categories, Map<String, Object> extras, @Nullable String component,
^
sdk/chimpchat/src/com/android/chimpchat/core/IChimpDevice.java:184: cannot find symbol
symbol : class Nullable
location: interface com.android.chimpchat.core.IChimpDevice
void broadcastIntent(@Nullable String uri, @Nullable String action,
^
sdk/chimpchat/src/com/android/chimpchat/core/IChimpDevice.java:184: cannot find symbol
symbol : class Nullable
location: interface com.android.chimpchat.core.IChimpDevice
void broadcastIntent(@Nullable String uri, @Nullable String action,
^
sdk/chimpchat/src/com/android/chimpchat/core/IChimpDevice.java:185: cannot find symbol
symbol : class Nullable
location: interface com.android.chimpchat.core.IChimpDevice
@Nullable String data, @Nullable String mimeType,
^
sdk/chimpchat/src/com/android/chimpchat/core/IChimpDevice.java:185: cannot find symbol
symbol : class Nullable
location: interface com.android.chimpchat.core.IChimpDevice
@Nullable String data, @Nullable String mimeType,
^
sdk/chimpchat/src/com/android/chimpchat/core/IChimpDevice.java:186: cannot find symbol
symbol : class Nullable
location: interface com.android.chimpchat.core.IChimpDevice
Collection<String> categories, Map<String, Object> extras, @Nullable String component,
^
sdk/chimpchat/src/com/android/chimpchat/adb/AdbChimpDevice.java:402: cannot find symbol
symbol : class Nullable
location: class com.android.chimpchat.adb.AdbChimpDevice
private static boolean isNullOrEmpty(@Nullable String string) {
^
13 errors
make: *** [out/host/common/obj/JAVA_LIBRARIES/chimpchat_intermediates/javalib.jar] Error 41
make: *** Waiting for unfinished jobs....
Click to expand...
Click to collapse
But there is no solution other than reinstall JDK, which I have done like three times now. So what JDK release should I use? currently running JDK6 update 31.
EDIT: Forgot what linux dist, and I'm one of those crazy people who run linux from scratch -.- version 7.0
Try oracle java7.
I'm on Ubuntu.
---------------------------------------------------
Motorola Defy red lens
German Vodafone Froyo based
CM7.2 nightly 20120402 by Maniac
Yeah Jdk 7 should work...
Sent from my MB526 using xda premium
Questions go in the Q&A section, not the Dev section
Use Ubuntu 10.04 LTS , should provide lesser errors
Ace-ing all tests.
sakitobaki said:
Try oracle java7.
I'm on Ubuntu.
---------------------------------------------------
Motorola Defy red lens
German Vodafone Froyo based
CM7.2 nightly 20120402 by Maniac
Click to expand...
Click to collapse
nogoodusername said:
Yeah Jdk 7 should work...
Sent from my MB526 using xda premium
Click to expand...
Click to collapse
Just installed and I did get past the earlier error message. Now it is whining about "target release 1.5 conflicts with default source release 1.7" why? And isn't Android 2.3+ using java version 1.6?
EmoBoiix3 said:
Use Ubuntu 10.04 LTS , should provide lesser errors
Ace-ing all tests.
Click to expand...
Click to collapse
I didn't create my own distribution based on LFS just to use Ubuntu. And I'm not going to learn anything from taking the short way around the problem. Ubuntu is when everything else fails.
Febernacke said:
Just installed and I did get past the earlier error message. Now it is whining about "target release 1.5 conflicts with default source release 1.7" why? And isn't Android 2.3+ using java version 1.6?
Click to expand...
Click to collapse
I'm in the same boat, trying to compile CM10, and found this thread. Java 1.6 and I get the IChimp Nullable errors, using 1.7 (on Ubuntu, for that matter) refuses to even compile with this error...
Everyone seems to treat Ubuntu as the distro of choice for compiling Android on, and it doesn't seem to work all that well for me... I would hate to see the errors people are getting on other distros...

[Q] Kltechnduo's Compile Error

Hi everybody,
I have a Galaxy S5 device, and I want to compile a rom package for it with code of CM12.1.
First I downloaded the CyanogenMod code from network, and configuration files for kltechnduo, klte and klte-common's device (such as vendor and kernel files).
Follow the CM official guide on wik, I compiled a rom package(fit for klte), but the package can't be flashing into my kltechnduo device with the right TWRP version(2.8.5.0).
Then I tried to compile another package which are fitting for kltechnduo device, and I got an error like this:
Code:
Import includes file: /home/kaisiyvn/projects/kltechnduo/CM12.1/out/target/product/kltechnduo/obj/SHARED_LIBRARIES/libinputservice_intermediates/import_includes
make: *** No rule to make target '/home/kaisiyvn/projects/kltechnduo/CM12.1/out/target/product/kltechnduo/obj/lib/libtime_genoff.so',
needed by '/home/kaisiyvn/projects/kltechnduo/CM12.1/out/target/product/kltechnduo /obj/SHARED_LIBRARIES/libandroid_servers_intermediates/LINKED /libandroid_servers.so'。 Stop。
no .so files ?
kltechnduo/obj/lib/libtime_genoff.so
libandroid_servers_intermediates/LINKED/libandroid_servers.so
I tried to copy the klte's libtime_genoff.so and libandroid_servers_intermediates to the kltechnduo's out folder, and continue brunch kltechnduo, and another error:
Code:
make: *** No rule to make target '/home/kaisiyvn/projects/kltechnduo/CM12.1/out/target/common/obj/JAVA_LIBRARIES/org.cyanogenmod.platform.sdk_intermediates/javalib.jar',
needed by '/home/kaisiyvn/projects/kltechnduo/CM12.1/out/target/common/obj/APPS /SystemUI_intermediates/classes-full-debug.jar'。 Stop。
I dont know why it always through errors, I just copy the klte's lib to the kltechnduo, and continue complie it, then got other errors:
Code:
target Java: CMAccount (/home/kaisiyvn/projects/kltechnduo/CM12.1/out/target/common/obj/APPS/CMAccount_intermediates/classes)
frameworks/base/packages/SystemUI/src/com/android/systemui/qs/QSDetailItemsGrid.java:52: Error : cannot find symbol
CustomTile.ExpandedItem[] items) {
^
symbol: class ExpandedItem
location: class CustomTile
frameworks/base/packages/SystemUI/src/com/android/systemui/qs/QSDetailItemsGrid.java:75: Error : cannot find symbol
private CustomTile.ExpandedItem[] mItems;
^
symbol: class ExpandedItem
location: class CustomTile
frameworks/base/packages/SystemUI/src/com/android/systemui/qs/QSDetailItemsGrid.java:83: Error : cannot find symbol
Context context, CustomTile.ExpandedItem[] items) {
^
symbol: class ExpandedItem
location: class CustomTile
frameworks/base/packages/SystemUI/src/com/android/systemui/qs/QSDetailItemsGrid.java:100: Error : cannot find symbol
public CustomTile.ExpandedItem getItem(int position) {
^
symbol: class ExpandedItem
location: class CustomTile
frameworks/base/packages/SystemUI/src/com/android/systemui/qs/QSDetailItemsGrid.java:79: Error : cannot find symbol
void onPsuedoGridItemClick(View view, CustomTile.ExpandedItem item);
^
symbol: class ExpandedItem
location: class CustomTile
frameworks/base/packages/SystemUI/src/com/android/systemui/qs/QSDetailItemsList.java:100: Error : cannot find symbol
public static class QSCustomDetailListAdapter extends ArrayAdapter<CustomTile.ExpandedItem> {
^
symbol: class ExpandedItem
location: class CustomTile
frameworks/base/packages/SystemUI/src/com/android/systemui/qs/QSDetailItemsList.java:104: Error : cannot find symbol
List<CustomTile.ExpandedItem> objects) {
^
symbol: class ExpandedItem
location: class CustomTile
frameworks/base/packages/SystemUI/src/com/android/systemui/qs/tiles/CustomQSTile.java:47: Error : cannot find symbol
private CustomTile.ExpandedStyle mExpandedStyle;
^
symbol: class ExpandedStyle
location: class CustomTile
frameworks/base/packages/SystemUI/src/com/android/systemui/qs/tiles/CustomQSTile.java:215: Error : cannot find symbol
public void onPsuedoGridItemClick(View view, CustomTile.ExpandedItem item) {
^
symbol: class ExpandedItem
location: class CustomTile
frameworks/base/packages/SystemUI/src/com/android/systemui/qs/QSDetailItemsGrid.java:113: Error : cannot find symbol
CustomTile.ExpandedItem item = getItem(i);
^
symbol: class ExpandedItem
location: class CustomTile
frameworks/base/packages/SystemUI/src/com/android/systemui/qs/QSDetailItemsGrid.java:134: Error : cannot find symbol
CustomTile.ExpandedItem item = (CustomTile.ExpandedItem) view.getTag();
^
symbol: class ExpandedItem
location: class CustomTile
frameworks/base/packages/SystemUI/src/com/android/systemui/qs/QSDetailItemsGrid.java:134: Error : cannot find symbol
CustomTile.ExpandedItem item = (CustomTile.ExpandedItem) view.getTag();
^
symbol: class ExpandedItem
location: class CustomTile
frameworks/base/packages/SystemUI/src/com/android/systemui/qs/QSDetailItemsList.java:117: Error : cannot find symbol
final CustomTile.ExpandedItem item = getItem(position);
^
symbol: class ExpandedItem
location: class CustomTile
frameworks/base/packages/SystemUI/src/com/android/systemui/qs/tiles/CustomQSTile.java:94: Error : cannot find symbol
mExpandedStyle.getStyle() != CustomTile.ExpandedStyle.NO_STYLE) {
^
symbol: variable ExpandedStyle
location: class CustomTile
frameworks/base/packages/SystemUI/src/com/android/systemui/qs/tiles/CustomQSTile.java:131: Error : cannot find symbol
mExpandedStyle = customTile.expandedStyle;
^
symbol: variable expandedStyle
location: Type CustomTile variable customTile
frameworks/base/packages/SystemUI/src/com/android/systemui/qs/tiles/CustomQSTile.java:186: Error : cannot find symbol
case CustomTile.ExpandedStyle.GRID_STYLE:
^
symbol: variable ExpandedStyle
location: class CustomTile
frameworks/base/packages/SystemUI/src/com/android/systemui/qs/tiles/CustomQSTile.java:193: Error : cannot find symbol
case CustomTile.ExpandedStyle.LIST_STYLE:
^
symbol: variable ExpandedStyle
location: class CustomTile
frameworks/base/packages/SystemUI/src/com/android/systemui/qs/tiles/CustomQSTile.java:210: Error : cannot find symbol
CustomTile.ExpandedItem item = mListAdapter.getItem(position);
^
symbol: class ExpandedItem
location: class CustomTile
18 Errors
build/core/java.mk:346: recipe for target '/home/kaisiyvn/projects/kltechnduo/CM12.1/out/target/common/obj/APPS/SystemUI_intermediates/classes-full-debug.jar' failed
make: *** [/home/kaisiyvn/projects/kltechnduo/CM12.1/out/target/common/obj/APPS/SystemUI_intermediates/classes-full-debug.jar] Error 41
I checked the log, and downloaded an old version to replace it, then complie it again....
Ok, completed successfully, I flashed my device with the out package, successfully and reboot, but, the device always cycling the bootanimation and became very hot, never entering the launcher.
At last I found there is an CM Official Nightly version for the kltechnduo on network, I downloaded it and flash it, it works well on my device.
Any body could tell me why I can't build an available package for kltechnduo?
Thank you very much~
Thank you very much~
Thank you very much~
^_^
Have same error on HTC One X with CM 12.1. Was your problem on Samsung solved? And how?
Thanks in advance.
Sent from my HTC One X using XDA Free mobile app
I have the same error on lg g2, see if someone can help us

Categories

Resources