Thread overview
SC name conflicts with NT Service cmd
Oct 19, 2002
SD
Oct 19, 2002
Christof Meerwald
Oct 19, 2002
Matthew Wilson
Oct 20, 2002
SD
October 19, 2002
Hi
I am running Windows XP.
I have installed digital mars and updated the PATH to first point to the
dmars directory.

When in my C source directory, I launch SC.EXE, the program which is invoked is a Microsoft NT service Controller and services. I have to put the full program path.

Another point : when I run scppn, I get the error "Fatal error: unable to open input file 'typeinfo.h'". sc.exe compiles without error.

Any similar experience and fix ?

Thx

Stephane Delaval
October 19, 2002
On Sat, 19 Oct 2002 11:22:06 +0000 (UTC), SD wrote:
> When in my C source directory, I launch SC.EXE, the program which is invoked is a Microsoft NT service Controller and services. I have to put the full program path.

Or use "dmc.exe" instead of "sc.exe"


> Another point : when I run scppn, I get the error "Fatal error: unable to open input file 'typeinfo.h'". sc.exe compiles without error.

sc.exe/dmc.exe sets some environment variables (defined in sc.ini) so that scppn knows where to look for standard include files - you shouldn't run scppn directly.


bye, Christof

-- 
http://cmeerw.org                                 JID: cmeerw@jabber.at mailto cmeerw at web.de

...and what have you contributed to the Net?
October 19, 2002
I have run into this from time to time. You need to ensure that your DMC path components come before those of the system. I do this by having a command/batch (.cmd on NT/2K/XP;.bat on 9x/ME), containing (the following is the NT version)

@echo off
echo .
echo Setting up command line environment for Digital Mars C/C++ 8.30
echo .

rem Compiler drive
if (%COMP_DRV%) == () goto got_no_comp_drv
goto got_comp_drv
:got_no_comp_drv
set COMP_DRV=C:
:got_comp_drv

rem Work drive
if (%WORK_DRV%) == () goto got_no_work_drv
goto got_work_drv
:got_no_work_drv
set WORK_DRV=C:
:got_work_drv

set COMP_DIR=%COMP_DRV%\PROGRAMS\DM\DM830\DM
set COMP_BIN=%COMP_DIR%\BIN
set
COMP_INC=%COMP_DIR%\include;%COMP_DIR%\include\win32;%COMP_DIR%\stl;%COMP_DI
R%\stlsoft
set COMP_LIB=%COMP_DIR%\lib

set WORK_DRV=H:
set WORK_DIR=\Dev\Test\

PATH=%COMP_BIN%;%PATH%;
path
set INCLUDE=%COMP_INC%
set LIB=%COMP_LIB%

echo .
%WORK_DRV%
cd %WORK_DIR%
echo .
cmd.exe

As you can see from the "PATH=%COMP_BIN%;%PATH%;" line, the DMC path is set to take priority over the existing, system, path. You're more than welcome to take whatever parts of this may be useful to you.

BTW, if you want a little help working with environment variables, you can download the Environment Variable Expander from http://www.synesis.com.au/r_systools.html. Simply typing "nvx PATH" or "nvx -p" at the command line will give you an ordered list of the current PATH setting, as in the following for one of my machines

P:\PROGRAMS\DM\DM830\DM\BIN
P:\Program Files\Intel\VTune\CGGlbCache
P:\Program Files\Intel\VTune\Analyzer\Bin
P:\Program Files\Intel\VTune\Shared\Bin
P:\Program Files\Intel\ICID
P:\Program Files\Intel\EDB
P:\Program Files\Intel\ISelect\Bin6
P:\Program Files\Intel\Compiler60\Ia64\Bin
P:\Program Files\Intel\Compiler60\IA32\Bin
P:\Program Files\Microsoft.NET\FrameworkSDK\Bin\
F:\WINXP\Microsoft.NET\Framework\v1.0.3705\
c:\bin
F:\WINXP\system32
F:\WINXP
F:\WINXP\system32\WBEM
P:\SDKs\Microsoft SDK\Bin\.
P:\SDKs\Microsoft SDK\Bin\WinNT\.


"SD" <stephanedelaval@wanadoo.fr> wrote in message news:aorf8t$1n88$1@digitaldaemon.com...
> Hi
> I am running Windows XP.
> I have installed digital mars and updated the PATH to first point to the
> dmars directory.
>
> When in my C source directory, I launch SC.EXE, the program which is invoked is a Microsoft NT service Controller and services. I have to put the full program path.
>
> Another point : when I run scppn, I get the error "Fatal error: unable to open input file 'typeinfo.h'". sc.exe compiles without error.
>
> Any similar experience and fix ?
>
> Thx
>
> Stephane Delaval


October 20, 2002
"Matthew Wilson" <dmd@synesis.com.au> wrote in news:aosmp4$2up4$1@digitaldaemon.com:

> I have run into this from time to time. You need to ensure that your DMC path components come before those of the system. I do this by having a command/batch (.cmd on NT/2K/XP;.bat on 9x/ME), containing (the following is the NT version)
> 
> @echo off
> echo .
> echo Setting up command line environment for Digital Mars C/C++ 8.30
> echo .
> 
> rem Compiler drive
> if (%COMP_DRV%) == () goto got_no_comp_drv
> goto got_comp_drv
>:got_no_comp_drv
> set COMP_DRV=C:
>:got_comp_drv
> 
> rem Work drive
> if (%WORK_DRV%) == () goto got_no_work_drv
> goto got_work_drv
>:got_no_work_drv
> set WORK_DRV=C:
>:got_work_drv
> 
> set COMP_DIR=%COMP_DRV%\PROGRAMS\DM\DM830\DM
> set COMP_BIN=%COMP_DIR%\BIN
> set
> COMP_INC=%COMP_DIR%\include;%COMP_DIR%\include\win32;%COMP_DIR%\stl;%
CO
> MP_DI R%\stlsoft
> set COMP_LIB=%COMP_DIR%\lib
> 
> set WORK_DRV=H:
> set WORK_DIR=\Dev\Test\
> 
> PATH=%COMP_BIN%;%PATH%;
> path
> set INCLUDE=%COMP_INC%
> set LIB=%COMP_LIB%
> 
> echo .
> %WORK_DRV%
> cd %WORK_DIR%
> echo .
> cmd.exe
> 
> As you can see from the "PATH=%COMP_BIN%;%PATH%;" line, the DMC path is set to take priority over the existing, system, path. You're more than welcome to take whatever parts of this may be useful to you.
> 
> BTW, if you want a little help working with environment variables, you can download the Environment Variable Expander from http://www.synesis.com.au/r_systools.html. Simply typing "nvx PATH" or "nvx -p" at the command line will give you an ordered list of the current PATH setting, as in the following for one of my machines
> 
> P:\PROGRAMS\DM\DM830\DM\BIN
> P:\Program Files\Intel\VTune\CGGlbCache
> P:\Program Files\Intel\VTune\Analyzer\Bin
> P:\Program Files\Intel\VTune\Shared\Bin
> P:\Program Files\Intel\ICID
> P:\Program Files\Intel\EDB
> P:\Program Files\Intel\ISelect\Bin6
> P:\Program Files\Intel\Compiler60\Ia64\Bin
> P:\Program Files\Intel\Compiler60\IA32\Bin
> P:\Program Files\Microsoft.NET\FrameworkSDK\Bin\
> F:\WINXP\Microsoft.NET\Framework\v1.0.3705\
> c:\bin
> F:\WINXP\system32
> F:\WINXP
> F:\WINXP\system32\WBEM
> P:\SDKs\Microsoft SDK\Bin\.
> P:\SDKs\Microsoft SDK\Bin\WinNT\.
> 
> 
> "SD" <stephanedelaval@wanadoo.fr> wrote in message news:aorf8t$1n88$1@digitaldaemon.com...
>> Hi
>> I am running Windows XP.
>> I have installed digital mars and updated the PATH to first point to
>> the dmars directory.
>>
>> When in my C source directory, I launch SC.EXE, the program which is invoked is a Microsoft NT service Controller and services. I have to put the full program path.
>>
>> Another point : when I run scppn, I get the error "Fatal error: unable to open input file 'typeinfo.h'". sc.exe compiles without error.
>>
>> Any similar experience and fix ?
>>
>> Thx
>>
>> Stephane Delaval
> 
> 
> 

Many thanks to both of you for your help.
Stephane