Ecore_Exe: ifdef prctl usage
authorbdilly <bdilly@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Sat, 8 Oct 2011 01:17:19 +0000 (01:17 +0000)
committerbdilly <bdilly@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Sat, 8 Oct 2011 01:17:19 +0000 (01:17 +0000)
git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/ecore@63916 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33

src/lib/ecore/ecore_exe.c

index 568a35c..239063f 100644 (file)
@@ -14,7 +14,9 @@
 #include <sys/types.h>
 #include <unistd.h>
 #include <fcntl.h>
-#include <sys/prctl.h>
+#ifdef __linux__
+# include <sys/prctl.h>
+#endif
 
 #ifdef HAVE_SYS_WAIT_H
 # include <sys/wait.h>
@@ -1510,10 +1512,12 @@ _ecore_exe_exec_it(const char *exe_cmd, Ecore_Exe_Flags flags)
           }
      }
 
+#ifdef __linux__
    if ((flags & ECORE_EXE_TERM_WITH_PARENT))
      {
         prctl(PR_SET_PDEATHSIG, SIGTERM);
      }
+#endif
 
    if (!(flags & ECORE_EXE_NOT_LEADER)) setsid();
    if ((flags & ECORE_EXE_USE_SH))