www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - arsd errors on windows

reply Greatsam4sure <greatsam4sure yahoo.com> writes:
from my project root directory


dub add arsd-official

This is added to dub.json

"arsd-official": "~>4.0.3"

just run the project gives


Fetching arsd-official 4.0.3 (getting selected version)...
Performing "debug" build using C:\D\dmd2\windows\bin\dmd.exe for 
x86_64.
arsd-official:cgi 4.0.3: building configuration 
"embedded_httpd"...
..\..\AppData\Local\dub\packages\arsd-official-4.0.3\arsd-off
cial\cgi.d(5828,3): Warning: statement is not reachable
C:\D\dmd2\windows\bin\dmd.exe failed with exit code 1.



import arsd.simpledisplay : SimpleWindow;

run the project gives



Performing "debug" build using C:\D\dmd2\windows\bin\dmd.exe for 
x86_64.
arsd-official:cgi 4.0.3: building configuration 
"embedded_httpd"...
..\..\AppData\Local\dub\packages\arsd-official-4.0.3\arsd-off
cial\cgi.d(5828,3): Warning: statement is not reachable
C:\D\dmd2\windows\bin\dmd.exe failed with exit code 1.

Enter the following code get the same error

SimpleWindow window = new SimpleWindow;
window.eventLoop(0);

what is the way out. I am in need of a gui in D for Window.Gtkd 
and dlangui are not options for me. it should be easily 
customization
Oct 16 2019
next sibling parent reply Dennis <dkorpel gmail.com> writes:
On Thursday, 17 October 2019 at 04:05:40 UTC, Greatsam4sure wrote:
 what is the way out.
I made a pull request fixing it: https://github.com/adamdruppe/arsd/pull/222 In the mean time, you can add the subpackage "arsd-official:simpledisplay" as a depdendency instead so cgi.d won't be included (assuming you don't need it).
Oct 17 2019
next sibling parent GreatSam4sure <greatsam4sure gmail.com> writes:
On Thursday, 17 October 2019 at 08:57:06 UTC, Dennis wrote:
 On Thursday, 17 October 2019 at 04:05:40 UTC, Greatsam4sure 
 wrote:
 what is the way out.
I made a pull request fixing it: https://github.com/adamdruppe/arsd/pull/222 In the mean time, you can add the subpackage "arsd-official:simpledisplay" as a depdendency instead so cgi.d won't be included (assuming you don't need it).
Thanks, I will try it out.
Oct 17 2019
prev sibling parent Greatsam4sure <greatsam4sure yahoo.com> writes:
On Thursday, 17 October 2019 at 08:57:06 UTC, Dennis wrote:
 On Thursday, 17 October 2019 at 04:05:40 UTC, Greatsam4sure 
 wrote:
 what is the way out.
I made a pull request fixing it: https://github.com/adamdruppe/arsd/pull/222 In the mean time, you can add the subpackage "arsd-official:simpledisplay" as a depdendency instead so cgi.d won't be included (assuming you don't need it).
this is the error Failed to get versions for package arsd-official:simpledisplay on provider registry at https://code.dlang.org/ (fallbacks registry at https://code-mirror.dlang.io/, registry at https://dub-registry.herokuapp.com/): (1): Error: Got .arsd-official:simpledisplay of type undefined, expected object. Could not find package 'arsd-official:simpledisplay'.
Oct 17 2019
prev sibling next sibling parent reply Adam D. Ruppe <destructionator gmail.com> writes:
On Thursday, 17 October 2019 at 04:05:40 UTC, Greatsam4sure wrote:
 Warning: statement is not reachable
ugh dub insists on this stupid warning as error nonsense and the warnings suck so they slip through me sometimes.
Oct 17 2019
parent reply Dennis <dkorpel gmail.com> writes:
On Thursday, 17 October 2019 at 11:35:26 UTC, Adam D. Ruppe wrote:
 ugh dub insists on this stupid warning as error nonsense and 
 the warnings suck so they slip through me sometimes.
You can put "buildRequirements": "allowWarnings" in your dub.json. (buildRequirements "allowWarnings" in dub.sdl)
Oct 17 2019
parent reply Dennis <dkorpel gmail.com> writes:
On Thursday, 17 October 2019 at 12:06:49 UTC, Dennis wrote:
 You can put "buildRequirements": "allowWarnings" in your 
 dub.json.
Should be "buildRequirements": ["allowWarnings"]
Oct 17 2019
parent reply Greatsam4sure <greatsam4sure yahoo.com> writes:
On Thursday, 17 October 2019 at 12:10:21 UTC, Dennis wrote:
 On Thursday, 17 October 2019 at 12:06:49 UTC, Dennis wrote:
 You can put "buildRequirements": "allowWarnings" in your 
 dub.json.
Should be "buildRequirements": ["allowWarnings"]
the same error Performing "debug" build using C:\D\dmd2\windows\bin\dmd.exe for x86_64. arsd-official:cgi 4.0.3: building configuration "embedded_httpd"... ..\..\AppData\Local\dub\packages\arsd-official-4.0.3\arsd-off cial\cgi.d(5828,3): Warning: statement is not reachable C:\D\dmd2\windows\bin\dmd.exe failed with exit code 1.
Oct 17 2019
next sibling parent Adam D. Ruppe <destructionator gmail.com> writes:
On Thursday, 17 October 2019 at 20:17:53 UTC, Greatsam4sure wrote:
 arsd-official:cgi 4.0.3: building configuration
oops i forgot to push the new tag to git. It should update in a little while now.
Oct 17 2019
prev sibling parent Dennis <dkorpel gmail.com> writes:
On Thursday, 17 October 2019 at 20:17:53 UTC, Greatsam4sure wrote:
 the same error
That was meant for Adam to put in the dub package file of arsd, in your project it won't affect the compilation of the dependency. (Though you can still try adding it in your local download of arsd to quickly get rid of the error)
Oct 17 2019
prev sibling parent reply WhatMeWorry <kheaser gmail.com> writes:
Really stupid question here, but when I try to run the same 
command I get:

C:\Users\whatmeworry>dub add arsd-official
Unknown command: add

USAGE: dub [--version] [<command>] [<options...>] [-- 
[<application arguments...>]]
    . . .
DUB version 1.11.0, built on Oct  6 2018




I thought about dub init, but that still doesn't give me an 'add' 
command.

Looking at help screen in Dub, I see add-path, add-local, etc. 
but the documentation says "dub add arsd-official".
Oct 17 2019
parent Dennis <dkorpel gmail.com> writes:
On Thursday, 17 October 2019 at 21:32:34 UTC, WhatMeWorry wrote:
 DUB version 1.11.0, built on Oct  6 2018
`dub add` got added at the end of 2018 IIRC, so you need to upgrade Dub.
Oct 17 2019