Installation instructions:
Please ensure you have python and numpy installed. Based on our experiences, Python 2.7+ is the preferred version to use with CnC-Python.
1. Install babel from https://computation.llnl.gov/casc/components/#page=home
while installing these commands may be helpful:
- ../babel/configure --prefix=/Users/shamsimam/softwares --enable-maintainer-mode --enable-python LDFLAGS=-L/Users/shamsimam/softwares/lib JAVAPREFIX=/System/Library/Frameworks/JavaVM.framework/Home JNI_INCLUDES=/System/Library/Frameworks/JavaVM.framework/Home/include
- make -j4
- sudo make install
- make check
make check is optional and may take a long while to complete.
2. After installing babel run the following command:
babel-config --dump | grep SUPPORT
you should get output as follows:
SUPPORT_FORTRAN77="false"
SUPPORT_CXX="true"
SUPPORT_JAVA="true"
SUPPORT_PYTHON="true"
SUPPORT_FORTRAN90="false"
SUPPORT_FORTRAN03="false"
SUPPORT_STATIC="true"
SUPPORT_SHARED="true"
BABEL_SUPPORTED_LANGUAGES="c cxx f77 f90 f03 java python"
ensure that Java and Python are supported.
3. Once babel is installed, you now need to install cnc-babel.
Run "ant clean && ant" on the directory to have cnc-babel installed.
Remember to set CNC_HOME environment variable to the distribution directory, this will be used by some later scripts
4. Running examples, e.g. cholesky
Examples also have associated makefiles. The following commands should run the translator, compiler and execution steps:
make translate
make build
make run