我正在尝试在ubuntu tegra(ARM)板上运行静态链接的hello world程序,但libc中的函数似乎会产生分段错误。
public interface DemoMe{
public void doSomething();
}
public class MainClass implements demoMe {
public void doSomething(){
System.out.println("Something was done ");
}
}
public class AnotherClass {
private final DemoMe demoVariable;
public void useMe(){
demoVariable.doSomething();
}
}
动态链接时,没有任何问题。
更多细节:
Program received signal SIGSEGV, Segmentation fault.
0x00039a1a in _dl_get_origin ()
(gdb) bt
#0 0x00039a1a in _dl_get_origin ()
#1 0x0001abaa in _dl_non_dynamic_init ()
#2 0x0001b5d8 in __libc_init_first ()
#3 0x00008ae2 in __libc_start_main ()
#4 0x000088d4 in _start ()
有关如何解决此问题的任何指示?谢谢!