sc.ini not checked for imports


In my sc.ini I have the default import folders like I do with dmd but dnet wont use them so I have to use -I switch everytime when compiling.

file attachments

Closed Jun 23, 2009 at 5:25 PM by cristiv


cristiv wrote May 20, 2009 at 3:51 AM

Could not reproduce, I created a sc.ini with this content:


And it worked.

tim_m89 wrote May 21, 2009 at 1:39 PM

If i type in the absolute path to dnet it works fine. I have dnet.exe in my path but when I type just dnet on it's own it appears that it cannot locate its self and therefore can't find sc.ini either. In inifile.c there is quite a lot of preprocessor directives and on my system (winxp vs-2008) a block of code is not active but appears like it should be there one:

if (1){
// Search PATH for argv0
const char *p = getenv("PATH");
Array *paths = FileName::splitPath(p);
filename = FileName::searchPath(paths, argv0, 0);
if (!filename)
goto Letc; // argv0 not found on path
filename = (char *)FileName::replaceName(filename, inifile);
if (FileName::exists(filename))
goto Ldone;

How are you compiling dnet?

tim_m89 wrote May 21, 2009 at 3:01 PM

That block of code I pointed out would only help if called as 'dnet.exe' but not 'dnet'. I am not going to try and cleanup the nix code and all those extra '#if' but I've added some windows code which it works fine with (attached). Dmd has always worked fine with my sc.ini but I always use the precompiled binary.

wrote May 21, 2009 at 3:01 PM

cristiv wrote Jun 20, 2009 at 2:46 AM

I have applied the fix.

wrote Jun 23, 2009 at 5:25 PM

wrote Jun 23, 2009 at 5:25 PM

wrote Feb 14, 2013 at 12:52 AM

wrote May 16, 2013 at 5:01 AM