Quick Search:

Mode

Context

Displaying 3 lines of context. None | Less | More | Full

Other Diffs

Ignore

Blank Lines Whitespace: Expand:

Diff

1.184
 
1.185
 
MAIN:plunky:20110606133526
 
cc.c
_>138138 static void add_prefix(const char *);
 139139 static char *find_file(const char *, int);
 140140 char *copy(const char *, int);
<> 141+char *cat(const char *, const char *);
141142 char *setsuf(char *, char);
 142143 int getsuf(char *);
 143144 int main(int, char *[]);
     
 !
864865                 for(pv=ptemp; pv <pvt; pv++)
 865866                         av[na++] = *pv;
 866867                 if (!nostdinc) {
<>867 -                        av[na++] = "-S", av[na++] = altincdir;
 868 -                        av[na++] = "-S", av[na++] = incdir;
 869 -                        av[na++] = "-S", av[na++] = pccincdir;
  868+                        av[na++] = "-S", av[na++] = cat(sysroot, altincdir);
  869+                        av[na++] = "-S", av[na++] = cat(sysroot, incdir);
  870+                        av[na++] = "-S", av[na++] = cat(sysroot, pccincdir);
870871                 }
 871872                 if (idirafter) {
 872873                         av[na++] = "-I";
     
 !
10601061 #if !defined(os_sunos) && !defined(os_win32) && !defined(os_darwin)
 10611062                 av[j++] = "-X";
 10621063 #endif
<> 1064+                if (sysroot)
  1065+                        av[j++] = cat("--sysroot=", sysroot);
10631066                 if (shared) {
 10641067 #ifdef os_darwin
 10651068                         av[j++] = "-dylib";
     
 !
14581461         return rv;
 14591462 }
 14601463 
<> 1464+/*
  1465+ * Catenate two (optional) strings together
  1466+ */
  1467+char *
  1468+cat(const char *a, const char *b)
  1469+{
  1470+        size_t len;
  1471+        char *rv;
  1472+
  1473+        len = (a ? strlen(a) : 0) + (b ? strlen(b) : 0) + 1;
  1474+        rv = ccmalloc(len);
  1475+        snprintf(rv, len, "%s%s", (a ? a : ""), (b ? b : ""));
  1476+        return rv;
  1477+}
  1478+
<_14611479 int
 14621480 cunlink(char *f)
 14631481 {
FishEye: Open Source License registered to PCC.
Atlassian FishEye, CVS analysis. (Version:1.6.3 Build:build-336 2008-11-04) - Administration - Page generated 2014-12-22 01:37 +0100