Changeset a376c9e in mainline for uspace/app/pcc/cc
- Timestamp:
- 2011-04-14T21:02:28Z (15 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 12831ed7
- Parents:
- 3daba9de
- Location:
- uspace/app/pcc/cc
- Files:
-
- 2 added
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/app/pcc/cc/cc/cc.c
r3daba9de ra376c9e 285 285 * Wide char defines. 286 286 */ 287 #if 0 287 288 #if WCHAR_TYPE == USHORT 288 289 #define WCT "short unsigned int" … … 306 307 #error WCHAR_TYPE not defined or invalid 307 308 #endif 309 #endif 310 311 #define WCT "int" 312 #define WCM "2147483647" 313 308 314 309 315 #ifdef GCC_COMPAT … … 1327 1333 } 1328 1334 1335 #elif defined(__helenos__) 1336 1337 #include <task.h> 1338 1339 int callsys(char *f, char *v[]) 1340 { 1341 size_t len; 1342 char *path = NULL; 1343 const char *s; 1344 int t; 1345 task_exit_t texit; 1346 int retval; 1347 1348 task_id_t tid; 1349 1350 if (vflag) { 1351 fprintf(stderr, "%s ", f); 1352 for (t = 1; v[t]; t++) 1353 fprintf(stderr, "%s ", v[t]); 1354 fprintf(stderr, "\n"); 1355 } 1356 1357 if (Bflag) { 1358 len = strlen (Bflag) + 8; 1359 path = malloc (len); 1360 if (path == NULL) { 1361 error("callsys: malloc failed"); 1362 exit(1); 1363 } 1364 if ((s = strrchr(f, '/'))) { 1365 strlcpy(path, Bflag, len); 1366 strlcat(path, s, len); 1367 if (task_spawnv(&tid, path, v) == 0) 1368 goto _wait; 1369 } 1370 } 1371 1372 if (task_spawnv(&tid, f, v) == 0) 1373 goto _wait; 1374 1375 if ((s = strrchr(f, '/')) && task_spawnv (&tid, s + 1, v) == 0) 1376 goto _wait; 1377 1378 errorx(8, "Can't find %s\n", f); 1379 return 0; 1380 1381 _wait: 1382 1383 1384 if (task_wait (tid, &texit, &retval) != 0) { 1385 error("Couldn't wait on task"); 1386 return 0; 1387 } 1388 1389 return retval; 1390 } 1391 1329 1392 #else 1330 1393 -
uspace/app/pcc/cc/cpp/Makefile
r3daba9de ra376c9e 30 30 MIPDIR = ../../mip 31 31 ARCHDIR = ../../arch/$(PLATFORM) 32 EXTRA_CFLAGS = -I$(MIPDIR) -I$(ARCHDIR) 32 EXTRA_CFLAGS = -I$(MIPDIR) -I$(ARCHDIR) -w 33 33 EXTRA_CLEAN = y.tab.c y.tab.h 34 34 DEFS = -DCPP_DEBUG -Dfree=free -DCPPBUF=16384
Note:
See TracChangeset
for help on using the changeset viewer.