可以在Debian stable上编译一些源代码,但不能在Ubuntu 18.04上编译

时间:2018-06-14 17:47:42

标签: c++ gradle linker-errors

我和一位朋友已经开始针对有问题的人制作游戏。我们非常处于原型设计阶段。我们在https://github.com/beer119/KrydsOgBolle

处有一些代码

我坐在Debian上,编译源代码没问题。但是一旦我尝试在Ubuntu 16.04或Ubuntu 18.04上编译它,我们就会遇到链接问题。我不明白为什么。您能解释为什么我们会看到这个问题吗?

错误来自我正在测试它的Ubuntu VM:

beer@beer-VirtualBox:~/KrydsOgBolle$ gradle build

WARNING: An illegal reflective access operation has occurred

WARNING: Illegal reflective access by                 
org.gradle.internal.reflect.JavaMethod (file:/usr/share/gradle/lib/gradle- 
base-services-3.4.1.jar) to method java.lang.ClassLoader.getPackages()

WARNING: Please consider reporting this to the maintainers of 
org.gradle.internal.reflect.JavaMethod

WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations

WARNING: All illegal access operations will be denied in a future release

Starting a Gradle Daemon (subsequent builds will be faster)

> Starting D:compileMainExecutableMainCpp UP-TO-DATE

:linkMainExecutable


/home/beer/KrydsOgBolle/build/objs/main/mainCpp/3vi7vozcf16y2016khbg3f6rz/Game.o:(.bss+0x0): multiple definition of `Game::s_pInstance'

/home/beer/KrydsOgBolle/build/objs/main/mainCpp/azuvodu910wlwmrraram10dmu/Game.o:(.bss+0x0): first defined here

0 个答案:

没有答案