How to compile OpenCV on Windows?

Windows Vista CLASSPATH or PATH setting error while using JGrasp IDE to compile C++?

  • hi I am using JGrasp IDE to try out C++. I used JGrasp before for Java. It does not have any problem when I used XP. I started to have this problem when I ported JGrasp to my Vista 64b. After I installed JGrasp on Vista, it couldn't compile Java. It has problem with finding the PATH to JavaC command. This is in 2009. I fixed it by changing the "CLASSPATH" on the Windows Environment Variables under the Advanced System Settings in Control panel. If I remembered it correctly. Google helped me with this. --------------------------------------… Now I am trying C++ with JGrasp. But It complained again about path, this is the error while compile: ----jGRASP exec: g++ -g -c C:\jg saves\C++\test1.cpp ----jGRASP wedge2 error: command "g++" not found. ---- This command must be in the current working directory ---- or on the current PATH to use this function. ---- PATH is ";C:\Program Files (x86)\PC Connectivity Solution\;C:\Xilinx\10.1\ISE\bin\nt64;C:… Files (x86)\CyberLink\Power2Go\;C:\Program Files\Java\jdk1.6.0_11\bin;C:\Program Files (x86)\QuickTime\QTSystem\". ----jGRASP: operation complete. ------------------------ It seems to be the same problem, but this time is the C++. The path is quite jumbled with many other commands.. while it is looking for g++ so I looked at the same Window Environment Variable I found that this time it is in "Path" not "ClassPath" So What should I type in to fix the path ? I don't think I have g++ installed.. do u need it installed first in vista ?? Is there a way to check g++ ? .. try compiling in prompt ? And what is the CLASSPATH and PATH anyway.. ? do they specifically define the Java and C++ ? your help would be appreciated thanks

  • Answer:

    I tried running a C file in JGrasp and I got the gcc error. I download BloodShed C++, which installs g++, and I then added the path to g++ to the Windows variable and JGrasp was able to compile C code. I would just scrape JGrasp and use Dev C++. You could also download the GNU C/C++ installation, but it's very hard to install. The PATH variable is where Windows looks to find programs called in the CLI (command line interface or 'command prompt'). It allows you to use 'java', 'javac', 'gcc', from anywhere in the command line interface. The CLASSPATH is where Java looks for the classes needed to compile a project. Say you want to use a class created by another programmer that's packed as a jar file. When you go to compile your code in the CLI you need to include the classpath tag so javac knows where to look for the other classes.

just_ken... at Yahoo! Answers Visit the source

Was this solution helpful to you?

Related Q & A:

Just Added Q & A:

Find solution

For every problem there is a solution! Proved by Solucija.

  • Got an issue and looking for advice?

  • Ask Solucija to search every corner of the Web for help.

  • Get workable solutions and helpful tips in a moment.

Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.