HPCC-14428 Replace popen/pclose with _popen/_pclose on Windows Reviewed-By: Richard Chapman <rchapman@hpccsystems.com>
@@ -331,7 +331,7 @@ static CComponentStatusFactory *csFactory = NULL;
static CriticalSection getComponentStatusSect;
-extern COMPONENTSTATUS_API IComponentStatusFactory* getComponentStatusFactory()
+IComponentStatusFactory* getComponentStatusFactory()
{
CriticalBlock block(getComponentStatusSect);
@@ -104,4 +104,4 @@ public:
virtual void updateComponentStatus(const char* reporter, IArrayOf<IConstComponentStatus>& statusList);
};
-extern "C" COMPONENTSTATUS_API IComponentStatusFactory* getComponentStatusFactory();
+COMPONENTSTATUS_API IComponentStatusFactory* getComponentStatusFactory();
@@ -23,6 +23,7 @@
#include "roxiecommlibscm.hpp"
#include "componentstatus.hpp"
#include "rmtssh.hpp"
+#include "platform.h"
#ifndef eqHoleCluster
#define eqHoleCluster "HoleCluster"
@@ -495,4 +495,13 @@ typedef __int64 cycle_t;
// BUILD_TAG not needed here anymore - defined in build_tag.h
//#define BUILD_TAG "build_0000" // Will get substituted during pre-build
+#ifdef _WINDOWS
+#ifndef popen
+#define popen _popen
+#endif
+#ifndef pclose
+#define pclose _pclose
+
#endif