Binary_c The binary_c stellar population nucleosynthesis framework --------------------------------------------------------- Websites: http://personal.ph.surrey.ac.uk/~ri0005/ http://personal.ph.surrey.ac.uk/~ri0005/binary_c.html http://www.ast.cam.ac.uk/~rgi/ http://www.ast.cam.ac.uk/~rgi/binary_c.html Code on gitlab: https://gitlab.eps.surrey.ac.uk/ri0005/binary_c https://gitlab.eps.surrey.ac.uk/ri0005/binary_c-python https://gitlab.eps.surrey.ac.uk/ri0005/librinterpolate https://gitlab.eps.surrey.ac.uk/ri0005/libmemoize https://gitlab.eps.surrey.ac.uk/ri0005/librchash Email lists: https://groups.google.com/forum/#!forum/binary_c-nucsyn-announce https://groups.google.com/forum/#!forum/binary_c-nucsyn-devel Online interface: http://www.ast.cam.ac.uk/~rgi/cgi-bin/binary5.cgi http://personal.ph.surrey.ac.uk/~ri0005/cgi-bin/binary5.cgi Social media: https://twitter.com/binary_c_code https://www.facebook.com/groups/149489915089142/ Contact: Dr. Robert Izzard, Department of Physics, University of Surrey, Guildford, United Kingdom r.izzard@surrey.ac.uk rob.izzard@gmail.com Documentation is in the doc/ directory. ------ Installation is, as of binary_c 2.1.4, performed using Meson (https://mesonbuild.com/) and Ninja. You can install Meson using your system package installer, but probably you require the latest Meson (0.54 at time of writing). You should install Python3 and pip, then install meson with --- pip3 install meson --- or upgrade with --- pip3 install --upgrade meson --- [ The old Perl configure script will remain in the binary_c tree for a while, but is officially deprecated. ] ------ You require the GNU scientific library. The official location for GSL is https://www.gnu.org/software/gsl/ but I have a version at https://gitlab.eps.surrey.ac.uk/ri0005/GSL-RGI which has minor improvements. Binary_c is tested with GSL 2.6. ---------------- You will need to tell binary_c if you have installed GSL in a non-system location, e.g. by setting the environment variables LD_LIBRARY_PATH and LIBRARY_PATH with, export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:<newgslpath> export LIBRARY_PATH=$LD_LIBRARY_PATH:<newgslpath> where "<newgslpath>" is the location of the libgsl.so shared library. If you cannot find libgsl.so (which may be libgsl.so.23 or similar) you cannot run binary_c. You also need to run the correct gsl-config. If you installed GSL in your home directory, $HOME, you need to tell your shell to use this, e.g. with, export PATH=$HOME/bin/:$PATH and then run gsl-config --cflags which should give you -I$HOME/include (where $HOME is expanded). ---------------- GSL can be found at https://www.gnu.org/software/gsl/ but I keep a slightly modified version at https://gitlab.eps.surrey.ac.uk/ri0005/GSL-RGI which you should use if you can. See the INSTALL.RGI file for installation instructions. You will require libbsd which should come with your system, e.g. in the libbsd-dev package, otherwise you can get it from https://libbsd.freedesktop.org/wiki/ ------ You might also want to install: Libmemoize from https://gitlab.eps.surrey.ac.uk/ri0005/libmemoize Librinterpolate from https://gitlab.eps.surrey.ac.uk/ri0005/librinterpolate Librchash from https://gitlab.eps.surrey.ac.uk/ri0005/librchash Libbfd, which should be part of your standard packages: you must install the development package also (e.g. binutils and binutils-dev). https://sourceware.org/binutils/ GCC on Ubuntu, and many other platforms, comes with libbacktrace. If you find this is missing, and you think you need it (it's very useful!), you can install it manually from https://github.com/ianlancetaylor/libbacktrace. Note that you should make sure it uses -fPIC when compiling its static library, otherwise you may have compiler errors (particularly on Windows Subsystem for Linux). ------ There is an experiental Python interface at: https://gitlab.eps.surrey.ac.uk/ri0005/binary_c-python ------ Once you have the pre-requisites, run --- meson builddir cd builddir ninja binary_c_install_legacy --- to build to binary_c executable and shared library. Note: your environment makes a difference. If you, say, set the CFLAGS environment variable, this will be propagated into the flags sent to the compiler, which may clash with the choice made by meson. If this happens, run --- unset CFLAGS --- (assuming you are using bash) and try again.