Enlightenment CVS committal
Author : dj2
Project : e17
Module : libs/engrave
Dir : e17/libs/engrave/src/lib
Modified Files:
engrave_load.c
Log Message:
- set cpps include path correctly
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/engrave/src/lib/engrave_load.c,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -3 -r1.9 -r1.10
--- engrave_load.c 14 Nov 2004 16:59:59 -0000 1.9
+++ engrave_load.c 15 Nov 2004 05:27:39 -0000 1.10
@@ -31,14 +31,26 @@
if (fd >= 0)
{
int ret;
+ char *path, *t;
- snprintf(buf, sizeof(buf), "cat %s | cpp -E -o %s", file, tmpf);
+ path = strdup(file);
+ t = strrchr(path, '/');
+ if (t) {
+ *t = '\0';
+ } else {
+ FREE(path);
+ path = strdup(".");
+ }
+
+ snprintf(buf, sizeof(buf), "cat %s | cpp -E -I %s -o %s", file, path,
tmpf);
ret = system(buf);
if (ret < 0)
{
- snprintf(buf, sizeof(buf), "gcc -E -o %s %s", tmpf, file);
+ snprintf(buf, sizeof(buf), "gcc -E -I %s -o %s %s", path, tmpf, file);
ret = system(buf);
}
+ FREE(path);
+
if (ret >= 0) file = tmpf;
close(fd);
}
-------------------------------------------------------
This SF.Net email is sponsored by: InterSystems CACHE
FREE OODBMS DOWNLOAD - A multidimensional database that combines
robust object and relational technologies, making it a perfect match
for Java, C++,COM, XML, ODBC and JDBC. www.intersystems.com/match8
_______________________________________________
enlightenment-cvs mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs