how to configure android build path? - java

I've had to install java, eclipse and android on a new machine as my old one had a problem with the graphics card. i've downloaded some software and others i've dragged in from my old harddrive, which is now an external harddrive. when i import the project i was working on from my old machine eclipse cant resolve anything that is android eg Activity, WindowManager etc. i've added android\tools and platform-tools to my system's path. In Eclipse when i try to configure the project's build path i've noticed that in the libraries tab it states "unable to get system library for the project". the only thing i've done differently on this installation is use jdk1.7.0 opposed to jdk6 on the old machine. any ideas on how to resolve this?
thanks matt.

find default.properties,modify the default-version,then,modify the Jdk 1.7 to 1.6,try step by step.the reason maybe is the Compatibility。

Related

JDK directory is not set or invalid (unity)?

I am now creating a keystore for my game (in unity) but when I press the add key button, an error pops up
Java Development Kit (JDK) directory is not set or invalid. Please, fix it in Preferences -> External Tools
UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr) (at /Users/builduser/buildslave/unity/build/Modules/IMGUI/GUIUtility.cs:187)
I installed the JDK and checked the path of it in the terminal using the command /usr/libexec/java_home, then it shows me that the path of the JDK is /Library/Java/JavaVirtualMachines/jdk-14.0.1.jdk/Contents/Home.
I copy and paste it in the JDK path in unity but the error still pops up.
I actually checked the JavaVirtualMachines in my computer's library but there's nothing in it.
How can I solve this problem? Any help is greatly appreciated.
Actually I solve this problem by adding the modules (Android SDK & NDK Tools, OpenJDK) to my Unity Editor. Actually if you tick the Android build support module, it won't automatically help you to tick the two modules above.
This solved for me in Linux (don't know if the case happens in Windows)
chmod -R 777 ~/Unity
This command set all privileges for all files/directories/subdirectories for the user.
Getting the error of this topic, for curiosity I tried to run the "java" executable inside the directory
~/Unity/Hub/Editor/2021.3.1f1/Editor/Data/PlaybackEngines/AndroidPlayer/OpenJDK/bin/
And got:
bash: ./java: Permission Denied
This explains why set the privileges.
I had the same problem, another solution doesn't work for me!!
I just uninstalled and then installed back using the unity HUB and it's worked.
Click on the three dots and uninstall
then click on add to install back the desired module.
While installing don't forget to check android build support and its all subcategories.
Also, I think I had installed more than one version of unity, that could also be a problem.
Check your Unity installation path in my case
C:\Program Files\Unity\Hub\Editor\2019.4.13f1\Editor\Data\PlaybackEngines\AndroidPlayer
this AndroidPlayer folder in NDK, SDK, and OpenJDK these folders are important for APK file generation.
These files are not properly installed then these files copy for another unity version.
enter image description here
Only one version you have then re-download it.
Edit the environment variable like this path in your case path was different but make sour bin folder is important.
C:\Program Files\Unity\Hub\Editor\2019.4.13f1\Editor\Data\PlaybackEngines\AndroidPlayer\OpenJDK\bin
enter image description here
Solve the problem.
I solve the problem by changing the paths inside:
edit->preferences->external tools
To point to the correct version as I download a different version for the SDK, NDK and JDK when using the hub. This can be done by ticking the checkboxes.
As #Jelly Qwerty answered, installing android platform alone won't install jdk, sdk and ndk. What you got to do is:
Open Unity Hub
Go to "Installs"
Click on the 3 dots on the upper right corner of your unity installation and select "Add Modules" Unity Hub Settings 1
Expand "Android Build Support" and check "Android SDK & NDK Tools" and "OpenJDK". Unity Hub Settings 2
Once the tools are installed you should be able to build your apk.
Cheers
I unchecked and checked the box for "JDK installed with untity" in Preferences>Externals Tools.
A window popped up and it installed some files and it fixed my issue
In Unity hub navigate to your unity versions, in the desire version click the doted menu and select add modules, if you already have android support, it has other options to install the android skd, ndk, and open ndk
There is no 3 dots and there is no installing JDK, Gradle, SDK, or NDK.
I always get Gradle building errors when I install these components manually, although they are the compatible ones of my version.
I want to download them automatically by unity, but the options you are talking about don't exist.
enter image description here

Subclipse installation fails "Subversion native library not available" (Java HL)

I'm trying to setup a fresh installation of Eclipse Oxygen at work, and I'm running into this issue when trying to checkout any project.
Import -> Checkout Projects From SVN ->
I'm trying to migrate from an old Mars installation with the same plugins, so maybe it has something to do with two installations trying to share the same path (Or trying to search on their own path the configuration files). I was given the original installation "as is", so I don't really know how the configuration process went (And yeah, it works just fine).
Any idea?
Your problem is that when the native Subversion JavaHL DLL's are being loaded, they try to load all of their dependencies. This includes the OpenSSL DLL's (libeay32.dll and ssleay32.dll). These DLL's are included with JavaHL but it looks like you have some other version higher in the PATH. More importantly these are 32-bit DLL's and you are running in a 64-bit JVM and loading 64-bit JavaHL. So it cannot use them.
Maybe you can fix your PATH to get rid of these? If not, you probably have to run 32-bit Eclipse using a 32-bit JVM.
You can also ignore the error and install the SVNKit adapter and choose to use that in your preferences under Team > SVN.
Take a closer look at the errors on the screenshot. It seems that there is a problem with java.library.path or %PATH% environment variable.

Eclipse SDK Manager Not Showing up

I'm using Windows-7 64 bit and I have installed this(jdk-7u45-windows-x64) updated JDK in my system. My SDK was updated upto API level 18(Android 4.3).
When i click on SDK manager in the eclipse, it does not start. I tried open it directly with Administrator permission also. But it does not start. I had tried to set the variable path like these.
But I'm always getting the same error like this.
After I found that in my find_java.exe get the java path from windows\system32 as shown below .
How can I set the Java path to my installed java folder.
Need some one help to figure it out. For Reference look at this link also.
SDK manager not starting
While setting the environment variable try JAVA_HOME variable pointing the bin directory.
because the android checks the java.exe in particular path.
I am new to android,As long as i studied ,Android requires Java 1.5 or 1.6. You are using 1.7
Google does not add complete jdk 1.7 support to android system requirement(some api are exception) .. It does not mean that you should not have jdk 1.7. you should also have 1.6 jdk for compiler compilance. it is a better way to avoid using 1.7 jdk ,if u dont want jdk 1.7 features.
http://developer.android.com/sdk/index.html see the system requirements and even if u developed using 1.7...when you installing your app in real device .we may face signing issue.
you may use some jar file which targetting java 1.7. but android system runtime(dalvik jvm) does not know how to process those files which means dex tool wont process those files which belongs to 1.7 and it wont create classes.dex file..hope it will help somehow
From the error you have posted it seems the problem is only with the path settings.
Add the path upto the bin folder of your jdk - C:\Program Files\Java\jdk1.7.0_45\bin and restart the eclipse.
Please verify if your SDK Location in the Window->Preferences->Android points to the correct SDK path.
Download latest android bundle from http://developer.android.com/sdk/index.html.
and replace new sdk folder with old sdk folder from android bundle folder.
now it's may work.
Finally Reinstalled my OS and Installed JDK 1.6. Then I have added my updated SDK to my ADT. It works fine now.
I've had the same issue, and this solved it

I have just installed android SDK updates and now my projects are full of errors

I recently just installed downloaded and installed some updates in the android sdk to get access to some features and now when I have restarted eclipse all the projects have errors!!
Theres a small error at the start of package and the only resolutions it suggests is reconfigure build path, here is a picture of the carnage. Does anyone know how I can resolve this?
If java.util is an offending import, you haven't got your JRE configured properly or either the build or the IDE are in a kind of corrupted state. Since you already used the Clean command I'm going for a more complex issue.
Check your project's configuration and make sure you're not still referencing your old Java implementation. If by installing updates you mean that you downloaded a new version, installed it and then deleted the one you've been using so far, then the IDE might not be finding the JRE system library your project has currently configured.
Try right clicking your project > Build Path > Configure build path, then check if your current JRE system library is unbound. If so, you'll have to configure it again on the Libraries tab by using Add Library > JRE System Library.

How to use digitalpersona one touch sdk java edition in netbeans?

I downloaded digitalpersona free one touch sdk (1.6.1): java edition.
Installed the sdk and the java run time environment (RTE).
I would like to create my own user interface for fingerprint enrollment/verification using the sdk , however I dont know how to implement it in a java application in netbeans. Am relatively new to using netbeans and I have a project to do using fingerprint matching.
How do I use the package com.digitalpersona.onetouch.ui.swing.sample.Enrollment; and import com.digitalpersona.onetouch.*; ?
What do I need to import to the new java application for it to allow me to use the methods available in the sdk? Any dll or jar i need to call or add to the library?
Your guidance will be much appreciated.
Thank you.
Although this answer is 4 years late, but I hope it helps make this community more helpful.
After installing the SDK on your development machine (Windows), you should navigate to the directory you installed the SDK (in my case, it is C:/Program Files/DigitalPersona, open bin/java and verify that the dpotapi jar executable exists. If it does, then you note the path to this jar file as this is your class path.
To add it to Netbeans, click on Projects in your IDE, right click on Libraries then choose Add Jar/Folder and from the dialog that pops up navigate to the directory where you had earlier found the dpotapi.jar file, click on it, then Open, and you are good to go.

Categories

Resources