10
1
mirror of https://gitlab.com/scemama/qmcchem.git synced 2024-11-06 22:23:39 +01:00
qmcchem/build.ninja

91 lines
2.7 KiB
Plaintext
Raw Normal View History

2015-12-20 01:09:14 +01:00
rule compile_ezfio
command = ./scripts/compile_ezfio.sh
description = Compiling the EZFIO library
pool = console
rule build_properties_config
command = bash -c "source qmcchemrc ; exec python ./scripts/create_properties_ezfio.py"
pool = console
rule compile_irpf90
command = ./scripts/compile_irpf90.sh
description = Compiling IRPF90
pool = console
rule compile_src
command = ./scripts/compile_src.sh
description = Compiling src
pool = console
rule create_archive
command = git archive --format tar.gz HEAD --prefix "QmcChem/" -7 -o qmcchem.tar.gz
description = Creating archive
pool = console
rule compile_ocaml_dep
command = scripts/compile_ocaml_dep.sh
description = Finding dependencies in OCaml files
pool = console
rule compile_ocaml
command = scripts/compile_ocaml.sh $target
description = Compiling OCaml tools
pool = console
rule copy_to_bin
command = bash -c "cp $in $out ; touch $out"
description = Copying $in into bin/
pool = console
rule clean
command = ./scripts/clean.sh
pool = console
# put all files of PROPERTIES here
# --------------------------------
2015-12-20 01:16:32 +01:00
build ezfio_config/properties.config: build_properties_config | scripts/create_properties_python.py src/PROPERTIES/properties.irp.f src/PROPERTIES/properties_energy.irp.f src/PROPERTIES/properties_general.irp.f || src/IRPF90_temp/build.ninja
2015-12-20 01:09:14 +01:00
# EZFIO
# -----
build lib/libezfio.a lib/libezfio_irp.a EZFIO/lib/libezfio.a EZFIO/lib/libezfio_irp.a EZFIO/Ocaml/ezfio.ml EZFIO/Python/ezfio.py: compile_ezfio | ezfio_config/qmc.config ezfio_config/properties.config make.config scripts/create_properties_ezfio.py || src/tags src/irpf90_entities src/irpf90.make src/IRPF90_temp/build.ninja
# Fortran executables
# -------------------
build always: phony
build src/tags src/irpf90_entities src/irpf90.make src/IRPF90_temp/build.ninja: compile_irpf90 | make.config always
2015-12-20 01:31:39 +01:00
build src/MAIN/qmc src/MAIN/qmc_create_walkers src/MAIN/qmcchem_info: compile_src | lib/libezfio.a lib/libezfio_irp.a src/tags || src/irpf90_entities src/irpf90.make src/IRPF90_temp/build.ninja
2015-12-20 01:09:14 +01:00
# Archive
# -------
build qmcchem.tar.gz: create_archive
# Ocaml
# -----
2015-12-20 02:03:40 +01:00
build ocaml/generated.ninja : compile_ocaml_dep | EZFIO/Ocaml/ezfio.ml always
2015-12-20 01:09:14 +01:00
build ocaml/qmcchem : compile_ocaml | ocaml/generated.ninja EZFIO/Ocaml/ezfio.ml
target = qmcchem
# Copy binaries in bin
# --------------------
build bin/qmc: copy_to_bin src/MAIN/qmc
build bin/qmcchem_info: copy_to_bin src/MAIN/qmcchem_info
build bin/qmc_create_walkers: copy_to_bin src/MAIN/qmc_create_walkers
build bin/qmcchem: copy_to_bin ocaml/qmcchem
2015-12-20 01:31:39 +01:00
default bin/qmc bin/qmcchem_info bin/qmc_create_walkers bin/qmcchem
2015-12-20 01:09:14 +01:00
# Clean
# -----
build clean: clean