Archives
D Programming
DD.gnu digitalmars.D digitalmars.D.bugs digitalmars.D.dtl digitalmars.D.dwt digitalmars.D.announce digitalmars.D.learn digitalmars.D.debugger C/C++ Programming
c++c++.announce c++.atl c++.beta c++.chat c++.command-line c++.dos c++.dos.16-bits c++.dos.32-bits c++.idde c++.mfc c++.rtl c++.stl c++.stl.hp c++.stl.port c++.stl.sgi c++.stlsoft c++.windows c++.windows.16-bits c++.windows.32-bits c++.wxwindows digitalmars.empire digitalmars.DMDScript |
c++ - Bug: sc.ini CFLAGS=fileName
Description: In \dm\bin\sc.ini, CFLAGS=fileName reads fileName as a seperate source file and compiles it. How to replicate: 1. Set CFLAGS in sc.ini to CFLAGS="% P%\cflags.ini" 2. Create test files cflags.ini and test.cpp. See below. 3. dmc test.cpp ***** BEGIN cfiles.ini ***** "-DSHOW_MESSAGE" ***** END cfiles.ini ***** ***** BEGIN test.cpp ***** #ifndef SHOW_MESSAGE # error SHOW_MESSAGE was not defined. #endif int main( void ) {return 0;} ***** END test.cpp ***** Expected results: The fileName used with CFLAGS should be opened and read for additional compiler switches. The following is a working example of what was expected. See \dm\html\ctg\sc.html#searches 1. Remove the CFLAGS line from sc.ini 2. dmc "\dm\bin\cflags.ini" test.cpp OS: XP w/ sp 2 Compiler: Digital Mars CD v 8.42, with cd843.zip Apologia if this turns out to be user misunderstanding. May 13 2005
Actually, that's how it's supposed to work. CFLAGS is inserted into the command line and parsed exactly as if it was typed on the command line. May 13 2005
OK, I'm unclear on CFLAGS. Fair enough. BTW Walter, thank you for the clerification. So, how would a user get the following command to work using sc.ini's CFLAGS? dmc "\dm\bin\cflags.ini" test.cpp I have tried CFLAGS= \dm\bin\cflags.ini Which fails during scppn.exe as "command line error: no input file specified" and CFLAGS=\dm\bin\cflags.ini Doesn't work as I assumed. I.e. It's pulling in scflags.ini as a source file to be compiled. I think my confusion originated with \dm\html\ctg\sc.html#searches which states "If it is set, it behaves as if the first argument to DMC is CFLAGS." An example of what I am tyrying to do can be seen at: c++/4627 In article <d63p59$a8k$1 digitaldaemon.com>, Walter says...Actually, that's how it's supposed to work. CFLAGS is inserted into the command line and parsed exactly as if it was typed on the command line. May 19 2005
"Marshall" <Marshall_member pathlink.com> wrote in message news:d6igfn$2655$1 digitaldaemon.com...OK, I'm unclear on CFLAGS. Fair enough. BTW Walter, thank you for the clerification. So, how would a user get the following command to work using sc.ini's May 20 2005
|