Version 3 (modified by tramer, 13 years ago) (diff) |
---|
Installing ccaffeine on BG/P (Surveyor at Argonne)
Current build instructions (Notes by Stephen Tramer [email protected]…)
You will need both the latest versions of cca-spec-babel and ccaffeine from the repository for this. ccaffeine is not configured for spec-classic or spec-neo; if you want either of those features you're on your own (but they should compile out of the box with a little love to the config/config.sub file to add the -bgp OS type; see the config/config.sub file for cca-spec-babel).
See here for instructions on checking out the cca-tools sources. You will need to build the latest version of babel as described on poring babel to BG/P before attempting any of this.
Building cca-spec-babel
Check cca-spec-babel out from the repository, and configure:
./configure CPP="gcc -E" CC=mpixlc CXX=mpixlcxx FC=mpixlf2003 F77=mpixlf77 \ --with-babel-config=$BABEL_INSTALL/bin/powerpc64-ibm-bgp-babel-config \ --with-libxml2=$LIBXML2_LOC --with-babel-python LDFLAGS="-qnostaticlink" \ --host=powerpc-bgp-linux-gnu --target=powerpc64-ibm-bgp \ target_alias=powerpc64-ibm-bgp --prefix=$CCA_INSTALL_DIR
Then 'make clean all install'. Done!
Building ccaffeine
Building ccaffeine will not work out of the box. You need to edit some parts of the cca-spec-babel install and also some of the makefiles for ccaffeine itself.
- Edit $CCA_INSTALL_DIR/share/cca-spec-babel-$(SPEC_VER)-babel-$(BABEL_VER) files
In most cases, SPEC_VER will be 0_8_6 and BABEL_VER will be 1.5.0, and that's what will be used in this example. You'll need to edit two files:
CCA_Babel_Vars.sh: CCASPEC_GENSCLCCA_SH=$CCA_INSTALL_DIRl/bin/genSCLCCA.sh_0_8_6_b_1.5.0/genSCLCCA.sh MakeIncl_CCA_Babel_Vars: CCASPEC_GENSCLCCA_SH=$CCA_INSTALL_DIR/bin/genSCLCCA.sh_0_8_6_b_1.5.0/genSCLCCA.sh
where $CCA_INSTALL_DIR refers to the value that you used when configuring - it's not an actual variable in these files. This should work since genSCLCCA.sh is a symbolic link to the "right" genSCLCCA.sh, which is prefixed with the system type it was compiled for and suffixed with version numbers. A quick way to do this is with sed:
cd $CCA_INSTALL_DIR/share find . -name *Vars* -exec sed -i1 \ -e "s|^CCASPEC_GENSCLCCA_SH=.*|CCASPEC_GENSCLCCA_SH='$CCA_INSTALL_DIRl/bin/genSCLCCA.sh'|g" {} \; -print
- Remove all instances of -Wall flags. '-Wall' is not compatible with the IBM C++ compilers. You will need to edit $CCAFE_SRC/cxx/Makefile.Rules.in and $CCAFE_SRC/cxx/gnu/getopt/Makefile.in.
- Edit $CCAFE_SRC/config/shlib.m4:
Index: config/shlib.m4 =================================================================== --- config/shlib.m4 (revision 190) +++ config/shlib.m4 (working copy) @@ -1133,7 +1133,6 @@ CXX_SHLIB_LD="${CXX} -shared" DL_OBJS="tclLoadDl.o" DL_LIBS="-ldl" - LDFLAGS="-rdynamic" CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}' LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS} else @@ -1175,7 +1174,6 @@ CXX_SHLIB_LD="${CXX} -shared" DL_OBJS="" DL_LIBS="-ldl" - LDFLAGS="-rdynamic" CC_SEARCH_FLAGS="" LD_SEARCH_FLAGS="" else
This prevents the '-rdynamic' flag, which is not compatible with xlC, from being passed to the linker.
- Run 'aclocal && autoconf'.
- Configure:
./configure CPP="gcc -E" CC=mpixlc CXX=mpixlcxx FC=mpixlf2003 F77=mpixlf77 \ --with-csb-config=$CCA_INSTALL_DIR/bin/cca-spec-babel-config \ --with-babel-python LDFLAGS="-qnostaticlink" --host=powerpc-bgp-linux-gnu \ --target=powerpc64-ibm-bgp target_alias=powerpc64-ibm-bgp --prefix=$CCA_INSTALL_DIR \ --with-boost=/home/norris/soft/boost-1_38_0/include/boost-1_38 \ --with-xml2-config=/gpfs/home/projects/ccatools/libxml2/bin/xml2-config \ --with-xml2-includes=-I/gpfs/home/projects/ccatools/libxml2/include/libxml2 \ --with-xml2-libs=-L/gpfs/home/projects/ccatools/libxml2/lib
- Build, and install.