Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Novice
652 Views

Error: Could not find or load main class com.intel.bts.BtsApp

I'm trying to run the board test system for Stratix 10 MX development kit in CentOS 7.7 and hit to the error below

Error: Could not find or load main class com.intel.bts.BtsApp

 

Is there anyone know how to fix it?

Thanks,

0 Kudos
8 Replies
Highlighted
534 Views

Hello

 

Welcome to INTEL forum. Based on my understanding. CentOS 7. version is not an officially support OS for Quartus. An unsupported platform means that some things may work, but others not, and we won't put any resources into debugging or diagnosing. We recommended to use the right OS for Quartus. For more details refer the below link, https://www.intel.com/content/www/us/en/programmable/support/support-resources/download/os-support.h...

0 Kudos
Highlighted
Novice
534 Views

Thank for quick reply.

I believed that it wasn't Quartus problem, but the Java software bts.jar. I run bts.jar in Ubuntu 18.04 at got the same problem

Command: java -jar bts.jar

Error: Could not find or load main class com.intel.bts.BtsApp

Caused by: java.lang.NoClassDefFoundError: javafx/application/Application

 

I wonder if anyone got this problem before. Thanks.

0 Kudos
Highlighted
534 Views

Hi, could you help check again your .class file name for your program. The compiler will generate the .class file with the exact same name given to the Java class in the program. You can refer to this link https://www.baeldung.com/java-could-not-find-load-main-class

0 Kudos
Highlighted
Employee
529 Views

I have hit the same problem with the Stratix10 DX board test system (BTS) files.  I'm running Ubuntu and I see the same same error: "Error: Could not find or load main class com.intel.bts.BtsApp" running any of the *.sh scripts in the board_test_system subdirectory of the devkit's examples.

This is the default version of the bts launcher:

#!/bin/sh
if [ "$QUARTUS_ROOTDIR" == "" ]; then
export QUARTUS_ROOTDIR=/tools/acds/15.1.2/current.linux/linux64/quartus
echo "Use default QUARTUS_ROOTDIR: $QUARTUS_ROOTDIR"
fi
export PATH=$QUARTUS_ROOTDIR/linux64/jre64/bin:$PATH
java -Xmx256m -jar bts.jar

I don't think the way that script determines QUARTUS_ROOTDIR is a general solution, but even when I 'fix it' for my installation the command: java -Xmx256m -jar bts.jar gives the same error above.

Any suggestions on how to fix or debug this?

0 Kudos
Highlighted
517 Views

I have the same problem, also running Ubuntu. No idea as to the solution as yet.

FWIW I found my BoardTestSystem.sh file was also slightly broken in that it seemed to have the wrong line endings.

0 Kudos
Highlighted
Beginner
380 Views

While executing, when JVM does not find a .class file with the specified name then a run time error occurs saying “Could not found or load main class”. The reason why this happens is mostly due to:

  • Wrong Class Name
  • Invalid Classpath

Main class could not be found when there is typo or wrong syntax in the fully qualified java class name or it does not exist in the provided classpath. You must ensure that you add the location of your .class file to your classpath. So, if its in the current folder, add . to your classpath. Note that the Windows classpath separator is a semi-colon( . If you want to execute the main() method in MainClass, you must use the full class name, including package name, in the java command.

 

0 Kudos
Highlighted
New Contributor I
147 Views

This problem still persist in Quartus Prime Pro 20.2.

The BoardTestSystem.sh supplied with the cyclone-10-gx-kit-ocllateral.zip seems to be created with Quartus 15.1. Maybe it should have been updated?

It looks like the class in question is embedded in the bts.jar file:

Nikolay_Rognlien_0-1604924624797.png

 

Why is it not recognized when running the Java environment supplied with the Quartus installation?

Are there any options or switches that can be used with the java command to point to where the class is located?

 

 

0 Kudos
Highlighted
Beginner
91 Views

Did anybody make any progress on this issue.

I am running Quartus Prime Pro 20.2 as well on a Ubuntu 18.04 LTS and I am facing the same problem

0 Kudos