CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions
Utils.LoadPrerequisiteSource Class Reference
Inheritance diagram for Utils.LoadPrerequisiteSource:

Public Member Functions

def insertInto
 
def setPrerequisites
 

Detailed Description

The class is a Source which loads prerequisites libraries in advance. 
   This is done to make sure we can load libraries containing common blocks in
   the correct order.

Definition at line 3 of file Utils.py.

Member Function Documentation

def Utils.LoadPrerequisiteSource.insertInto (   self,
  parameterSet,
  myname 
)

Definition at line 11 of file Utils.py.

11 
12  def insertInto(self, parameterSet, myname):
13  from ctypes import LibraryLoader, CDLL
14  import platform
15  loader = LibraryLoader(CDLL)
16  ext = platform.uname()[0] == "Darwin" and "dylib" or "so"
17  [loader.LoadLibrary("lib%s.%s" % (l, ext)) for l in self.libraries]
18  super(LoadPrerequisiteSource,self).insertInto(parameterSet,myname)
def Utils.LoadPrerequisiteSource.setPrerequisites (   self,
  libs 
)

Definition at line 8 of file Utils.py.

8 
9  def setPrerequisites(self, *libs):
10  self.__dict__["libraries"] = libs