Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
New Developer
Posts: 2
Registered: ‎09-19-2008
My Device: Not Specified

Build Error "I/O Error: Cannot run program "javac""

Hi,

 

I just started to exploare BB JDE and got one simple demo from BB site, which is about "helloworld.jdw".

And I could build (F7) but it complains something like below when I tried build all(alt+F7).

 

 

Building helloworld
C:\Program Files\Research In Motion\BlackBerry JDE 4.5.0\bin\rapc.exe  -quiet import=..\lib\net_rim_api.jar codename=helloworld helloworld.rapc warnkey=0x52424200;0x52525400;0x52435200 "C:\Program Files\Research In Motion\BlackBerry JDE 4.5.0\helloworld\com\rim\samples\helloworld\HelloWorld.java"
I/O Error: Cannot run program "javac": CreateProcess error=2, The system cannot find the file specified
Error while building project

 

I hope there is somebody that can help me here.

Thank you.

 

 

Highlighted
Developer
Posts: 131
Registered: ‎08-13-2008
My Device: Not Specified

Re: Build Error "I/O Error: Cannot run program "javac""

[ Edited ]

Make sure you have environment variables set up.

Right click my computer > Properties > Advanced > Environment variables

Variable   Value

PATH      C:\Program Files\Java\jdk1.6.0_07\bin; //something like that, varies according to version of Java etc.

 

Also, it'd be better to search the forums for your problem before asking (you'll get an answer quicker too)

Message Edited by KeniF on 09-20-2008 01:01 AM
New Developer
Posts: 2
Registered: ‎09-19-2008
My Device: Not Specified

Re: Build Error "I/O Error: Cannot run program "javac""

Thank you for your help.

I will try to search the forum for my problem first before asking a question here.

By the way, I did what you suggested. But, I am getting same error.

Anyway, thank you again for your reply.

BlackBerry Development Advisor
Posts: 15,696
Registered: ‎07-09-2008
My Device: BlackBerry PRIV
My Carrier: Bell

Re: Build Error "I/O Error: Cannot run program "javac""

Please see the following link.

 

Support - I/O Error: CreateProcess
Article Number: DB-00081

http://www.blackberry.com/knowledgecenterpublic/livelink.exe/fetch/2000/348583/800901/Support_-_I_O_...

Mark Sohm
BlackBerry Development Advisor

Please refrain from posting new questions in solved threads.
Problem solved? Click the Accept As Solution button.
Found a bug? Report it using Issue Tracker
New Developer
Posts: 45
Registered: ‎03-04-2009
My Device: Not Specified

Re: Build Error "I/O Error: Cannot run program "javac""

Hi,

 

I m facing the same problem as jwpark.

 

Building HelloWorldProjectFile
C:\BlackBerry JDE 4.3.0\bin\rapc.exe  -quiet import=..\lib\net_rim_api.jar codename=HelloWorldProjectFolder\HelloWorldProjectFile HelloWorldProjectFolder\HelloWorldProjectFile.rapc warnkey=0x52424200;0x52525400;0x52435200 "C:\BlackBerry JDE 4.3.0\subash\HelloWorldProjectFolder\HelloWorld.java" "C:\BlackBerry JDE 4.3.0\subash\HelloWorldProjectFolder\helloworld_jde.png"
I/O Error: Cannot run program "javac": CreateProcess error=2, The system cannot find the file specified
Error while building project

I did all the setps as mentioned in this post as well as other posts , but still getting the same error

 

These are the settings on my system

 

I use BB JDE 4.3.0

 

JAVA Version - jdk1.6.0_12

 

PATH - =C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Program Files\Mi
crosoft SQL Server\80\Tools\Binn\;C:\Program Files\Microsoft SQL Server\90\Tools
\binn\;C:\Program Files\Microsoft SQL Server\90\DTS\Binn\;C:\Program Files\Micro
soft SQL Server\90\Tools\Binn\VSShell\Common7\IDE\;C:\Program Files\Microsoft Vi
sual Studio 8\Common7\IDE\PrivateAssemblies\;C:\Program Files\Common Files\Roxio
 Shared\DLLShared\;C:\Program Files\Common Files\Roxio Shared\9.0\DLLShared\;C:\
Java\jdk1.6.0_12\bin\;C:\Java\jre6\bin\

 

JAVA_HOME - C:\Java\jdk1.6.0_12

 

JDE_HOME - C:\BlackBerry JDE 4.3.0

 

CLASSPATH - C:\Java\jdk1.6.0_12\bin

 

When i type javac in the cmd prompt, Im able to see the options. But the BB JDE keeps throwing the above error again and again. Is there anything else i have to do ? Please help.

 

Thanks

 

BlackBerry Development Advisor
Posts: 15,696
Registered: ‎07-09-2008
My Device: BlackBerry PRIV
My Carrier: Bell

Re: Build Error "I/O Error: Cannot run program "javac""

Move C:\Java\jdk1.6.0_12\bin\ to the start of your PATH environment variable and remove the JRE directory from the end.
Mark Sohm
BlackBerry Development Advisor

Please refrain from posting new questions in solved threads.
Problem solved? Click the Accept As Solution button.
Found a bug? Report it using Issue Tracker
New Developer
Posts: 2
Registered: ‎08-29-2009
My Device: Not Specified

Re: Build Error "I/O Error: Cannot run program "javac""

m having the same problem yet....  set all the var accordingly but though... pls any one guide me on this...

 

 CLASSPATH - C:\Program Files\Java\jdk1.6.0_10\bin

 JAVA_HOME - C:\Program Files\Java\jdk1.6.0_10

JDE_HOME -- C:\Program Files\Research In Motion\BlackBerry JDE 5.0.0

PATH   --- C:\Program Files\Java\jdk1.6.0_10\bin

 

 

m i missing something !!

Developer
Posts: 984
Registered: ‎02-10-2009
My Device: Not Specified

Re: Build Error "I/O Error: Cannot run program "javac""

About Path 

----------------

For setting your system environment variable try like:

 

1. Control Panel -> System -> Environment variables -> click path in the system variables ->

    Edit

2. Now add the following in the "Variable value"   each separated with a semicolon

a) C:\Program Files\Java\jdk1.6.0_10\bin

b) C:\Program Files\Java\jre1.6.0_10\bin

c) C:\Program Files\Research In Motion\BlackBerry JDE 4.6.0\bin

3. Restart your PC.

 

 

You can verify if the javac path is set properly by open a DOS command prompt and type "javac".

 

 

Regards

Bikas

New Contributor
Posts: 3
Registered: ‎06-15-2011
My Device: Torch 9800
My Carrier: Bell

Re: Build Error "I/O Error: Cannot run program "javac""

[ Edited ]

FOUND A  SOLUTION at this link:

http://www.apl.jhu.edu/~hall/java/beginner/settingup.html

Lots of places tell you how to set the environment variables, but still I couldn't get it working. Now I finally got it after reading from the above link.

 

Basically you just have to set the environment variable so that javac can be directly accessed from folders outside the Java bin folder. 

 

And dont forget to close and restart BB JDE!

New Member
Posts: 1
Registered: ‎05-02-2013
My Device: Blackberry Curve 9360
My Carrier: Telefonica Venezuela

Re: Build Error "I/O Error: Cannot run program "javac""

Today got same problem.

 

Solution:

 

1.- Reinstall without spaces at path C:\BlackBerry_JDE_5.0.0

 

2.-Add System Variables:

JAVA_HOME = C:\jdk1.6.0_45

PATH = ....;C:\jdk1.6.0_45\bin;

 

Now work!!!!

 

Best Regards.