Esempio n. 1
0
# Write setup.cfg
import KCore.Dist as Dist
Dist.writeSetupCfg()

# Test if numpy exists =======================================================
(numpyVersion, numpyIncDir, numpyLibDir) = Dist.checkNumpy()

# Test if kcore exists =======================================================
(kcoreVersion, kcoreIncDir, kcoreLibDir) = Dist.checkKCore()

# Compilation des fortrans ===================================================
from KCore.config import *
if (f77compiler == "None"):
    print "Error: a fortran 77 compiler is required for compiling Post."
    sys.exit()
args = Dist.getForArgs(); opt = ''
for c in xrange(len(args)):
    opt += 'FOPT'+str(c)+'='+args[c]+' '
os.system("make -e FC="+f77compiler+" F90=true WDIR=Post/Fortran "+opt)
os.system("make -e FC="+f77compiler+" F90=true WDIR=Post/zipper "+opt)
if (f90compiler != "None" and os.access('Post/usurp', os.F_OK) == True):
    os.system("(cd Post/usurp; make -e FC="+f77compiler+" F90="+f90compiler+" "+opt+")")
prod = os.getenv("ELSAPROD")
if prod is None: prod = 'xx'

# Setting libraryDirs and libraries ===========================================
libraryDirs = ["build/"+prod, kcoreLibDir]
libraries = ["PostF", "kcore"]
(ok, libs, paths) = Dist.checkFortranLibs([], additionalLibPaths)
libraryDirs += paths; libraries += libs
(ok, libs, paths) = Dist.checkCppLibs([], additionalLibPaths)
Esempio n. 2
0
# Write setup.cfg file
import KCore.Dist as Dist
Dist.writeSetupCfg()

# Test if numpy exists =======================================================
(numpyVersion, numpyIncDir, numpyLibDir) = Dist.checkNumpy()

# Test if kcore exists =======================================================
(kcoreVersion, kcoreIncDir, kcoreLibDir) = Dist.checkKCore()

# Compilation des fortrans ===================================================
from KCore.config import *
if (f77compiler == "None"):
    print "Error: a fortran 77 compiler is required for compiling Connector."
    sys.exit()
args = Dist.getForArgs()
opt = ''
for c in xrange(len(args)):
    opt += 'FOPT' + str(c) + '=' + args[c] + ' '
os.system("make -e FC=" + f77compiler + " WDIR=Connector/Fortran " + opt)
prod = os.getenv("ELSAPROD")
if prod is None: prod = 'xx'

# Setting libraryDirs and libraries ===========================================
libraryDirs = ["build/" + prod, kcoreLibDir]
libraries = ["ConnectorF", "kcore"]
(ok, libs, paths) = Dist.checkFortranLibs([], additionalLibPaths)
libraryDirs += paths
libraries += libs
(ok, libs, paths) = Dist.checkCppLibs([], additionalLibPaths)
libraryDirs += paths