Any 3D Game or Engine with examples/demos which just work (compile&run) out of the box on linux ?

Prokop Hapala prokophapala at gmail.com
Fri Oct 18 05:52:19 UTC 2019


Already >1 year I consider to move from C++ to Dlang or to Rust 
in my hobby game development (mostly based on physical 
simulations 
https://github.com/ProkopHapala/SimpleSimulationEngine). I 
probably prefer Dlang because it compiles much faster, and I can 
copy&paste C/C++ code to it without much changes.

But I cannot figure out how to jumpstart. The barrier is to 
configure environment/libraries.

Up to now I was able to compile just "First Triangle example" 
(Not sure from where I copyied it)
https://www.dropbox.com/sh/myem3g69qjyo58v/AABZuvwuRDpnskhEC4AAK5AVa?dl=0

but when I tried to clone from github some more sophisticated 
tutorials or demos it never works. Either it is Windows-only 
(Visual Studio .snl, no dub; 
https://github.com/Ingrater/Spacecraft), or there are some 
dependencies on old versions of libraries, which I don't know how 
to upgrade. Or it has some other dependecies which documentation 
does not explain how to configure on linux.

============================================================
These are some cases I tried (and problems I had):
============================================================

#### d-gamedev-team/opengl-tutorials 
(https://github.com/d-gamedev-team/opengl-tutorials)

opengl-tutorials/ports/opengl-tutorial.org/$ dub
Failed to find any versions for package glad-drey, referenced by 
opengl-tutorial.org ~master

opengl-tutorials/ports/opengl-tutorial.org/tutorials/02_triangle$ 
dub
Failed to find any versions for package glamour-drey, referenced 
by gltut-utility >=0.0.0 
@/home/prokop/git_SW/_Dlang/opengl-tutorials/utility


#### kiith-sa/d-gl-tutorial 
(https://github.com/kiith-sa/d-gl-tutorial)

(dmd-2.088.0)prokop at prokop-Lenovo-ideapad-Y700-15ISK:~/git_SW/_Dlang/d-gl-tutorial$ ./compile.sh
./DerelictUtil-master/source/derelict/util/sharedlib.d(40): 
Error: module linux is in file 'std/c/linux/linux.d' which cannot 
be read
import path[0] = ./DerelictGL3-master/source/
import path[1] = ./DerelictSDL2-master/source/
import path[2] = ./DerelictUtil-master/source/
import path[3] = .
import path[4] = 
/home/prokop/dlang/dmd-2.088.0/linux/bin64/../../src/phobos
import path[5] = 
/home/prokop/dlang/dmd-2.088.0/linux/bin64/../../src/druntime/import
Failed: ["/home/prokop/dlang/dmd-2.088.0/linux/bin64/dmd", 
"-I./DerelictGL3-master/source/", 
"-I./DerelictSDL2-master/source/", 
"-I./DerelictUtil-master/source/", "-v", "-o-", "triangle.d", 
"-I."]


#### Dagon (https://github.com/gecko0307/dagon)

... it compiles and produce 'libdagon.a', but what to do with it? 
there are not demos/examples

#### dagon-demo (https://github.com/gecko0307/dagon-demo)

Linking...
Copying files for dagon...
Invalid source/import path: 
/home/prokop/git_SW/_Dlang/dagon-demo/shaders
Running ./dagondemo
Error: Nuklear library is not found. Please, install Nuklear.
Program exited with code 1
... Almost there, but still I don't know how to make it run

#### dmech (https://github.com/gecko0307/dmech)

Target is a library. Skipping execution.

#### dmech/demos (https://github.com/gecko0307/dmech)

dlib 0.12.2: building configuration "library"...
../../../../.dub/packages/dlib-0.12.2/dlib/dlib/core/stream.d(228,16): Error: module string is in file 'std/c/string.d' which cannot be read
import path[0] = ../../../../.dub/packages/dlib-0.12.2/dlib
import path[1] = 
/home/prokop/dlang/dmd-2.088.0/linux/bin64/../../src/phobos
import path[2] = 
/home/prokop/dlang/dmd-2.088.0/linux/bin64/../../src/druntime/import
/home/prokop/dlang/dmd-2.088.0/linux/bin64/dmd failed with exit 
code 1.

#### Dash (https://github.com/Circular-Studios/Dash)

Running pre-build commands...
cp: cannot create regular file '/usr/lib/libsoloud_x86.so': 
Permission denied
source/dash/utility/data/yaml.d(4,15): Deprecation: module yaml 
is deprecated - Import dyaml instead
../../../.dub/packages/vibe-d-0.7.33/vibe-d/source/vibe/core/log.d(554,21): Error: Built-in hex string literals are obsolete, use std.conv.hexString!"EFBBBF" instead.
source/dash/utility/input/input.d(7,8): Deprecation: module yaml 
is deprecated - Import dyaml instead
source/dash/core/gameobject.d(7,8): Deprecation: module yaml is 
deprecated - Import dyaml instead
source/dash/components/assets.d(10,8): Deprecation: module yaml 
is deprecated - Import dyaml instead
source/dash/components/material.d(7,8): Deprecation: module yaml 
is deprecated - Import dyaml instead
source/dash/components/mesh.d(8,19): Error: module stream is in 
file 'std/stream.d' which cannot be read

#### Sample-Dash-Game 
(https://github.com/Circular-Studios/Sample-Dash-Game)

logger 0.3.3: building configuration "library"...
Error: module std.experimental.logger.core from file 
../../../.dub/packages/logger-0.3.3/logger/std/experimental/logger/core.d is specified twice on the command line
Error: module std.experimental.logger.filelogger from file 
../../../.dub/packages/logger-0.3.3/logger/std/experimental/logger/filelogger.d is specified twice on the command line
Error: module std.experimental.logger.multilogger from file 
../../../.dub/packages/logger-0.3.3/logger/std/experimental/logger/multilogger.d is specified twice on the command line
Error: module std.experimental.logger.nulllogger from file 
../../../.dub/packages/logger-0.3.3/logger/std/experimental/logger/nulllogger.d is specified twice on the command line
../../../.dub/packages/logger-0.3.3/logger/std/experimental/logger/package.d(1,1): Error: module std.experimental.logger from file ../../../.dub/packages/logger-0.3.3/logger/std/experimental/logger/package.d conflicts with package name logger
/home/prokop/dlang/dmd-2.088.0/linux/bin64/dmd failed with exit 
code 1.



More information about the Digitalmars-d-learn mailing list