Bläddra i källkod

HPCC-8692 Fix OSX build issues

Mostly related to location of template instantiation.

Signed-off-by: Anthony Fishbeck <Anthony.Fishbeck@lexisnexis.com>
Anthony Fishbeck 12 år sedan
förälder
incheckning
f0cd4929e8
3 ändrade filer med 10 tillägg och 3 borttagningar
  1. 6 0
      common/workunit/package.cpp
  2. 1 0
      common/workunit/package.h
  3. 3 3
      common/workunit/pkgimpl.hpp

+ 6 - 0
common/workunit/package.cpp

@@ -28,6 +28,12 @@
 
 #define SDS_LOCK_TIMEOUT (5*60*1000) // 5mins, 30s a bit short
 
+//wrap the hashing function here to simplify template dependencies
+hash64_t pkgHash64Data(size32_t len, const void *buf, hash64_t hval)
+{
+    return rtlHash64Data(len, buf, hval);
+}
+
 CPackageNode::CPackageNode(IPropertyTree *p)
 {
     if (p)

+ 1 - 0
common/workunit/package.h

@@ -48,6 +48,7 @@ extern WORKUNIT_API IHpccPackageSet *createPackageSet(const char *process);
 extern WORKUNIT_API IPropertyTree * getPackageMapById(const char * id, bool readonly);
 extern WORKUNIT_API IPropertyTree * getPackageSetById(const char * id, bool readonly);
 extern WORKUNIT_API IPropertyTree * resolvePackageSetRegistry(const char *process, bool readonly);
+extern WORKUNIT_API hash64_t pkgHash64Data(size32_t len, const void *buf, hash64_t hval);
 
 
 #endif

+ 3 - 3
common/workunit/pkgimpl.hpp

@@ -175,8 +175,8 @@ public:
         {
             const self *p = dynamic_cast<const self *>(base);
             bases.append(const_cast<self &>(*LINK(p)));   // should really be an arrayof<const base> but that would require some fixing in jlib
-            TYPE::hash = rtlHash64Data(sizeof(p->hash), &p->hash, TYPE::hash);
-            mergeEnvironment(p);
+            TYPE::hash = pkgHash64Data(sizeof(p->hash), &p->hash, TYPE::hash);
+            TYPE::mergeEnvironment(p);
         }
     }
 
@@ -230,7 +230,7 @@ public:
         if (*superFileName=='~')
             superFileName++;
         StringBuffer xpath;
-        if (hasProp(TYPE::makeSuperFileXPath(xpath, superFileName)))
+        if (TYPE::hasProp(TYPE::makeSuperFileXPath(xpath, superFileName)))
             return true;
         ForEachItemIn(idx, bases)
         {