On Sunday, 8 October 2017 at 07:51:12 UTC, Nicholas Wilson wrote:
On Saturday, 7 October 2017 at 10:34:15 UTC, kerdemdemir wrote:
do you set "-mdcompute-targets=cuda-xxx" in the dflags for
your dub.json for your project?
I have added now after your comment.
But it seems it didn't changed anything.
Here is the dub.json file I have:
{
"name": "dsharpear",
"authors": [
"Erdem"
],
"dflags" : ["-mdcompute-targets=cuda-210" ,"-oq", "-betterC"],
"dependencies": {
"dcompute": ">=0.0.0-alpha0 <0.1.0"
},
"description": "Beamforming with D ",
"copyright": "Copyright © 2017, Erdem",
"license": "proprietary"
}
And running "dub build --compiler=D:\LDCDownload\bin\ldc2.exe
--force" fails with:
Performing "debug" build using D:\LDCDownload\bin\ldc2.exe for
x86.
derelict-util 2.1.0: building configuration "library"...
derelict-cl 2.0.0: building configuration "library"...
derelict-cuda 2.0.1: building configuration "library"...
..\..\..\..\..\AppData\Roaming\dub\packages\derelict-cuda-2.0.1\derelict-cuda\source\derelict\cuda\runtimeapi.d(816,5):
Deprecation: constructor derelict.cuda.runtimeapi.dim3.this
all parameters have default arguments, but structs cannot have
default constructors.
dcompute 0.0.0-alpha0: building configuration "library"...
Targeting 'i686-pc-windows-msvc' (CPU 'pentium4' with features
'')
Building type: real
Building type: uint
Building type: char
Building type: ubyte
Building type: ulong
Building type: int
Building type: double
Building type: long
Building type: ushort
Building type: wchar
Building type: byte
Building type: short
Building type: float
Building type: dchar
..\..\..\..\..\AppData\Roaming\dub\packages\dcompute-0.0.0-alpha0\dcompute\source\dcompute\std\package.d(6,5):
Error: static assert "Need to use a DCompute enabled compiler
See https://github.com/thewilsonator/ldc/tree/dcompute"
D:\LDCDownload\bin\ldc2.exe failed with exit code 1.
You are using an old DCompute: that message was changed in
https://github.com/libmir/dcompute/commit/cf1420d5377c48f9132f1a9a0f8f06ebb46a6433#diff-b0637c2cde07f2ec8f77f9e3d379fff7
I'm not quite sure how the dub version specs work but I believe
"dcompute": "~>0.0.0" should work, or you can force it to use
master.
I'm still not sure why it fails with that error though, are you
using an old LDC as well? 1.4.0 should work.
I changed my dependency setting in dub file to "dcompute":
"~>0.0.0" but still getting the same error message. By the way I
am sure my LDC version is good because I can build DCompute
source code with same LDC version.