“Multiple definition”, “first defined here” errors

The problem here is that you are including commands.c in commands.h before the function prototype. Therefore, the C pre-processor inserts the content of commands.c into commands.h before the function prototype. commands.c contains the function definition. As a result, the function definition ends up before than the function declaration causing the error. The content of commands.h … Read more

“The public type <> must be defined in its own file” error in Eclipse [duplicate]

If .java file contains top level (not nested) public class, it has to have the same name as that public class. So if you have class like public class A{…} it needs to be placed in A.java file. Because of that we can’t have two public classes in one .java file. If having two public classes would be allowed then, and lets say aside from public A class … Read more

Eclipse internal error while initializing Java tooling

Close all open projects and exit Eclipse. Now you can open Eclipse without getting the error. Start opening your projects one by one to find which one causes the problem. This is most likely because you deleted a Device profile inside the AVD manager. Or you can start working on a new workspace, (i.e. change … Read more

How to resolve the “ADB server didn’t ACK” error?

Try the following: Close Eclipse. Restart your phone. End adb.exe process in Task Manager (Windows). In Mac, force close in Activity Monitor. Issue kill and start command in \platform-tools\ C:\sdk\platform-tools>adb kill-server C:\sdk\platform-tools>adb start-server If it says something like ‘started successfully’, you are good.

No appenders could be found for logger(log4j)?

This Short introduction to log4j guide is a little bit old but still valid. That guide will give you some information about how to use loggers and appenders. Just to get you going you have two simple approaches you can take. First one is to just add this line to your main method: Second approach is to … Read more

Eclipse java debugging: source not found

Eclipse debugging works with the class actually loaded by the program. The symptoms you describe sounds like the class in question was not found in the project, but in a distribution jar without debug info found before the project you are working with. This can happen for several reasons but have a look at the location where the classes … Read more

Program “make” not found in PATH

You may try altering toolchain in case if for some reason you can’t use gcc. Open Properties for your project (by right clicking on your project name in the Project Explorer), then C/C++ Build > Tool Chain Editor. You can change the current builder there from GNU Make Builder to CDT Internal Builder or whatever compatible you have.

Ant “JAVA_HOME does not point to the JDK” – but it does

The real message is that Ant can’t find com.sun.tools.javac.Main. Which, together with the fact that the latest “Sun” (Oracle) JDK is 1.7.0_13 (or maybe _14, but definitely not the “_52” that your install dir indicates), makes me think that you’re not using a distribution that Ant recognizes. You can verify this by running jar tvf $JAVA_HOME/lib/tools.jar, and … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)