forked from enlightenment/efl
parent
c7c66a652a
commit
5b9e0b0ead
|
@ -34,6 +34,8 @@ void *alloca (size_t);
|
|||
#include <math.h>
|
||||
|
||||
#include "edje_cc.h"
|
||||
#include <Ecore.h>
|
||||
#include <Ecore_File.h>
|
||||
|
||||
static void new_object(void);
|
||||
static void new_statement(void);
|
||||
|
@ -696,6 +698,9 @@ compile(void)
|
|||
* Also, that preprocessor is not managing C++ comments, so pass the
|
||||
* sun cc preprocessor just after.
|
||||
*/
|
||||
ret = -1;
|
||||
if (ecore_file_exists("/usr/ccs/lib/cpp"))
|
||||
{
|
||||
snprintf(buf, sizeof(buf), "/usr/ccs/lib/cpp -I%s %s %s %s",
|
||||
inc, def, file_in, tmpn);
|
||||
ret = system(buf);
|
||||
|
@ -714,6 +719,7 @@ compile(void)
|
|||
snprintf(tmpn, 4096, "%s", tmpn2);
|
||||
}
|
||||
}
|
||||
}
|
||||
/*
|
||||
* On some BSD based systems (MacOS, OpenBSD), the default cpp
|
||||
* in the path is a wrapper script that chokes on the -o option.
|
||||
|
@ -728,13 +734,13 @@ compile(void)
|
|||
* OpenSolaris: using gcc -E to remove them after using cpp.
|
||||
*
|
||||
*/
|
||||
if (ret < 0)
|
||||
if (ret != 0)
|
||||
{
|
||||
snprintf(buf, sizeof(buf), "cat %s | cpp -I%s %s > %s",
|
||||
file_in, inc, def, tmpn);
|
||||
ret = system(buf);
|
||||
}
|
||||
if (ret < 0)
|
||||
if (ret != 0)
|
||||
{
|
||||
snprintf(buf, sizeof(buf), "gcc -I%s %s -E -o %s %s",
|
||||
inc, def, tmpn, file_in);
|
||||
|
|
Loading…
Reference in New Issue