www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - import problem

reply "Lloyd Dupont" <ld-REMOVE galador.net> writes:
so I copied the Entice generated UI code in Visual D, and tried to compile.
I got 1 error:
Error    1    Error: module all is in file 'dfl\all.d' which cannot be read 
C:\Dev\DTest\DTest1\myform.d    7

On
import dfl.all;

For info I do have dfl.all in
C:\D\dmd2\windows\import\dfl 
May 19 2011
next sibling parent Matthew Ong <ongbp yahoo.com> writes:
On 5/19/2011 9:49 PM, Lloyd Dupont wrote:
 so I copied the Entice generated UI code in Visual D, and tried to compile.
 I got 1 error:
 Error 1 Error: module all is in file 'dfl\all.d' which cannot be read
 C:\Dev\DTest\DTest1\myform.d 7

 On
 import dfl.all;

 For info I do have dfl.all in
 C:\D\dmd2\windows\import\dfl

multiple files. -- Matthew Ong email: ongbp yahoo.com
May 19 2011
prev sibling parent reply Jesse Phillips <jessekphillips+D gmail.com> writes:
Lloyd Dupont Wrote:

 so I copied the Entice generated UI code in Visual D, and tried to compile.
 I got 1 error:
 Error    1    Error: module all is in file 'dfl\all.d' which cannot be read 
 C:\Dev\DTest\DTest1\myform.d    7
 
 On
 import dfl.all;
 
 For info I do have dfl.all in
 C:\D\dmd2\windows\import\dfl 
 

dmd myform.d -IC:\D\dmd2\windows\import\dfl
May 19 2011
parent reply Jesse Phillips <jessekphillips+D gmail.com> writes:
Jesse Phillips Wrote:

 Lloyd Dupont Wrote:
 
 so I copied the Entice generated UI code in Visual D, and tried to compile.
 I got 1 error:
 Error    1    Error: module all is in file 'dfl\all.d' which cannot be read 
 C:\Dev\DTest\DTest1\myform.d    7
 
 On
 import dfl.all;
 
 For info I do have dfl.all in
 C:\D\dmd2\windows\import\dfl 
 

dmd myform.d -IC:\D\dmd2\windows\import\dfl

Forgot DFL requires some more switches, maybe using dfl.exe to compile: http://wiki.dprogramming.com/Dfl/Tutorial The simplest way to compile with DFL is to use the dfl.exe command. Simply open a command prompt, cd to the directory containing the source files you wish to compile, and type dfl sourcefile.d you can add -gui switch and any other source files to include in the compilation Finally, the least appealing choice is to call the compiler directly. You must follow strict rules when doing this or things may behave erratically and even crash. The details can be found on the old setup instructions page; look for the "use DMD directly" section.
May 19 2011
parent "Lloyd Dupont" <ld-REMOVE galador.net> writes:
Well.. I'm using Visual D, so I have to find out how to set up the compiler!

At any rates, I gave up on DFL, as it requires to overwrite the runtime 
library.
I don't feel quite ready for it....
It'll be OK if I had any clue as to which file are going to be overwritten.. 
but now I'm confused.. why does the compiler need my D file for when it has 
the .lib file?

Anyway, I'm struggling with DGui now.
I added the import, to the source of DGui. Should be enough, right?
No!
I have this error when trying to compile (still with Visual D)
Error    1    Error 42: Symbol Undefined _D4dgui3all12__ModuleInfoZ 
C:\Dev\DTest\DTest1\

for info here is the build log:
==============================================
Building Debug\DTest1.exe

Command Line

set PATH=C:\D\dmd2\windows\bin;C:\Program Files (x86)\Microsoft 
SDKs\Windows\v7.0A\\bin;%PATH%
set DMD_LIB=;C:\D\dgui\lib
dmd -g -debug -X -Xf"Debug\DTest1.json" -IC:\D\dgui -of"Debug\DTest1.exe_cv" 
 -deps="Debug\DTest1.dep" -map "Debug\DTest1.map" -L/NOMAP hello.d
if errorlevel 1 goto reportError
if not exist "Debug\DTest1.exe_cv" (echo "Debug\DTest1.exe_cv" not created! 
&& goto reportError)
echo Converting debug information...
"C:\Program Files (x86)\VisualD\cv2pdb\cv2pdb.exe" -D2 "Debug\DTest1.exe_cv" 
"Debug\DTest1.exe"
if errorlevel 1 goto reportError
if not exist "Debug\DTest1.exe" (echo "Debug\DTest1.exe" not created! && 
goto reportError)

goto noError

:reportError
echo Building Debug\DTest1.exe failed!

:noError
Output

OPTLINK (R) for Win32  Release 8.00.12
Copyright (C) Digital Mars 1989-2010  All rights reserved.
http://www.digitalmars.com/ctg/optlink.html
Debug\DTest1.obj(DTest1)
Error 42: Symbol Undefined _D4dgui3all12__ModuleInfoZ
--- errorlevel 1
Building Debug\DTest1.exe failed!
===============================================


"Jesse Phillips"  wrote in message news:ir3pl3$1df4$1 digitalmars.com...

Jesse Phillips Wrote:

 Lloyd Dupont Wrote:

 so I copied the Entice generated UI code in Visual D, and tried to 
 compile.
 I got 1 error:
 Error    1    Error: module all is in file 'dfl\all.d' which cannot be 
 read
 C:\Dev\DTest\DTest1\myform.d    7

 On
 import dfl.all;

 For info I do have dfl.all in
 C:\D\dmd2\windows\import\dfl

dmd myform.d -IC:\D\dmd2\windows\import\dfl

Forgot DFL requires some more switches, maybe using dfl.exe to compile: http://wiki.dprogramming.com/Dfl/Tutorial The simplest way to compile with DFL is to use the dfl.exe command. Simply open a command prompt, cd to the directory containing the source files you wish to compile, and type dfl sourcefile.d you can add -gui switch and any other source files to include in the compilation Finally, the least appealing choice is to call the compiler directly. You must follow strict rules when doing this or things may behave erratically and even crash. The details can be found on the old setup instructions page; look for the "use DMD directly" section.
May 20 2011