Hi, I am trying to compile a machine code out of a java source code by using gcj, but I run into this error message that I could not comprehend.
#gcj --main=updateRoom updateRoom.java
/tmp/cckfECKN.o: In function `java::sql::Connection* updateRoom::fnMakeConn()':
updateRoom.java: (.text+0x1f8): undefined reference to `com::microsoft::jdbc::sqlserver::SQLServerDriver::class$'
updateRoom.java: (.text+0x20b): undefined reference to `com::microsoft::jdbc::sqlserver::SQLServerDriver::SQLServerDriver()'
collect2: ld returned 1 exit status
meanwhile, if I compile the code using
#javac updateRoom.java
did not give any error.
in the program I have
import java.io.*;
import java.sql.*;
***omitted***
public static Connection fnMakeConn() throws SQLException
{
Connection connection = null;
try
{
//loads MS SQL JDBC driver
DriverManager.registerDriver(new com.microsoft.jdbc.sqlserver.SQLServerDriver());
connection = DriverManager.getConnection(strUrl, strUserName, strUserPassword);
}
catch(Exception e)
{
}
return connection;
}
***omitted***
If someone happen to understand or have any idea on why/what the error means, please kindly point me to the proper direction