[Home]
[FAQ]
[News Groups]
[Search]
[Books]
[Buy CD]
Last update Mar 17, 2003
Frequently Asked Questions
Can I get it on CD?
CD now available!
It's very reasonably priced at $25 plus S&H.
Where's the debugger?
The
CD
version includes the DMC++ debugger.
Alternatively,
you can use any debugger that works with the Microsoft CodeView
format or linker .MAP format. These include the:
- Symantec debuggers
- Zortech debuggers
- Microsoft debuggers (Codeview, symdeb, windbg, VC++ debugger)
- Rational Systems debuggers
- Multiscope debuggers
Remember to compile with the -g option
(generate symbolic debug info)
and link with /co/ma.
Where's the IDDE?
The
CD
version includes the DMC++ Integrated Developing and
Debugging Environment (IDDE).
Alternatively, the Microemacs editor, included in the free download
version, is a fully capable and powerful text editor.
When I click on it, a window flashes and disappears?
This happens when the program is a console program.
Console programs are meant to be run from the command prompt.
Most of the non-IDDE Digital Mars programs are console programs.
A command prompt window can be created on XP by
clicking on [Start][Command Prompt].
Can I download the documentation in one zip file?
All the documentation comes on the
CD as html files,
as well as the Microsoft API documentation in Windows
Help format.
Is DOSX still available?
DOSX is now re-released as X32 for the Digital Mars compilers,
and is now available again! Download the
patch
for X32, and
X32
itself.
If you need the old Symantec or Zortech dos extender version,
and you have an original licensed copy of the Zortech or Symantec
compilers, copy these files:
lib\sdx.lod
lib\cx.obj
src\dos32\cx.asm
src\dos32\lib\x386.lib
into the same directories and then you can develop for DOSX
again.
Does the WDOSX (Wuschel's DOS eXtender) work with DMC?
Is the Zed editor still available?
Will the compiler run under DOS?
No. Although the compiler will build 16 bit DOS programs, the
compiler itself will only run under Win32.
The dos extended versions of
the tool executables are no longer included.
Symantec does offer a freely downloadable set of compilers
that run under DOS
here.
(This link appears to be broken.)
How do I specify other compiler flags to the IDDE?
To give 'other' flags (newer ones not on the
property pages) such as -Ab, use the
'defines' edit box and give the flags there. In such a case, you must
explicitely use -D for your defines. If you are only defining,
then -D is not required.
e.g. If you want to define 'NDEBUG' only, specify only 'NDEBUG'. If in
addition, you want to specify -Ab, you must write:
-Ab -DNDEBUG
Redefined type errors when including the socket header files
There are some name collisions by default when including the
socket header files. It reports about 5 redefined variable types,
fd_set being among them.
fd_set can also be found in types.h and unistd.h.
The solution is to #define _WIN32_WINNT=0x0400 in order to
force windows.h to include
winsock2.h, not winsock.h.
I'm getting a message about SCT3D32.DLL not installed
This can happen when creating an application using the AppExpress
feature of ProjectExpress [Project->New] in the IDDE.
Clicking "use AppExpress" followed by "finish", the message
in a window titled CTL3DV2 appears:
"This application uses SCT3D32.DLL, which has not been correctly
installed."
This message is generated by SCT3D32.DLL itself (a Microsoft supplied
DLL), and is produced when it is not residing in the system directory.
SCT3D32.DLL is in the \dm\bin directory. Copy it to your windows
system directory (which on NT is \winnt40\system32), and rename
the one in \dm\bin to SCT3D32.DLL.OLD.
This is the only known DLL with this problem.
How do I work with old CodeView?
The problem:
Compiling a test program like this,
sc -ms -0 -g -L/co/ma foo.c
and proceeding to load CodeView in "real" DOS produces the message:
CV0104 Warning: CodeView information for 'D:\FOO.EXE' is
newer than this version of CodeView
The version of codeview is 4.01 as supplied in the
MASM 6.11 package, dated from 1992.
Using /cvversion:4 to the linker produces the same result,
as well as using compiler option -g4.
Using masm to assemble an example program and linking using Microsoft Link
does work with codeview. Linking the same .obj file with optlink/cvversion:4
produces the same failure.
The solution:
Optlink runs cvpack when
generating cv4 info. This seems to be the cause of
the trouble: cv only gives the "info is newer
than this version of codeview" error when cvpack is
executed without any options. When optlink is given
the /nocvpack option, then run cvpack manually with
the minimal option, the debugger (cv) then reports
with symbolic names. For example:
sc -ms -0 -g -L/co/l/i/nocv foo.exe
cvpack /minimal foo.exe
and cv will work.
(Thanks to Jack Jay for tracking this down.)
I need an import library for a Windows system DLL
Consider the following program test.c:
#include <windows.h>
void main()
{
gethostbyname(0);
}
The function gethostbyname() is declared in \dm\include\win32\winsock.h,
and is exported from the Windows system dLL wsock32.dll. Compiling and
linking test.c produces:
E:>sc test
link test,,,user32+kernel32/noi;
OPTLINK (R) for Win32 Release 7.50B1
Copyright (C) Digital Mars 1989 - 2001 All Rights Reserved
test.obj(test)
Error 42: Symbol Undefined _gethostbyname@4
--- errorlevel 1
E:>
If implib is run over wsock32.dll to
create wsock32.lib, it still doesn't
link because the name in wsock32.dll is gethostbyname, not _gethostbyname@4.
The solution is to create a
module definition file
wsock32.def with the contents:
LIBRARY wsock32
EXETYPE NT
SUBSYSTEM WINDOWS
EXPORTS
_gethostbyname@4 = gethostbyname
This establishes a translation from one name to the other.
Add each of the exports needed.
Then run implib over it with:
implib wsock32.lib wsock32.def
and link with:
sc test.obj wsock32.lib
and it should then link successfully.
ClassExpress crashes reading resources created by VC++
The problem is in the .rc file. If the project has numbers (i.e.
63552, 10254, ...) in place of menu resource ID's (i.e. IDM_FILE_OPEN,
IDM_FILE_SAVE, ...) then ClassExpress will crash when looking at
"Control ID's in Class" under "Message Maps".
Replace the numbers with the correct resource ID defines
from "resource.h".
(Thanks to Andrew Corkan for tracking this down.)
IDDE sometimes can't find files, shows paths wrong?
I need winfax.h or some other new Win SDK header file.
Windows SDK updates can be downloaded from
sdkupdate
which includes winfax.h.
Resource Editor crashes under Windows ME?
How do I use DirectX with DMC?
You can get .lib files from MS DIRECTX SDK and
convert them to OMF format with COFF2OMF.
Then use the .h files from the same SDK.
If using only a limited set of DirectX functions,
it is possible to build a .lib from .DLL using the
implib.exe utility.
(Thanks to Nic Tiger.)
Why can't I create a workspace in the IDDE?
The menu items Environment->Workspace->New or
Environment->Workspace->Clone are always grayed in the installation.
The limit is 5 workspaces, and as delivered on the CD there
are already 5. To create a new workspace, delete one of the
existing ones first.
(Thanks to Frank Albe.)
When I run the compiler, it just flashes on the screen and disappears?
The free downloadable compiler is a console program. That means
it needs to be run from within a console window.
To start a console for Windows XP,
click on [Command Prompt] from the [start] menu.
The GUI version of the compiler comes
with the CD.
Where is the header file <iostream>?
iostream is part of STLport.
Do one of the following:
For more information, see \dm\stlport\readme.txt.
I get 'Symbol Undefined _WinMain@16'?
When linking a program as a GUI application, but having a main()
like a console application, results in the error message from
the linker:
link /NOI /DE /PACKF /XN /NT /ENTRY:WinMainCRTStartup /BAS:4194304 /A:512
@tst.LNK
Error: c:\dm\lib\SNN.lib(winstart) : Symbol Undefined _WinMain@16
Errors: 1 Warnings: 0
Build failed
If using the IDDE, this is corrected by selecting [Console]
under [Target Type] in the first [Tab] of [Project Settings].
If using a module definition (.def) file, these lines should
appear in it:
EXETYPE NT
SUBSYSTEM CONSOLE
Do not use /ENTRY:WinMainCRTStartup in a command to the linker,
this specifies a Windows application.
How do I stop the console window from appearing?
Add these lines to the module definition (.def) file:
EXETYPE NT
SUBSYSTEM WINDOWS
or add the linker flag -L/exet:nt/su:windows.
Copyright (c) 1999-2002 by Digital Mars, All Rights Reserved