Re: Getting DUB to work with VS 2017

2017-05-22 Thread Enjoys Math via Digitalmars-d-learn

On Monday, 22 May 2017 at 06:44:27 UTC, Rainer Schuetze wrote:



On 22.05.2017 03:54, Enjoys Math wrote:
[...]

C:\Users\Gabe\AppData\Roaming\dub\packages\pyd-0.9.9\pyd\\infrastructure\windows\python27_digitalmars.lib+

user32.lib+
kernel32.lib/NOMAP/CO/NOI/DELEXE
LINK : fatal error LNK1181: cannot open input file 
'obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\source\led_ux_grammar.obj+'


Building 
C:\Users\Gabe\Dropbox\MyProjects\___SOUND_UNITED\LED_UX_Designer\lang\PEGparser\PEGparser.exe failed!
Details saved as 
"file://C:\Users\Gabe\Dropbox\MyProjects\___SOUND_UNITED\LED_UX_Designer\lang\PEGparser\.dub\obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\pegparser.buildlog.html"


== Build: 0 succeeded, 1 failed, 1 up-to-date, 0 
skipped ==


This looks like the wrong link.exe has been found in path. When 
building for Win32/x86 the default is to use optlink that is 
installed with dmd. The error message is issued by MS link 
instead.


I suspect the DMD installation folder is not set correctly 
(check Tools->Options->Projects and Solutions->Visual D 
Settings->DMD directories). Please also check the executable 
search paths below, they should include 
"$(DMDInstallDir)windows\bin". There was a bug in Visual D 
0.44.0 where a bad character sneaked into the path to DMD's bin 
folder.


> Opening any of the dub.json files with red X's opens them,
but then immediately crashes VS.

The red cross means it's not part of the build, so that's 
correct.


The crash is not ok. I can reproduce it, seems to happen due to 
a function not being implemented (which seems fine for other 
files).



Thank you.  That fixed it.  Simply removing the dub.json files 
from the project is a temporary solution to the crashes.  
However, the entire directory under pegged.examples is red X's.  
So to temp fix that, remove whole directory, add new filter 
(folder) 'examples', and add the example you need by copy / 
pasting text from another install of Pegged (so you can find it 
on disk), from the example grammar you need.  E.g. I added new 
item `c.d` under new folder `examples`, then copy / pasted the 
contents of `c.d` from a 2nd install of pegged.  The red X goes 
away, and I am able to use the grammar.


Alternatively, simply add the new file `c.d` to your 
project/source folder.


Re: Getting DUB to work with VS 2017

2017-05-22 Thread Rainer Schuetze via Digitalmars-d-learn



On 22.05.2017 03:54, Enjoys Math wrote:
[...]
C:\Users\Gabe\AppData\Roaming\dub\packages\pyd-0.9.9\pyd\\infrastructure\windows\python27_digitalmars.lib+ 


user32.lib+
kernel32.lib/NOMAP/CO/NOI/DELEXE
LINK : fatal error LNK1181: cannot open input file 
'obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\source\led_ux_grammar.obj+' 

Building 
C:\Users\Gabe\Dropbox\MyProjects\___SOUND_UNITED\LED_UX_Designer\lang\PEGparser\PEGparser.exe 
failed!
Details saved as 
"file://C:\Users\Gabe\Dropbox\MyProjects\___SOUND_UNITED\LED_UX_Designer\lang\PEGparser\.dub\obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\pegparser.buildlog.html" 


== Build: 0 succeeded, 1 failed, 1 up-to-date, 0 skipped ==


This looks like the wrong link.exe has been found in path. When building 
for Win32/x86 the default is to use optlink that is installed with dmd. 
The error message is issued by MS link instead.


I suspect the DMD installation folder is not set correctly (check 
Tools->Options->Projects and Solutions->Visual D Settings->DMD 
directories). Please also check the executable search paths below, they 
should include "$(DMDInstallDir)windows\bin". There was a bug in Visual 
D 0.44.0 where a bad character sneaked into the path to DMD's bin folder.


> Opening any of the dub.json files with red X's opens them, but then 
immediately crashes VS.


The red cross means it's not part of the build, so that's correct.

The crash is not ok. I can reproduce it, seems to happen due to a 
function not being implemented (which seems fine for other files).


Re: Getting DUB to work with VS 2017

2017-05-21 Thread Enjoys Math via Digitalmars-d-learn

On Monday, 22 May 2017 at 01:49:48 UTC, Enjoys Math wrote:

I did `dub generate visuald project_name`.

VS 2017 loads the .sln file except for red 'x's on the dub.json 
files.


My dub.json file looks like (if it matters):

{
"name": "pegparser",
"targetName": "PEGparser",
"authors": [
"Fruitful Approach"
],
"description": "A parser for LED UX Designer using pegged.",
"copyright": "Copyright 2017, fruitfulappro...@gmail.co",
"license": "proprietary",
"dependencies": {
"pegged": "~>0.4.2",
"pyd": "~>0.9.9",
}
}

Building gives errors although doing `dub build` at the command 
line works.


Shouldn't the build command be `dub build` instead of `$(CC) 
-c` ?


How do I make this work.  Otherwise, I will just make calls to 
a D app from python over the command line or something...


Build Errors:
---



-- Build started: Project: pegparser, Configuration: debug 
Win32 --
Building 
C:\Users\Gabe\Dropbox\MyProjects\___SOUND_UNITED\LED_UX_Designer\lang\PEGparser\PEGparser.exe...

Microsoft (R) Incremental Linker Version 14.10.25019.0
Copyright (C) Microsoft Corporation.  All rights reserved.

obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\source\led_ux_grammar.obj+
obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\source\main.obj+
obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\..\..\..\..\..\..\AppData\Roaming\dub\packages\pyd-0.9.9\pyd\infrastructure\deimos\python\abstract_.obj+
obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\..\..\..\..\..\..\AppData\Roaming\dub\packages\pyd-0.9.9\pyd\infrastructure\deimos\python\ast.obj+
obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\..\..\..\..\..\..\AppData\Roaming\dub\packages\pyd-0.9.9\pyd\infrastructure\deimos\python\boolobject.obj+
obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\..\..\..\..\..\..\AppData\Roaming\dub\packages\pyd-0.9.9\pyd\infrastructure\deimos\python\bufferobject.obj+
obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\..\..\..\..\..\..\AppData\Roaming\dub\packages\pyd-0.9.9\pyd\infrastructure\deimos\python\bytearrayobject.obj+
obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\..\..\..\..\..\..\AppData\Roaming\dub\packages\pyd-0.9.9\pyd\infrastructure\deimos\python\bytesobject.obj+
obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\..\..\..\..\..\..\AppData\Roaming\dub\packages\pyd-0.9.9\pyd\infrastructure\deimos\python\cellobject.obj+
obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\..\..\..\..\..\..\AppData\Roaming\dub\packages\pyd-0.9.9\pyd\infrastructure\deimos\python\ceval.obj+
obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\..\..\..\..\..\..\AppData\Roaming\dub\packages\pyd-0.9.9\pyd\infrastructure\deimos\python\classobject.obj+
obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\..\..\..\..\..\..\AppData\Roaming\dub\packages\pyd-0.9.9\pyd\infrastructure\deimos\python\cobject.obj+
obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\..\..\..\..\..\..\AppData\Roaming\dub\packages\pyd-0.9.9\pyd\infrastructure\deimos\python\code.obj+
obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\..\..\..\..\..\..\AppData\Roaming\dub\packages\pyd-0.9.9\pyd\infrastructure\deimos\python\codecs.obj+
obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\..\..\..\..\..\..\AppData\Roaming\dub\packages\pyd-0.9.9\pyd\infrastructure\deimos\python\compile.obj+
obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\..\..\..\..\..\..\AppData\Roaming\dub\packages\pyd-0.9.9\pyd\infrastructure\deimos\python\complexobject.obj+
obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\..\..\..\..\..\..\AppData\Roaming\dub\packages\pyd-0.9.9\pyd\infrastructure\deimos\python\cStringIO.obj+
obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\..\..\..\..\..\..\AppData\Roaming\dub\packages\pyd-0.9.9\pyd\infrastructure\deimos\python\datetime.obj+
obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\..\..\..\..\..\..\AppData\Roaming\dub\packages\pyd-0.9.9\pyd\infrastructure\deimos\python\descrobject.obj+
obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\..\..\..\..\..\..\AppData\Roaming\dub\packages\pyd-0.9.9\pyd\infrastructure\deimos\python\dictobject.obj+
obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\..\..\..\..\..\..\AppData\Roaming\dub\packages\pyd-0.9.9\pyd\infrastructure\deimos\python\enumobject.obj+
obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\..\..\..\..\..\..\AppData\Roaming\dub\packages\pyd-0.9.9\pyd\infrastructure\deimos\python\errcode.obj+
obj\debug\dummy\dummy\dummy\dummy\dummy\dummy\dummy\pegparser\..\..\..\..\..\..\..\AppData\Roaming\dub\packages\pyd-0.9.9\pyd\infrastructure\deimos\python\eval.obj+

Getting DUB to work with VS 2017

2017-05-21 Thread Enjoys Math via Digitalmars-d-learn

I did `dub generate visuald project_name`.

VS 2017 loads the .sln file except for red 'x's on the dub.json 
files.


My dub.json file looks like (if it matters):

{
"name": "pegparser",
"targetName": "PEGparser",
"authors": [
"Fruitful Approach"
],
"description": "A parser for LED UX Designer using pegged.",
"copyright": "Copyright 2017, fruitfulappro...@gmail.co",
"license": "proprietary",
"dependencies": {
"pegged": "~>0.4.2",
"pyd": "~>0.9.9",
}
}

Building gives errors although doing `dub build` at the command 
line works.


Shouldn't the build command be `dub build` instead of `$(CC) -c` ?

How do I make this work.  Otherwise, I will just make calls to a 
D app from python over the command line or something...