diff --git a/COPYING b/COPYING new file mode 120000 index 0000000..7a694c9 --- /dev/null +++ b/COPYING @@ -0,0 +1 @@ +LICENSE \ No newline at end of file diff --git a/Makefile.am b/Makefile.am index 8dafb9b..9b18f07 100644 --- a/Makefile.am +++ b/Makefile.am @@ -1,24 +1,24 @@ # QMCkl - Quantum Monte Carlo kernel library # # BSD 3-Clause License -# +# # Copyright (c) 2020, TREX Center of Excellence # All rights reserved. -# +# # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: -# +# # 1. Redistributions of source code must retain the above copyright notice, this # list of conditions and the following disclaimer. -# +# # 2. Redistributions in binary form must reproduce the above copyright notice, # this list of conditions and the following disclaimer in the documentation # and/or other materials provided with the distribution. -# +# # 3. Neither the name of the copyright holder nor the names of its # contributors may be used to endorse or promote products derived from # this software without specific prior written permission. -# +# # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" # AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE # IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE @@ -37,10 +37,66 @@ VERSION_MAJOR = @VERSION_MAJOR@ VERSION_MINOR = @VERSION_MINOR@ VERSION_PATCH = @VERSION_PATCH@ -SUBDIRS = src +SUBDIRS = +CLEANFILES = pkgconfigdir = $(libdir)/pkgconfig -pkgconfig_DATA = qmckl.pc +pkgconfig_DATA = $(srcdir)/qmckl.pc + +qmckl_h = $(srcdir)/include/qmckl.h +include_HEADERS = $(qmckl_h) + +qmckl_f = $(srcdir)/share/qmckl/fortran/qmckl_f.f90 +fortrandir = $(datadir)/$(PACKAGE_NAME)/fortran/ +fortran_DATA = $(qmckl_f) + +export srcdir qmckl_f qmckl_h + +sources_tangled = src/qmckl_ao.c + + +if QMCKL_DEVEL +# <----- +dist_src_DATA = $(ORG_FILES) + +BUILT_SOURCES = $(C_FILES) $(F_FILES) $(FH_FUNC_FILES) $(FH_TYPE_FILES) $(H_FUNC_FILES) $(H_TYPE_FILES) $(H_PRIVATE_FUNC_FILES) $(H_PRIVATE_TYPE_FILES) +CLEANFILES += $(BUILT_SOURCES) $(C_TEST_FILES) $(F_TEST_FILES) + +# -----> +endif + +## Silent + +tangle_verbose = $(tangle_verbose_@AM_V@) +tangle_verbose_ = $(tangle_verbose_@AM_DEFAULT_V@) +tangle_verbose_0 = @echo " TANGLE $@"; + +cat_h_verbose = $(cat_h_verbose_@AM_V@) +cat_h_verbose_ = $(cat_h_verbose_@AM_DEFAULT_V@) +cat_h_verbose_0 = @echo " HEADER $@"; + +## Rules +include $(srcdir)/generated.mk + +SUFFIXES = .f90 .h .org .c _f.f90 _func.h _type.h _private_func.h _private_type.h + +$(srcdir)/generated.mk: $(ORG_FILES) + $(srcdir)/tools/build_makefile.sh + +$(qmckl_h): $(H_FUNC_FILES) $(H_TYPE_FILES) + $(cat_h_verbose)$(srcdir)/tools/build_qmckl_h.sh + +$(qmckl_f): $(FH_FUNC_FILES) $(FH_TYPE_FILES) + $(cat_h_verbose)$(srcdir)/tools/build_qmckl_f.sh + +$(srcdir)/src/qmckl_f.f90: $(qmckl_f) + cp $(qmckl_f) $(srcdir)/src/qmckl_f.f90 + +#lib_LTLIBRARIES = $(top_srcdir)/src/libqmckl.la +# +#$(top_srcdir)/src/libqmckl.la; +# $(MAKE) -C src libqmckl.la +# rpms srcrpm: for dir in $(SUBDIRS); do \ @@ -49,6 +105,4 @@ rpms srcrpm: .PHONY: rpms srcrpm -README: README.md -COPYING: LICENSE diff --git a/Makefile.in b/Makefile.in index b49c63a..aa6194f 100644 --- a/Makefile.in +++ b/Makefile.in @@ -17,24 +17,24 @@ # QMCkl - Quantum Monte Carlo kernel library # # BSD 3-Clause License -# +# # Copyright (c) 2020, TREX Center of Excellence # All rights reserved. -# +# # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: -# +# # 1. Redistributions of source code must retain the above copyright notice, this # list of conditions and the following disclaimer. -# +# # 2. Redistributions in binary form must reproduce the above copyright notice, # this list of conditions and the following disclaimer in the documentation # and/or other materials provided with the distribution. -# +# # 3. Neither the name of the copyright holder nor the names of its # contributors may be used to endorse or promote products derived from # this software without specific prior written permission. -# +# # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" # AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE # IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE @@ -46,6 +46,7 @@ # OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + VPATH = @srcdir@ am__is_gnu_make = { \ if test -z '$(MAKELEVEL)'; then \ @@ -120,6 +121,7 @@ PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ +@QMCKL_DEVEL_TRUE@am__append_1 = $(BUILT_SOURCES) $(C_TEST_FILES) $(F_TEST_FILES) subdir = . ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \ @@ -129,7 +131,8 @@ am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \ am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) DIST_COMMON = $(srcdir)/Makefile.am $(top_srcdir)/configure \ - $(am__configure_deps) $(am__DIST_COMMON) + $(am__configure_deps) $(am__dist_src_DATA_DIST) \ + $(include_HEADERS) $(am__DIST_COMMON) am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ configure.lineno config.status.lineno mkinstalldirs = $(install_sh) -d @@ -163,6 +166,13 @@ am__can_run_installinfo = \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac +am__dist_src_DATA_DIST = $(srcdir)/org/qmckl_ao.org \ + $(srcdir)/org/qmckl_context.org \ + $(srcdir)/org/qmckl_distance.org \ + $(srcdir)/org/qmckl_electron.org $(srcdir)/org/qmckl_error.org \ + $(srcdir)/org/qmckl_memory.org $(srcdir)/org/qmckl_numprec.org \ + $(srcdir)/org/qmckl.org $(srcdir)/org/README.org \ + $(srcdir)/org/test_qmckl.org am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ @@ -190,8 +200,10 @@ am__uninstall_files_from_dir = { \ || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ $(am__cd) "$$dir" && rm -f $$files; }; \ } -am__installdirs = "$(DESTDIR)$(pkgconfigdir)" -DATA = $(pkgconfig_DATA) +am__installdirs = "$(DESTDIR)$(srcdir)" "$(DESTDIR)$(fortrandir)" \ + "$(DESTDIR)$(pkgconfigdir)" "$(DESTDIR)$(includedir)" +DATA = $(dist_src_DATA) $(fortran_DATA) $(pkgconfig_DATA) +HEADERS = $(include_HEADERS) RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ distclean-recursive maintainer-clean-recursive am__recursive_targets = \ @@ -221,10 +233,10 @@ ETAGS = etags CTAGS = ctags CSCOPE = cscope DIST_SUBDIRS = $(SUBDIRS) -am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/qmckl.pc.in \ - $(top_srcdir)/include/config.h.in AUTHORS COPYING ChangeLog \ - INSTALL NEWS README compile config.guess config.sub depcomp \ - install-sh ltmain.sh missing +am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/generated.mk \ + $(srcdir)/qmckl.pc.in $(top_srcdir)/include/config.h.in \ + AUTHORS COPYING ChangeLog INSTALL NEWS README compile \ + config.guess config.sub depcomp install-sh ltmain.sh missing DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) distdir = $(PACKAGE)-$(VERSION) top_distdir = $(distdir) @@ -281,7 +293,6 @@ CFLAGS = @CFLAGS@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ CYGPATH_W = @CYGPATH_W@ -C_FILES = @C_FILES@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DLLTOOL = @DLLTOOL@ @@ -298,15 +309,8 @@ FCFLAGS = @FCFLAGS@ FCFLAGS_f90 = @FCFLAGS_f90@ FCLIBS = @FCLIBS@ FGREP = @FGREP@ -FH_FUNC_FILES = @FH_FUNC_FILES@ -FH_TYPE_FILES = @FH_TYPE_FILES@ -F_FILES = @F_FILES@ GREP = @GREP@ HAS_CPPCHECK = @HAS_CPPCHECK@ -H_FUNC_FILES = @H_FUNC_FILES@ -H_PRIVATE_FUNC_FILES = @H_PRIVATE_FUNC_FILES@ -H_PRIVATE_TYPE_FILES = @H_PRIVATE_TYPE_FILES@ -H_TYPE_FILES = @H_TYPE_FILES@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ @@ -329,7 +333,6 @@ NM = @NM@ NMEDIT = @NMEDIT@ OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -ORG_FILES = @ORG_FILES@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ @@ -409,15 +412,50 @@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ ACLOCAL_AMFLAGS = -I m4 -SUBDIRS = src +SUBDIRS = +CLEANFILES = $(am__append_1) pkgconfigdir = $(libdir)/pkgconfig -pkgconfig_DATA = qmckl.pc -all: all-recursive +pkgconfig_DATA = $(srcdir)/qmckl.pc +qmckl_h = $(srcdir)/include/qmckl.h +include_HEADERS = $(qmckl_h) +qmckl_f = $(srcdir)/share/qmckl/fortran/qmckl_f.f90 +fortrandir = $(datadir)/$(PACKAGE_NAME)/fortran/ +fortran_DATA = $(qmckl_f) +sources_tangled = src/qmckl_ao.c + +# <----- +@QMCKL_DEVEL_TRUE@dist_src_DATA = $(ORG_FILES) +@QMCKL_DEVEL_TRUE@BUILT_SOURCES = $(C_FILES) $(F_FILES) $(FH_FUNC_FILES) $(FH_TYPE_FILES) $(H_FUNC_FILES) $(H_TYPE_FILES) $(H_PRIVATE_FUNC_FILES) $(H_PRIVATE_TYPE_FILES) + +# -----> +tangle_verbose = $(tangle_verbose_@AM_V@) +tangle_verbose_ = $(tangle_verbose_@AM_DEFAULT_V@) +tangle_verbose_0 = @echo " TANGLE $@"; +cat_h_verbose = $(cat_h_verbose_@AM_V@) +cat_h_verbose_ = $(cat_h_verbose_@AM_DEFAULT_V@) +cat_h_verbose_0 = @echo " HEADER $@"; +ORG_FILES = $(srcdir)/org/qmckl_ao.org $(srcdir)/org/qmckl_context.org $(srcdir)/org/qmckl_distance.org $(srcdir)/org/qmckl_electron.org $(srcdir)/org/qmckl_error.org $(srcdir)/org/qmckl_memory.org $(srcdir)/org/qmckl_numprec.org $(srcdir)/org/qmckl.org $(srcdir)/org/README.org $(srcdir)/org/test_qmckl.org +C_FILES = $(srcdir)/src/qmckl_ao.c $(srcdir)/src/qmckl_context.c $(srcdir)/src/qmckl_electron.c $(srcdir)/src/qmckl_error.c $(srcdir)/src/qmckl_memory.c $(srcdir)/src/qmckl_numprec.c +F_FILES = $(srcdir)/src/qmckl_ao_f.f90 $(srcdir)/src/qmckl_distance_f.f90 $(srcdir)/src/qmckl_electron_f.f90 +C_O_FILES = $(srcdir)/src/qmckl_ao.o $(srcdir)/src/qmckl_context.o $(srcdir)/src/qmckl_electron.o $(srcdir)/src/qmckl_error.o $(srcdir)/src/qmckl_memory.o $(srcdir)/src/qmckl_numprec.o +F_O_FILES = +FH_FUNC_FILES = $(srcdir)/src/qmckl_ao_fh_func.f90 $(srcdir)/src/qmckl_context_fh_func.f90 $(srcdir)/src/qmckl_distance_fh_func.f90 $(srcdir)/src/qmckl_error_fh_func.f90 $(srcdir)/src/qmckl_numprec_fh_func.f90 +FH_TYPE_FILES = $(srcdir)/src/qmckl_context_fh_type.f90 $(srcdir)/src/qmckl_error_fh_type.f90 +H_FUNC_FILES = $(srcdir)/src/qmckl_ao_func.h $(srcdir)/src/qmckl_context_func.h $(srcdir)/src/qmckl_distance_func.h $(srcdir)/src/qmckl_electron_func.h $(srcdir)/src/qmckl_error_func.h $(srcdir)/src/qmckl_memory_func.h $(srcdir)/src/qmckl_numprec_func.h +H_TYPE_FILES = $(srcdir)/src/qmckl_context_type.h $(srcdir)/src/qmckl_error_type.h $(srcdir)/src/qmckl_numprec_type.h +H_PRIVATE_FUNC_FILES = $(srcdir)/src/qmckl_ao_private_func.h $(srcdir)/src/qmckl_electron_private_func.h $(srcdir)/src/qmckl_memory_private_func.h +H_PRIVATE_TYPE_FILES = $(srcdir)/src/qmckl_ao_private_type.h $(srcdir)/src/qmckl_context_private_type.h $(srcdir)/src/qmckl_electron_private_type.h $(srcdir)/src/qmckl_error_private_type.h $(srcdir)/src/qmckl_memory_private_type.h $(srcdir)/src/qmckl_numprec_private_type.h +C_TEST_FILES = $(srcdir)/src/test_qmckl_ao.c $(srcdir)/src/test_qmckl_context.c $(srcdir)/src/test_qmckl_distance.c $(srcdir)/src/test_qmckl_electron.c $(srcdir)/src/test_qmckl_error.c $(srcdir)/src/test_qmckl_memory.c $(srcdir)/src/test_qmckl_numprec.c +F_TEST_FILES = $(srcdir)/src/test_qmckl_ao_f.f90 $(srcdir)/src/test_qmckl_distance_f.f90 +SUFFIXES = .f90 .h .org .c _f.f90 _func.h _type.h _private_func.h _private_type.h +all: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) all-recursive .SUFFIXES: +.SUFFIXES: .f90 .h .org .c _f.f90 _func.h _type.h _private_func.h _private_type.h am--refresh: Makefile @: -$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) +$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(srcdir)/generated.mk $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ @@ -439,6 +477,7 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__maybe_remake_depfiles)'; \ cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__maybe_remake_depfiles);; \ esac; +$(srcdir)/generated.mk $(am__empty): $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) $(SHELL) ./config.status --recheck @@ -474,6 +513,48 @@ clean-libtool: distclean-libtool: -rm -f libtool config.lt +install-dist_srcDATA: $(dist_src_DATA) + @$(NORMAL_INSTALL) + @list='$(dist_src_DATA)'; test -n "$(srcdir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(srcdir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(srcdir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(srcdir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(srcdir)" || exit $$?; \ + done + +uninstall-dist_srcDATA: + @$(NORMAL_UNINSTALL) + @list='$(dist_src_DATA)'; test -n "$(srcdir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + dir='$(DESTDIR)$(srcdir)'; $(am__uninstall_files_from_dir) +install-fortranDATA: $(fortran_DATA) + @$(NORMAL_INSTALL) + @list='$(fortran_DATA)'; test -n "$(fortrandir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(fortrandir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(fortrandir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(fortrandir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(fortrandir)" || exit $$?; \ + done + +uninstall-fortranDATA: + @$(NORMAL_UNINSTALL) + @list='$(fortran_DATA)'; test -n "$(fortrandir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + dir='$(DESTDIR)$(fortrandir)'; $(am__uninstall_files_from_dir) install-pkgconfigDATA: $(pkgconfig_DATA) @$(NORMAL_INSTALL) @list='$(pkgconfig_DATA)'; test -n "$(pkgconfigdir)" || list=; \ @@ -495,6 +576,27 @@ uninstall-pkgconfigDATA: @list='$(pkgconfig_DATA)'; test -n "$(pkgconfigdir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ dir='$(DESTDIR)$(pkgconfigdir)'; $(am__uninstall_files_from_dir) +install-includeHEADERS: $(include_HEADERS) + @$(NORMAL_INSTALL) + @list='$(include_HEADERS)'; test -n "$(includedir)" || list=; \ + if test -n "$$list"; then \ + echo " $(MKDIR_P) '$(DESTDIR)$(includedir)'"; \ + $(MKDIR_P) "$(DESTDIR)$(includedir)" || exit 1; \ + fi; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(includedir)'"; \ + $(INSTALL_HEADER) $$files "$(DESTDIR)$(includedir)" || exit $$?; \ + done + +uninstall-includeHEADERS: + @$(NORMAL_UNINSTALL) + @list='$(include_HEADERS)'; test -n "$(includedir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + dir='$(DESTDIR)$(includedir)'; $(am__uninstall_files_from_dir) # This directory's subdirectories are mostly independent; you can cd # into them and run 'make' without going through this Makefile. @@ -794,14 +896,16 @@ distcleancheck: distclean $(distcleancheck_listfiles) ; \ exit 1; } >&2 check-am: all-am -check: check-recursive -all-am: Makefile $(DATA) +check: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) check-recursive +all-am: Makefile $(DATA) $(HEADERS) installdirs: installdirs-recursive installdirs-am: - for dir in "$(DESTDIR)$(pkgconfigdir)"; do \ + for dir in "$(DESTDIR)$(srcdir)" "$(DESTDIR)$(fortrandir)" "$(DESTDIR)$(pkgconfigdir)" "$(DESTDIR)$(includedir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done -install: install-recursive +install: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) install-recursive install-exec: install-exec-recursive install-data: install-data-recursive uninstall: uninstall-recursive @@ -823,6 +927,7 @@ install-strip: mostlyclean-generic: clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) @@ -831,6 +936,7 @@ distclean-generic: maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." + -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) clean: clean-recursive clean-am: clean-generic clean-libtool mostlyclean-am @@ -853,7 +959,8 @@ info: info-recursive info-am: -install-data-am: install-pkgconfigDATA +install-data-am: install-dist_srcDATA install-fortranDATA \ + install-includeHEADERS install-pkgconfigDATA install-dvi: install-dvi-recursive @@ -899,9 +1006,11 @@ ps: ps-recursive ps-am: -uninstall-am: uninstall-pkgconfigDATA +uninstall-am: uninstall-dist_srcDATA uninstall-fortranDATA \ + uninstall-includeHEADERS uninstall-pkgconfigDATA -.MAKE: $(am__recursive_targets) install-am install-strip +.MAKE: $(am__recursive_targets) all check install install-am \ + install-strip .PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am \ am--refresh check check-am clean clean-cscope clean-generic \ @@ -911,18 +1020,85 @@ uninstall-am: uninstall-pkgconfigDATA distclean-hdr distclean-libtool distclean-tags distcleancheck \ distdir distuninstallcheck dvi dvi-am html html-am info \ info-am install install-am install-data install-data-am \ - install-dvi install-dvi-am install-exec install-exec-am \ - install-html install-html-am install-info install-info-am \ - install-man install-pdf install-pdf-am install-pkgconfigDATA \ - install-ps install-ps-am install-strip installcheck \ - installcheck-am installdirs installdirs-am maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-generic \ - mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \ - uninstall-am uninstall-pkgconfigDATA + install-dist_srcDATA install-dvi install-dvi-am install-exec \ + install-exec-am install-fortranDATA install-html \ + install-html-am install-includeHEADERS install-info \ + install-info-am install-man install-pdf install-pdf-am \ + install-pkgconfigDATA install-ps install-ps-am install-strip \ + installcheck installcheck-am installdirs installdirs-am \ + maintainer-clean maintainer-clean-generic mostlyclean \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags tags-am uninstall uninstall-am uninstall-dist_srcDATA \ + uninstall-fortranDATA uninstall-includeHEADERS \ + uninstall-pkgconfigDATA .PRECIOUS: Makefile +export srcdir qmckl_f qmckl_h + +$(srcdir)/src/qmckl_context.c $(srcdir)/src/qmckl_context_func.h $(srcdir)/src/qmckl_context_type.h $(srcdir)/src/qmckl_context_private_type.h $(srcdir)/src/qmckl_context_fh_func.f90 $(srcdir)/src/qmckl_context_fh_type.f90 $(srcdir)/src/test_qmckl_context.c : org/qmckl_context.org + $(tangle_verbose)$(srcdir)/tools/tangle.sh org/qmckl_context.org + +$(srcdir)/src/qmckl_ao.c $(srcdir)/src/qmckl_ao_func.h $(srcdir)/src/qmckl_ao_private_type.h $(srcdir)/src/qmckl_ao_private_func.h $(srcdir)/src/qmckl_ao_f.f90 $(srcdir)/src/qmckl_ao_fh_func.f90 $(srcdir)/src/test_qmckl_ao.c $(srcdir)/src/test_qmckl_ao_f.f90 : org/qmckl_ao.org + $(tangle_verbose)$(srcdir)/tools/tangle.sh org/qmckl_ao.org + +$(srcdir)/src/qmckl_numprec.c $(srcdir)/src/qmckl_numprec_func.h $(srcdir)/src/qmckl_numprec_type.h $(srcdir)/src/qmckl_numprec_private_type.h $(srcdir)/src/qmckl_numprec_fh_func.f90 $(srcdir)/src/test_qmckl_numprec.c : org/qmckl_numprec.org + $(tangle_verbose)$(srcdir)/tools/tangle.sh org/qmckl_numprec.org + +$(srcdir)/src/qmckl_electron.c $(srcdir)/src/qmckl_electron_func.h $(srcdir)/src/qmckl_electron_private_type.h $(srcdir)/src/qmckl_electron_private_func.h $(srcdir)/src/qmckl_electron_f.f90 $(srcdir)/src/test_qmckl_electron.c : org/qmckl_electron.org + $(tangle_verbose)$(srcdir)/tools/tangle.sh org/qmckl_electron.org + +$(srcdir)/src/qmckl_error.c $(srcdir)/src/qmckl_error_func.h $(srcdir)/src/qmckl_error_type.h $(srcdir)/src/qmckl_error_private_type.h $(srcdir)/src/qmckl_error_fh_func.f90 $(srcdir)/src/qmckl_error_fh_type.f90 $(srcdir)/src/test_qmckl_error.c : org/qmckl_error.org + $(tangle_verbose)$(srcdir)/tools/tangle.sh org/qmckl_error.org + +$(srcdir)/src/qmckl_distance_func.h $(srcdir)/src/qmckl_distance_f.f90 $(srcdir)/src/qmckl_distance_fh_func.f90 $(srcdir)/src/test_qmckl_distance.c $(srcdir)/src/test_qmckl_distance_f.f90 : org/qmckl_distance.org + $(tangle_verbose)$(srcdir)/tools/tangle.sh org/qmckl_distance.org + +$(srcdir)/src/qmckl_memory.c $(srcdir)/src/qmckl_memory_func.h $(srcdir)/src/qmckl_memory_private_type.h $(srcdir)/src/qmckl_memory_private_func.h $(srcdir)/src/test_qmckl_memory.c : org/qmckl_memory.org + $(tangle_verbose)$(srcdir)/tools/tangle.sh org/qmckl_memory.org + +$(srcdir)/src/qmckl_ao_f.o: $(srcdir)/src/qmckl_ao_f.f90 $(srcdir)/src/qmckl_ao_fh_func.f90 qmckl_f.o +$(srcdir)/src/qmckl_ao.o: $(srcdir)/src/qmckl_ao.c $(srcdir)/src/qmckl_ao_func.h $(srcdir)/src/qmckl_ao_private_type.h $(srcdir)/src/qmckl_ao_private_func.h $(qmckl_h) +$(srcdir)/src/qmckl_context_f.o: $(srcdir)/src/qmckl_context_fh_func.f90 $(srcdir)/src/qmckl_context_fh_type.f90 qmckl_f.o +$(srcdir)/src/qmckl_context.o: $(srcdir)/src/qmckl_context.c $(srcdir)/src/qmckl_context_func.h $(srcdir)/src/qmckl_context_type.h $(srcdir)/src/qmckl_context_private_type.h $(qmckl_h) +$(srcdir)/src/qmckl_distance_f.o: $(srcdir)/src/qmckl_distance_f.f90 $(srcdir)/src/qmckl_distance_fh_func.f90 qmckl_f.o +$(srcdir)/src/qmckl_distance.o: $(srcdir)/src/qmckl_distance_func.h $(qmckl_h) +$(srcdir)/src/qmckl_electron_f.o: $(srcdir)/src/qmckl_electron_f.f90 qmckl_f.o +$(srcdir)/src/qmckl_electron.o: $(srcdir)/src/qmckl_electron.c $(srcdir)/src/qmckl_electron_func.h $(srcdir)/src/qmckl_electron_private_type.h $(srcdir)/src/qmckl_electron_private_func.h $(qmckl_h) +$(srcdir)/src/qmckl_error_f.o: $(srcdir)/src/qmckl_error_fh_func.f90 $(srcdir)/src/qmckl_error_fh_type.f90 qmckl_f.o +$(srcdir)/src/qmckl_error.o: $(srcdir)/src/qmckl_error.c $(srcdir)/src/qmckl_error_func.h $(srcdir)/src/qmckl_error_type.h $(srcdir)/src/qmckl_error_private_type.h $(qmckl_h) +$(srcdir)/src/qmckl_memory.o: $(srcdir)/src/qmckl_memory.c $(srcdir)/src/qmckl_memory_func.h $(srcdir)/src/qmckl_memory_private_type.h $(srcdir)/src/qmckl_memory_private_func.h $(qmckl_h) +$(srcdir)/src/qmckl_numprec_f.o: $(srcdir)/src/qmckl_numprec_fh_func.f90 qmckl_f.o +$(srcdir)/src/qmckl_numprec.o: $(srcdir)/src/qmckl_numprec.c $(srcdir)/src/qmckl_numprec_func.h $(srcdir)/src/qmckl_numprec_type.h $(srcdir)/src/qmckl_numprec_private_type.h $(qmckl_h) +$(srcdir)/src/test_qmckl_ao_f.o: $(srcdir)/src/test_qmckl_ao_f.f90 $(srcdir)/src/qmckl_ao_f.o qmckl_f.o +$(srcdir)/src/test_qmckl_ao.o: $(srcdir)/src/test_qmckl_ao.c $(srcdir)/src/qmckl_ao.o $(qmckl_h) +$(srcdir)/src/test_qmckl_context.o: $(srcdir)/src/test_qmckl_context.c $(srcdir)/src/qmckl_context.o $(qmckl_h) +$(srcdir)/src/test_qmckl_distance_f.o: $(srcdir)/src/test_qmckl_distance_f.f90 $(srcdir)/src/qmckl_distance_f.o qmckl_f.o +$(srcdir)/src/test_qmckl_distance.o: $(srcdir)/src/test_qmckl_distance.c $(srcdir)/src/qmckl_distance.o $(qmckl_h) +$(srcdir)/src/test_qmckl_electron.o: $(srcdir)/src/test_qmckl_electron.c $(srcdir)/src/qmckl_electron.o $(qmckl_h) +$(srcdir)/src/test_qmckl_error.o: $(srcdir)/src/test_qmckl_error.c $(srcdir)/src/qmckl_error.o $(qmckl_h) +$(srcdir)/src/test_qmckl_memory.o: $(srcdir)/src/test_qmckl_memory.c $(srcdir)/src/qmckl_memory.o $(qmckl_h) +$(srcdir)/src/test_qmckl_numprec.o: $(srcdir)/src/test_qmckl_numprec.c $(srcdir)/src/qmckl_numprec.o $(qmckl_h) + +$(srcdir)/generated.mk: $(ORG_FILES) + $(srcdir)/tools/build_makefile.sh + +$(qmckl_h): $(H_FUNC_FILES) $(H_TYPE_FILES) + $(cat_h_verbose)$(srcdir)/tools/build_qmckl_h.sh + +$(qmckl_f): $(FH_FUNC_FILES) $(FH_TYPE_FILES) + $(cat_h_verbose)$(srcdir)/tools/build_qmckl_f.sh + +$(srcdir)/src/qmckl_f.f90: $(qmckl_f) + cp $(qmckl_f) $(srcdir)/src/qmckl_f.f90 + +#lib_LTLIBRARIES = $(top_srcdir)/src/libqmckl.la +# +#$(top_srcdir)/src/libqmckl.la; +# $(MAKE) -C src libqmckl.la +# + rpms srcrpm: for dir in $(SUBDIRS); do \ (cd $$dir && $(MAKE) $(AM_MAKEFLAGS) $@) || exit 1; \ @@ -930,9 +1106,6 @@ rpms srcrpm: .PHONY: rpms srcrpm -README: README.md -COPYING: LICENSE - # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: diff --git a/README b/README new file mode 120000 index 0000000..42061c0 --- /dev/null +++ b/README @@ -0,0 +1 @@ +README.md \ No newline at end of file diff --git a/README.md b/README.md index 46bf12d..757ce6e 100644 --- a/README.md +++ b/README.md @@ -31,7 +31,7 @@ in org-mode files and produce the source code and the documentation from these f ``` autoreconf -./configure --enable-maintainer-mode --enable-debug +QMCKL_DEVEL=1 ./configure --enable-debug make make check ``` diff --git a/configure.ac b/configure.ac index 177ffe5..1928515 100644 --- a/configure.ac +++ b/configure.ac @@ -41,7 +41,7 @@ AC_INIT([QMCkl],[0.1.1], AM_INIT_AUTOMAKE([color-tests parallel-tests silent-rules 1.11]) AM_MAINTAINER_MODE() LT_INIT -AC_CONFIG_SRCDIR([src/README.org]) +AC_CONFIG_SRCDIR([Makefile.in]) AC_CONFIG_HEADERS([include/config.h]) AC_CONFIG_MACRO_DIR([m4]) #AM_MAINTAINER_MODE @@ -148,29 +148,12 @@ if test "$ok" = "yes"; then ARGS="${ARGS} efence" fi -AC_ARG_WITH(munit, [AC_HELP_STRING([--without-munit],[use munit for testing])], ok=yes, ok=no) -if test "$ok" = "no"; then -AC_CHECK_FILE([munit/munit.h], [], - AC_MSG_ERROR([ - ------------------------------------------------- - Error: Git submodule for munit is not downloaded. - $ git submodule update --init - ------------------------------------------------- -]) ) -else - ARGS="${ARGS} munit" - AC_DEFINE(HAVE_MUNIT,1,[Define when using munit]) -fi - # Checks for header files. ## qmckl AC_CHECK_HEADERS([inttypes.h malloc.h stdint.h stdlib.h string.h strings.h unistd.h]) -## munit -AC_CHECK_HEADERS([fcntl.h langinfo.h limits.h locale.h mach/mach.h sys/time.h]) - # Checks for typedefs, structures, and compiler characteristics. ## qmckl @@ -181,10 +164,6 @@ AC_TYPE_SIZE_T AC_TYPE_UINT32_T AC_TYPE_UINT64_T -## munit -AC_TYPE_PID_T -AC_C_INLINE -AC_TYPE_SSIZE_T # Checks for library functions. @@ -192,16 +171,13 @@ AC_TYPE_SSIZE_T AC_FUNC_MALLOC AC_CHECK_FUNCS([memset strerror]) -## munit -AC_FUNC_REALLOC -AC_FUNC_STRERROR_R -AC_FUNC_FORK -AC_CHECK_FUNCS([clock_gettime dup2 gettimeofday nl_langinfo setlocale strcasecmp strtoul]) +# Development mode +AM_CONDITIONAL([QMCKL_DEVEL],[test "x$QMCKL_DEVEL" != x]) -if test "x${MAINT}" = "x${MAINTAINER_MODE_TRUE}"; then +if test "x${QMCKL_DEVEL}" != "x"; then AC_PROG_AWK - cd src && ../tools/create_makefile.sh && cd .. + ${srcdir}/tools/build_makefile.sh AC_CHECK_PROGS([EMACS],[emacs26 emacs],[no]) if test x${EMACS} == xno ; then @@ -216,17 +192,31 @@ if test "x${MAINT}" = "x${MAINTAINER_MODE_TRUE}"; then if test x${HAS_CPPCHECK} != xno ; then HAS_CPPCHECK=1 fi -fi -AC_SUBST([ORG_FILES]) -AC_SUBST([C_FILES]) -AC_SUBST([F_FILES]) -AC_SUBST([FH_FUNC_FILES]) -AC_SUBST([FH_TYPE_FILES]) -AC_SUBST([H_FUNC_FILES]) -AC_SUBST([H_TYPE_FILES]) -AC_SUBST([H_PRIVATE_FUNC_FILES]) -AC_SUBST([H_PRIVATE_TYPE_FILES]) + ## munit + AC_ARG_WITH(munit, [AC_HELP_STRING([--without-munit],[use munit for testing])], ok=yes, ok=no) + if test "$ok" = "no"; then + AC_CHECK_FILE([munit/munit.h], [], + AC_MSG_ERROR([ + ------------------------------------------------- + Error: Git submodule for munit is not downloaded. + $ git submodule update --init + ------------------------------------------------- + ]) ) + else + ARGS="${ARGS} munit" + AC_DEFINE(HAVE_MUNIT,1,[Define when using munit]) + fi + AC_CHECK_HEADERS([fcntl.h langinfo.h limits.h locale.h mach/mach.h sys/time.h]) + AC_TYPE_PID_T + AC_C_INLINE + AC_TYPE_SSIZE_T + AC_FUNC_REALLOC + AC_FUNC_STRERROR_R + AC_FUNC_FORK + AC_CHECK_FUNCS([clock_gettime dup2 gettimeofday nl_langinfo setlocale strcasecmp strtoul]) + +fi #PKG-CONFIG #mkl-dynamic-lp64-seq @@ -238,7 +228,7 @@ AC_SUBST([PKG_CFLAGS]) AC_CONFIG_FILES([Makefile qmckl.pc - src/Makefile]) + ]) AC_OUTPUT diff --git a/configure.ac.dist.in b/configure.ac.dist.in deleted file mode 100644 index bbe1ed3..0000000 --- a/configure.ac.dist.in +++ /dev/null @@ -1,168 +0,0 @@ -# -*- Autoconf -*- -# Process this file with autoconf to produce a configure script. -# -# configure script for maintainers. - -AC_PREREQ([2.69]) - -AC_INIT([@PACKAGE_NAME@],[@PACKAGE_VERSION@], - [@PACKAGE_BUGREPORT@], [], - [@PACKAGE_URL@]) - -AC_CONFIG_SRCDIR([src/qmckl_ao.c]) -AC_CONFIG_HEADERS([include/config.h]) -AC_CONFIG_MACRO_DIR([m4]) -#AM_MAINTAINER_MODE - -VERSION_MAJOR=`echo ${PACKAGE_VERSION} | cut -d. -f1` -VERSION_MINOR=`echo ${PACKAGE_VERSION} | cut -d. -f2` -VERSION_PATCH=`echo ${PACKAGE_VERSION} | cut -d. -f3 | cut -d- -f1` -AC_DEFINE_UNQUOTED(QMCKL_VERSION_MAJOR, [$VERSION_MAJOR], [major version]) -AC_DEFINE_UNQUOTED(QMCKL_VERSION_MINOR, [$VERSION_MINOR], [minor version]) -AC_DEFINE_UNQUOTED(QMCKL_VERSION_PATCH, [$VERSION_PATCH], [patch version]) - -#AM_INIT_AUTOMAKE([foreign color-tests parallel-tests silent-rules 1.11]) -#AM_SILENT_RULES(yes) -#AC_SUBST(SHARED_VERSION_INFO) -#AM_ENABLE_SHARED(no) dnl shared libs cause too many headaches to be default -#AC_PROG_LIBTOOL - -AC_LANG(C) - -# Checks for programs. -AC_PROG_CC -AC_PROG_CC_C_O -AC_PROG_FC -AC_PROG_FC_C_O -AC_FC_SRCEXT([f90]) -AC_FC_FREEFORM -AC_PROG_INSTALL -AC_PROG_LN_S -AC_PROG_CC_C99 -PKG_PROG_PKG_CONFIG() -PKG_LIBS="" -PKG_CFLAGS="" - -# fPIC option -AC_MSG_CHECKING(whether fPIC compiler option is accepted in C) -SAVED_CFLAGS="${CFLAGS}" -CFLAGS="${CFLAGS} -fPIC -Werror" -AC_COMPILE_IFELSE([AC_LANG_PROGRAM([], [return 0;])], - [AC_MSG_RESULT(yes) - CFLAGS="${SAVED_CFLAGS} -fPIC"], - [AC_MSG_RESULT(no) - CFLAGS="${SAVED_CFLAGS}"]) - -AC_MSG_CHECKING(whether fPIC compiler option is accepted in Fortran) -FCFLAGS="${FCFLAGS} -fPIC -Werror" -SAVED_FCFLAGS="${FCFLAGS}" -AC_LANG_PUSH(Fortran) -AC_COMPILE_IFELSE([AC_LANG_PROGRAM([], [])], - [AC_MSG_RESULT(yes) - FCFLAGS="${SAVED_FCFLAGS} -fPIC"], - [AC_MSG_RESULT(no) - FCFLAGS="${SAVED_FCFLAGS}"]) -AC_LANG_POP() - -# Checks for libraries. - -AC_FC_LIBRARY_LDFLAGS - -AC_CHECK_LIB([m], [sqrt]) -AC_CHECK_HEADERS([assert.h errno.h malloc.h math.h pthread.h stdbool.h stdint.h stdio.h stdlib.h string.h]) - -## pthread -AC_CHECK_LIB([pthread], [pthread_create]) - -# OpenMP -AC_ARG_WITH(openmp, [AC_HELP_STRING([--with-openmp],[enable OpenMP])], with_omp=$withval, with_omp=no) -if test "x$with_omp" = xyes; then - AC_DEFINE([USE_OPENMP], [1], [Define to use OpenMP threading.]) - AX_OPENMP([], - [AC_MSG_ERROR([Could not find OpenMP flags; configure with --without-openmp])]) - CFLAGS="${CFLAGS} ${OPENMP_CFLAGS}" -fi - - -## BLAS -AX_BLAS([], [AC_MSG_ERROR([BLAS was not found.])]) - -## LAPACK -AX_LAPACK([], [AC_MSG_ERROR([LAPACK was not found.])]) - -# Checks for header files. - -## qmckl -AC_CHECK_HEADERS([inttypes.h malloc.h stdint.h stdlib.h string.h strings.h unistd.h]) - -# Checks for typedefs, structures, and compiler characteristics. - -## qmckl -AC_CHECK_HEADER_STDBOOL -AC_TYPE_INT32_T -AC_TYPE_INT64_T -AC_TYPE_SIZE_T -AC_TYPE_UINT32_T -AC_TYPE_UINT64_T - -# Checks for library functions. - -## qmckl -AC_FUNC_MALLOC -AC_CHECK_FUNCS([memset strerror]) - -# Options. - -AC_ARG_ENABLE(debug, [AC_HELP_STRING([--enable-debug],[compile for debugging])], ok=$enableval, ok=no) -if test "$ok" = "yes"; then - if test "$GCC" = "yes"; then - CFLAGS="$CFLAGS \ --Wall -W -Wbad-function-cast -Wcast-qual \ --Wpointer-arith -Wcast-align -Wpedantic -Wextra -fmax-errors=3" - fi - if test "$GFC" = "yes"; then - FCFLAGS="$FCFLAGS \ --fcheck=all -Waliasing -Wampersand -Wconversion \ --Wsurprising -ffpe-trap=zero,overflow,underflow \ --Wintrinsics-std -Wno-tabs -Wintrinsic-shadow -Wline-truncation \ --Wreal-q-constant -Wuninitialized -fbacktrace -finit-real=nan" - fi - if test "$FC" = "ifort"; then - FCFLAGS="$FCFLAGS \ --traceback -check all -debug all -fpe-all=0 -implicitnone" - fi - AC_DEFINE(DEBUG,1,[Define to turn on debugging checks]) -fi - -AC_ARG_ENABLE(debug-malloc, [AC_HELP_STRING([--enable-debug-malloc],[use debug malloc/free])], ok=$enableval, ok=no) -if test "$ok" = "yes"; then - AC_DEFINE(DEBUG_MALLOC,1,[Define to use debugging malloc/free]) -fi - -AC_ARG_ENABLE(prof, [AC_HELP_STRING([--enable-prof],[compile for profiling])], ok=$enableval, ok=no) -if test "$ok" = "yes"; then - CFLAGS="${CFLAGS} -pg" - AC_DEFINE(ENABLE_PROF,1,[Define when using the profiler tool]) -fi - -AC_ARG_WITH(efence, [AC_HELP_STRING([--with-efence],[use ElectricFence library])], ok=$withval, ok=no) -if test "$ok" = "yes"; then - AC_CHECK_LIB(efence, malloc) -fi - - -#PKG-CONFIG -#mkl-dynamic-lp64-seq - -LIBS="${LAPACK_LIBS} ${BLAS_LIBS} ${LIBS}" -PKG_LIBS="${PKG_LIBS} ${LIBS}" -AC_SUBST([PKG_LIBS]) -AC_SUBST([PKG_CFLAGS]) - -AC_CONFIG_FILES([Makefile - qmckl.pc - src/Makefile - ]) - - -AC_OUTPUT diff --git a/include/.gitignore b/include/.gitignore index 8b13789..02c6f49 100644 --- a/include/.gitignore +++ b/include/.gitignore @@ -1 +1,3 @@ - +config.h.in +config.h +qmckl.h diff --git a/lib/.gitignore b/lib/.gitignore deleted file mode 100644 index 17eec9d..0000000 --- a/lib/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -libqmckl.so -libqmckl.a diff --git a/src/README.org b/org/README.org similarity index 100% rename from src/README.org rename to org/README.org diff --git a/src/hpc/qmckl_tile.org b/org/hpc/qmckl_tile.org similarity index 100% rename from src/hpc/qmckl_tile.org rename to org/hpc/qmckl_tile.org diff --git a/src/qmckl.org b/org/qmckl.org similarity index 100% rename from src/qmckl.org rename to org/qmckl.org diff --git a/src/qmckl_ao.org b/org/qmckl_ao.org similarity index 100% rename from src/qmckl_ao.org rename to org/qmckl_ao.org diff --git a/src/qmckl_context.org b/org/qmckl_context.org similarity index 100% rename from src/qmckl_context.org rename to org/qmckl_context.org diff --git a/src/qmckl_distance.org b/org/qmckl_distance.org similarity index 100% rename from src/qmckl_distance.org rename to org/qmckl_distance.org diff --git a/src/qmckl_electron.org b/org/qmckl_electron.org similarity index 100% rename from src/qmckl_electron.org rename to org/qmckl_electron.org diff --git a/src/qmckl_error.org b/org/qmckl_error.org similarity index 100% rename from src/qmckl_error.org rename to org/qmckl_error.org diff --git a/src/qmckl_memory.org b/org/qmckl_memory.org similarity index 100% rename from src/qmckl_memory.org rename to org/qmckl_memory.org diff --git a/src/qmckl_numprec.org b/org/qmckl_numprec.org similarity index 100% rename from src/qmckl_numprec.org rename to org/qmckl_numprec.org diff --git a/src/table_of_contents b/org/table_of_contents similarity index 100% rename from src/table_of_contents rename to org/table_of_contents diff --git a/src/test_qmckl.org b/org/test_qmckl.org similarity index 100% rename from src/test_qmckl.org rename to org/test_qmckl.org diff --git a/share/doc/qmckl/html/qmckl.css b/share/doc/qmckl/html/qmckl.css deleted file mode 100644 index cfc7a63..0000000 --- a/share/doc/qmckl/html/qmckl.css +++ /dev/null @@ -1,972 +0,0 @@ -/* Adapted from worg.css */ - -@import url(https://fonts.googleapis.com/css?family=Droid+Sans|Droid+Sans+Mono|Droid+Serif); - -@media all -{ - html { - margin: 0; - font: .9em/1.6em "Droid Serif", Cambria, Georgia, "DejaVu Serif", serif; - background-image: url(/img/org-mode-unicorn-logo-worg.png); - background-attachment: fixed; - background-position: right bottom; - background-repeat: no-repeat; - background-color: white; - } - - body { - font-size: 14pt; - line-height: 22pt; - color: black; - margin-top: 0; - } - - body #content { - padding-top: 2em; - margin: auto; - max-width: 70%; - background-color: white; - } - - body #support { - position: fixed; - top:0; - display:block; - font-size: 12pt; - right:0pt; - text-align: right; - padding: .2em 1em; - background: #EEE; - border-radius: 10px; - } - - body .title { - margin-left: 0px; - font-size: 22pt; - } - - #org-div-home-and-up{ - position: fixed; - right: 0.5em; - margin-top: 70px; - font-family:sans-serif; - } - - /* TOC inspired by http://jashkenas.github.com/coffee-script */ - #table-of-contents { - margin-top: 105px; - font-size: 10pt; - font-family:sans-serif; - position: fixed; - right: 0em; - top: 0em; - background: white; - line-height: 12pt; - text-align: right; - box-shadow: 0 0 1em #777777; - -webkit-box-shadow: 0 0 1em #777777; - -moz-box-shadow: 0 0 1em #777777; - -webkit-border-bottom-left-radius: 5px; - -moz-border-radius-bottomleft: 5px; - /* ensure doesn't flow off the screen when expanded */ - max-height: 80%; - overflow: auto; } - #table-of-contents h2 { - font-size: 13pt; - max-width: 9em; - border: 0; - font-weight: normal; - padding-left: 0.5em; - padding-right: 0.5em; - padding-top: 0.05em; - padding-bottom: 0.05em; } - #table-of-contents #text-table-of-contents { - display: none; - text-align: left; } - #table-of-contents:hover #text-table-of-contents { - display: block; - padding: 0.5em; - margin-top: -1.5em; } - - #license { - background-color: #eeeeee; - } - - h1 { - font-size:2.1em; - padding:0 0 30px 0; - margin-top: 10px; - margin-bottom: 10px; - margin-right: 7%; - color: grey; - } - - h2 { - font-family:sans-serif; - font-size:1.45em; - padding:10px 0 10px 0; - color: black; - border-bottom: 1px solid #ddd; - padding-top: 1.5em; - } - - .outline-text-2 { - margin-left: 0.1em - } - - h3 { - font-family:sans-serif; - font-size:1.3em; - color: grey; - margin-left: 0.6em; - padding-top: 1.5em; - } - - /* #A34D32;*/ - - - .outline-text-3 { - margin-left: 0.9em; - } - - h4 { - font-family:sans-serif; - font-size:1.2em; - margin-left: 1.2em; - color: #A5573E; - padding-top: 1.5em; - } - - .outline-text-4 { - margin-left: 1.45em; - } - - a {text-decoration: none; font-weight: 400;} - a:visited {text-decoration: none; font-weight: 400;} - a:hover {text-decoration: underline;} - - .todo { - color: #CA0000; - } - - .done { - color: #006666; - } - - .timestamp-kwd { - color: #444; - } - - .tag { - background-color: #ffff; - color: #ffff; - } - - li { - margin: .4em; - } - - table { - border: 1; - border-color: grey; - } - - thead { - border: 0; - } - - tbody { - border: 0; - } - - tr { - border: 0; - } - - td { - border-left: 0px; - border-right: 0px; - border-top: 0px; - border-bottom: 0px; - } - - th { - border-left: 0px; - border-right: 0px; - border-top: 1px solid grey; - border-bottom: 1px solid grey; - } - - code { - font-size: 100%; - color: black; - padding: 0px 0.2em; - } - - img { - border: 0; - } - - .share img { - opacity: .4; - -moz-opacity: .4; - filter: alpha(opacity=40); - } - - .share img:hover { - opacity: 1; - -moz-opacity: 1; - filter: alpha(opacity=100); - } - - pre { - font-family: Droid Sans Mono, Monaco, Consolas, "Lucida Console", monospace; - color: black; - font-size: 90%; - padding: 0.5em; - overflow: auto; - border: none; - background-color: #f2f2f2; - border-radius: 5px; - } - - .org-info-box { - clear:both; - margin-left:auto; - margin-right:auto; - padding:0.7em; - } - .org-info-box img { - float:left; - margin:0em 0.5em 0em 0em; - } - .org-info-box p { - margin:0em; - padding:0em; - } - - - .builtin { - /* font-lock-builtin-face */ - color: #f4a460; - } - .comment { - /* font-lock-comment-face */ - color: #737373; - } - .comment-delimiter { - /* font-lock-comment-delimiter-face */ - color: #666666; - } - .constant { - /* font-lock-constant-face */ - color: #db7093; - } - .doc { - /* font-lock-doc-face */ - color: #b3b3b3; - } - .function-name { - /* font-lock-function-name-face */ - color: #5f9ea0; - } - .headline { - /* headline-face */ - color: #ffffff; - background-color: #000000; - font-weight: bold; - } - .keyword { - /* font-lock-keyword-face */ - color: #4682b4; - } - .negation-char { - } - .regexp-grouping-backslash { - } - .regexp-grouping-construct { - } - .string { - /* font-lock-string-face */ - color: #ccc79a; - } - .todo-comment { - /* todo-comment-face */ - color: #ffffff; - background-color: #000000; - font-weight: bold; - } - .variable-name { - /* font-lock-variable-name-face */ - color: #ff6a6a; - } - .warning { - /* font-lock-warning-face */ - color: #ffffff; - background-color: #cd5c5c; - font-weight: bold; - } - .important { - /* font-lock-warning-face */ - background-color: #e3e3f7; - } - .exercise { - /* font-lock-warning-face */ - background-color: #e3f7e3; - } - .note { - /* font-lock-warning-face */ - background-color: #f7f7d9; - } - pre.a { - color: inherit; - background-color: inherit; - font: inherit; - text-decoration: inherit; - } - pre.a:hover { - text-decoration: underline; - } - - /* Styles for org-info.js */ - - .org-info-js_info-navigation - { - border-style:none; - } - - #org-info-js_console-label - { - font-size:10px; - font-weight:bold; - white-space:nowrap; - } - - .org-info-js_search-highlight - { - background-color:#ffff00; - color:#000000; - font-weight:bold; - } - - #org-info-js-window - { - border-bottom:1px solid black; - padding-bottom:10px; - margin-bottom:10px; - } - - - - .org-info-search-highlight - { - background-color:#adefef; /* same color as emacs default */ - color:#000000; - font-weight:bold; - } - - .org-bbdb-company { - /* bbdb-company */ - font-style: italic; - } - .org-bbdb-field-name { - } - .org-bbdb-field-value { - } - .org-bbdb-name { - /* bbdb-name */ - text-decoration: underline; - } - .org-bold { - /* bold */ - font-weight: bold; - } - .org-bold-italic { - /* bold-italic */ - font-weight: bold; - font-style: italic; - } - .org-border { - /* border */ - background-color: #000000; - } - .org-buffer-menu-buffer { - /* buffer-menu-buffer */ - font-weight: bold; - } - .org-builtin { - /* font-lock-builtin-face */ - color: #da70d6; - } - .org-button { - /* button */ - text-decoration: underline; - } - .org-c-nonbreakable-space { - /* c-nonbreakable-space-face */ - background-color: #ff0000; - font-weight: bold; - } - .org-calendar-today { - /* calendar-today */ - text-decoration: underline; - } - .org-comment { - /* font-lock-comment-face */ - color: #b22222; - } - .org-comment-delimiter { - /* font-lock-comment-delimiter-face */ - color: #b22222; - } - .org-constant { - /* font-lock-constant-face */ - color: #5f9ea0; - } - .org-cursor { - /* cursor */ - background-color: #000000; - } - .org-default { - /* default */ - color: #000000; - background-color: #ffffff; - } - .org-diary { - /* diary */ - color: #ff0000; - } - .org-doc { - /* font-lock-doc-face */ - color: #bc8f8f; - } - .org-escape-glyph { - /* escape-glyph */ - color: #a52a2a; - } - .org-file-name-shadow { - /* file-name-shadow */ - color: #7f7f7f; - } - .org-fixed-pitch { - } - .org-fringe { - /* fringe */ - background-color: #f2f2f2; - } - .org-function-name { - /* font-lock-function-name-face */ - color: #0000ff; - } - .org-header-line { - /* header-line */ - color: #333333; - background-color: #e5e5e5; - } - .org-help-argument-name { - /* help-argument-name */ - font-style: italic; - } - .org-highlight { - /* highlight */ - background-color: #b4eeb4; - } - .org-holiday { - /* holiday */ - background-color: #ffc0cb; - } - .org-info-header-node { - /* info-header-node */ - color: #a52a2a; - font-weight: bold; - font-style: italic; - } - .org-info-header-xref { - /* info-header-xref */ - color: #0000ff; - text-decoration: underline; - } - .org-info-menu-header { - /* info-menu-header */ - font-weight: bold; - } - .org-info-menu-star { - /* info-menu-star */ - color: #ff0000; - } - .org-info-node { - /* info-node */ - color: #a52a2a; - font-weight: bold; - font-style: italic; - } - .org-info-title-1 { - /* info-title-1 */ - font-size: 172%; - font-weight: bold; - } - .org-info-title-2 { - /* info-title-2 */ - font-size: 144%; - font-weight: bold; - } - .org-info-title-3 { - /* info-title-3 */ - font-size: 120%; - font-weight: bold; - } - .org-info-title-4 { - /* info-title-4 */ - font-weight: bold; - } - .org-info-xref { - /* info-xref */ - color: #0000ff; - text-decoration: underline; - } - .org-isearch { - /* isearch */ - color: #b0e2ff; - background-color: #cd00cd; - } - .org-italic { - /* italic */ - font-style: italic; - } - .org-keyword { - /* font-lock-keyword-face */ - color: #a020f0; - } - .org-lazy-highlight { - /* lazy-highlight */ - background-color: #afeeee; - } - .org-link { - /* link */ - color: #0000ff; - text-decoration: underline; - } - .org-link-visited { - /* link-visited */ - color: #8b008b; - text-decoration: underline; - } - .org-match { - /* match */ - background-color: #ffff00; - } - .org-menu { - } - .org-message-cited-text { - /* message-cited-text */ - color: #ff0000; - } - .org-message-header-cc { - /* message-header-cc */ - color: #191970; - } - .org-message-header-name { - /* message-header-name */ - color: #6495ed; - } - .org-message-header-newsgroups { - /* message-header-newsgroups */ - color: #00008b; - font-weight: bold; - font-style: italic; - } - .org-message-header-other { - /* message-header-other */ - color: #4682b4; - } - .org-message-header-subject { - /* message-header-subject */ - color: #000080; - font-weight: bold; - } - .org-message-header-to { - /* message-header-to */ - color: #191970; - font-weight: bold; - } - .org-message-header-xheader { - /* message-header-xheader */ - color: #0000ff; - } - .org-message-mml { - /* message-mml */ - color: #228b22; - } - .org-message-separator { - /* message-separator */ - color: #a52a2a; - } - .org-minibuffer-prompt { - /* minibuffer-prompt */ - color: #0000cd; - } - .org-mm-uu-extract { - /* mm-uu-extract */ - color: #006400; - background-color: #ffffe0; - } - .org-mode-line { - /* mode-line */ - color: #000000; - background-color: #bfbfbf; - } - .org-mode-line-buffer-id { - /* mode-line-buffer-id */ - font-weight: bold; - } - .org-mode-line-highlight { - } - .org-mode-line-inactive { - /* mode-line-inactive */ - color: #333333; - background-color: #e5e5e5; - } - .org-mouse { - /* mouse */ - background-color: #000000; - } - .org-negation-char { - } - .org-next-error { - /* next-error */ - background-color: #eedc82; - } - .org-nobreak-space { - /* nobreak-space */ - color: #a52a2a; - text-decoration: underline; - } - .org-org-agenda-date { - /* org-agenda-date */ - color: #0000ff; - } - .org-org-agenda-date-weekend { - /* org-agenda-date-weekend */ - color: #0000ff; - font-weight: bold; - } - .org-org-agenda-restriction-lock { - /* org-agenda-restriction-lock */ - background-color: #ffff00; - } - .org-org-agenda-structure { - /* org-agenda-structure */ - color: #0000ff; - } - .org-org-archived { - /* org-archived */ - color: #7f7f7f; - } - .org-org-code { - /* org-code */ - color: #7f7f7f; - } - .org-org-column { - /* org-column */ - background-color: #e5e5e5; - } - .org-org-column-title { - /* org-column-title */ - background-color: #e5e5e5; - font-weight: bold; - text-decoration: underline; - } - .org-org-date { - /* org-date */ - color: #a020f0; - text-decoration: underline; - } - .org-org-done { - /* org-done */ - color: #228b22; - font-weight: bold; - } - .org-org-drawer { - /* org-drawer */ - color: #0000ff; - } - .org-org-ellipsis { - /* org-ellipsis */ - color: #b8860b; - text-decoration: underline; - } - .org-org-formula { - /* org-formula */ - color: #b22222; - } - .org-org-headline-done { - /* org-headline-done */ - color: #bc8f8f; - } - .org-org-hide { - /* org-hide */ - color: #e5e5e5; - } - .org-org-latex-and-export-specials { - /* org-latex-and-export-specials */ - color: #8b4513; - } - .org-org-level-1 { - /* org-level-1 */ - color: #0000ff; - } - .org-org-level-2 { - /* org-level-2 */ - color: #b8860b; - } - .org-org-level-3 { - /* org-level-3 */ - color: #a020f0; - } - .org-org-level-4 { - /* org-level-4 */ - color: #b22222; - } - .org-org-level-5 { - /* org-level-5 */ - color: #228b22; - } - .org-org-level-6 { - /* org-level-6 */ - color: #5f9ea0; - } - .org-org-level-7 { - /* org-level-7 */ - color: #da70d6; - } - .org-org-level-8 { - /* org-level-8 */ - color: #bc8f8f; - } - .org-org-link { - /* org-link */ - color: #a020f0; - text-decoration: underline; - } - .org-org-property-value { - } - .org-org-scheduled-previously { - /* org-scheduled-previously */ - color: #b22222; - } - .org-org-scheduled-today { - /* org-scheduled-today */ - color: #006400; - } - .org-org-sexp-date { - /* org-sexp-date */ - color: #a020f0; - } - .org-org-special-keyword { - /* org-special-keyword */ - color: #bc8f8f; - } - .org-org-table { - /* org-table */ - color: #0000ff; - } - .org-org-tag { - /* org-tag */ - font-weight: bold; - } - .org-org-target { - /* org-target */ - text-decoration: underline; - } - .org-org-time-grid { - /* org-time-grid */ - color: #b8860b; - } - .org-org-todo { - /* org-todo */ - color: #ff0000; - } - .org-org-upcoming-deadline { - /* org-upcoming-deadline */ - color: #b22222; - } - .org-org-verbatim { - /* org-verbatim */ - color: #7f7f7f; - text-decoration: underline; - } - .org-org-warning { - /* org-warning */ - color: #ff0000; - font-weight: bold; - } - .org-outline-1 { - /* outline-1 */ - color: #0000ff; - } - .org-outline-2 { - /* outline-2 */ - color: #b8860b; - } - .org-outline-3 { - /* outline-3 */ - color: #a020f0; - } - .org-outline-4 { - /* outline-4 */ - color: #b22222; - } - .org-outline-5 { - /* outline-5 */ - color: #228b22; - } - .org-outline-6 { - /* outline-6 */ - color: #5f9ea0; - } - .org-outline-7 { - /* outline-7 */ - color: #da70d6; - } - .org-outline-8 { - /* outline-8 */ - color: #bc8f8f; - } - .outline-text-1, .outline-text-2, .outline-text-3, .outline-text-4, .outline-text-5, .outline-text-6 { - /* Add more spacing between section. Padding, so that folding with org-info.js works as expected. */ - - } - - .org-preprocessor { - /* font-lock-preprocessor-face */ - color: #da70d6; - } - .org-query-replace { - /* query-replace */ - color: #b0e2ff; - background-color: #cd00cd; - } - .org-regexp-grouping-backslash { - /* font-lock-regexp-grouping-backslash */ - font-weight: bold; - } - .org-regexp-grouping-construct { - /* font-lock-regexp-grouping-construct */ - font-weight: bold; - } - .org-region { - /* region */ - background-color: #eedc82; - } - .org-rmail-highlight { - } - .org-scroll-bar { - /* scroll-bar */ - background-color: #bfbfbf; - } - .org-secondary-selection { - /* secondary-selection */ - background-color: #ffff00; - } - .org-shadow { - /* shadow */ - color: #7f7f7f; - } - .org-show-paren-match { - /* show-paren-match */ - background-color: #40e0d0; - } - .org-show-paren-mismatch { - /* show-paren-mismatch */ - color: #ffffff; - background-color: #a020f0; - } - .org-string { - /* font-lock-string-face */ - color: #bc8f8f; - } - .org-texinfo-heading { - /* texinfo-heading */ - color: #0000ff; - } - .org-tool-bar { - /* tool-bar */ - color: #000000; - background-color: #bfbfbf; - } - .org-tooltip { - /* tooltip */ - color: #000000; - background-color: #ffffe0; - } - .org-trailing-whitespace { - /* trailing-whitespace */ - background-color: #ff0000; - } - .org-type { - /* font-lock-type-face */ - color: #228b22; - } - .org-underline { - /* underline */ - text-decoration: underline; - } - .org-variable-name { - /* font-lock-variable-name-face */ - color: #b8860b; - } - .org-variable-pitch { - } - .org-vertical-border { - } - .org-warning { - /* font-lock-warning-face */ - color: #ff0000; - font-weight: bold; - } - .rss_box {} - .rss_title, rss_title a {} - .rss_items {} - .rss_item a:link, .rss_item a:visited, .rss_item a:active {} - .rss_item a:hover {} - .rss_date {} - - pre.src { - position: static; - overflow: visible; - padding-top: 1.2em; - } - - label.org-src-name { - font-size: 80%; - font-style: italic; - } - - #show_source {margin: 0; padding: 0;} - - #postamble { - font-size: 75%; - min-width: 700px; - max-width: 80%; - line-height: 14pt; - margin-left: 20px; - margin-top: 10px; - padding: .2em; - background-color: #ffffff; - z-index: -1000; - } - - -} /* END OF @media all */ - -@media screen -{ - #table-of-contents { - position: fixed; - margin-top: 105px; - float: right; - border: 1px solid #red; - max-width: 50%; - overflow: auto; - } -} /* END OF @media screen */ diff --git a/src/Makefile.am b/src/Makefile.am index 28d84cd..1f1049c 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -8,14 +8,15 @@ libqmckl_la_version = $(VERSION_MAJOR).$(VERSION_MINOR) #lib_LTLIBRARIES = libqmckl-$(libqmckl_so_version).la lib_LTLIBRARIES = libqmckl.la + include generated.mk -qmckl_h = $(top_srcdir)/include/qmckl.h -qmckl_f = $(top_srcdir)/share/qmckl/fortran/qmckl_f.f90 BUILT_SOURCES= $(C_FILES) $(F_FILES) $(FH_FUNC_FILES) $(FH_TYPE_FILES) $(H_FUNC_FILES) $(H_TYPE_FILES) $(H_PRIVATE_FUNC_FILES) $(H_PRIVATE_TYPE_FILES) libqmckl_la_CPPFLAGS = -I$(srcdir) -I$(top_srcdir)/include -libqmckl_la_SOURCES = $(C_FILES) $(F_FILES) $(qmckl_h) $(qmckl_f) $(H_PRIVATE_FUNC_FILES) $(H_PRIVATE_TYPE_FILES) +libqmckl_la_SOURCES = qmckl.h qmckl_f.f90 $(C_FILES) $(F_FILES) $(H_FUNC_FILES) $(H_TYPE_FILES) $(H_PRIVATE_FUNC_FILES) $(H_PRIVATE_TYPE_FILES) + +dist_src_DATA = $(ORG_FILES) tangle_verbose = $(tangle_verbose_@AM_V@) tangle_verbose_ = $(tangle_verbose_@AM_DEFAULT_V@) @@ -25,32 +26,24 @@ cat_h_verbose = $(cat_h_verbose_@AM_V@) cat_h_verbose_ = $(cat_h_verbose_@AM_DEFAULT_V@) cat_h_verbose_0 = @echo " HEADER $@"; - +SUFFIXES = .f90 .h .org .c _f.f90 _func.h _type.h _private_func.h _private_type.h export top_srcdir +if QMCKL_DEVEL + Makefile.in: generated.mk generated.mk: $(ORG_FILES) - $(top_srcdir)/tools/create_makefile.sh + cd $(top_srcdir) && ./tools/create_makefile.sh qmckl.h qmckl_f.f90: $(FH_FUNC_FILES) $(H_FUNC_FILES) $(H_TYPE_FILES) $(cat_h_verbose)$(top_srcdir)/tools/build_qmckl_h.sh -SUFFIXES = .f90 .h .org .c - -.f90: $(ORG_FILES) - $(tangle_verbose)$(top_srcdir)/tools/tangle.sh $(ORG_FILES) - -.h: $(ORG_FILES) - $(tangle_verbose)$(top_srcdir)/tools/tangle.sh $(ORG_FILES) - -.org.c: +.org_private_func.h .org_private_type.h .org_type.h .org_func.h .org.h .org_f.f90 .org.c: $(tangle_verbose)$(top_srcdir)/tools/tangle.sh $< -$(qmckl_f): qmckl_f.f90 - mv qmckl_f.f90 $(qmckl_f) - -$(qmckl_h): qmckl.h - mv qmckl.h $(qmckl_h) +.h .f90 _f.f90 _func.h _type.h _private_func.h _private_type.h .c: $(ORG_FILES) +CLEANFILES = $(BUILT_SOURCES) $(C_TEST_FILES) $(F_TEST_FILES) qmckl_f.f90 qmckl.h +endif diff --git a/src/Makefile.in b/src/Makefile.in deleted file mode 100644 index 4e91b12..0000000 --- a/src/Makefile.in +++ /dev/null @@ -1,987 +0,0 @@ -# Makefile.in generated by automake 1.16.1 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2018 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -subdir = src -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \ - $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ - $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ - $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/include/config.h -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; -am__vpath_adj = case $$p in \ - $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ - *) f=$$p;; \ - esac; -am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; -am__install_max = 40 -am__nobase_strip_setup = \ - srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` -am__nobase_strip = \ - for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" -am__nobase_list = $(am__nobase_strip_setup); \ - for p in $$list; do echo "$$p $$p"; done | \ - sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ - $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ - if (++n[$$2] == $(am__install_max)) \ - { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ - END { for (dir in files) print dir, files[dir] }' -am__base_list = \ - sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ - sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' -am__uninstall_files_from_dir = { \ - test -z "$$files" \ - || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ - || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ - $(am__cd) "$$dir" && rm -f $$files; }; \ - } -am__installdirs = "$(DESTDIR)$(libdir)" -LTLIBRARIES = $(lib_LTLIBRARIES) -libqmckl_la_LIBADD = -am__objects_1 = libqmckl_la-qmckl_ao.lo libqmckl_la-qmckl_context.lo \ - libqmckl_la-qmckl_electron.lo libqmckl_la-qmckl_error.lo \ - libqmckl_la-qmckl_memory.lo libqmckl_la-qmckl_numprec.lo -am__objects_2 = qmckl_ao_f.lo qmckl_distance_f.lo qmckl_electron_f.lo -am__objects_3 = -am__objects_4 = qmckl_f.lo -am_libqmckl_la_OBJECTS = $(am__objects_1) $(am__objects_2) \ - $(am__objects_3) $(am__objects_4) $(am__objects_3) \ - $(am__objects_3) -libqmckl_la_OBJECTS = $(am_libqmckl_la_OBJECTS) -AM_V_lt = $(am__v_lt_@AM_V@) -am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) -am__v_lt_0 = --silent -am__v_lt_1 = -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/include -depcomp = $(SHELL) $(top_srcdir)/depcomp -am__maybe_remake_depfiles = depfiles -am__depfiles_remade = ./$(DEPDIR)/libqmckl_la-qmckl_ao.Plo \ - ./$(DEPDIR)/libqmckl_la-qmckl_context.Plo \ - ./$(DEPDIR)/libqmckl_la-qmckl_electron.Plo \ - ./$(DEPDIR)/libqmckl_la-qmckl_error.Plo \ - ./$(DEPDIR)/libqmckl_la-qmckl_memory.Plo \ - ./$(DEPDIR)/libqmckl_la-qmckl_numprec.Plo -am__mv = mv -f -COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ - $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ - $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ - $(AM_CFLAGS) $(CFLAGS) -AM_V_CC = $(am__v_CC_@AM_V@) -am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) -am__v_CC_0 = @echo " CC " $@; -am__v_CC_1 = -CCLD = $(CC) -LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ - $(AM_LDFLAGS) $(LDFLAGS) -o $@ -AM_V_CCLD = $(am__v_CCLD_@AM_V@) -am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) -am__v_CCLD_0 = @echo " CCLD " $@; -am__v_CCLD_1 = -FCCOMPILE = $(FC) $(AM_FCFLAGS) $(FCFLAGS) -LTFCCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -AM_V_FC = $(am__v_FC_@AM_V@) -am__v_FC_ = $(am__v_FC_@AM_DEFAULT_V@) -am__v_FC_0 = @echo " FC " $@; -am__v_FC_1 = -FCLD = $(FC) -FCLINK = $(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) \ - $(LIBTOOLFLAGS) --mode=link $(FCLD) $(AM_FCFLAGS) $(FCFLAGS) \ - $(AM_LDFLAGS) $(LDFLAGS) -o $@ -AM_V_FCLD = $(am__v_FCLD_@AM_V@) -am__v_FCLD_ = $(am__v_FCLD_@AM_DEFAULT_V@) -am__v_FCLD_0 = @echo " FCLD " $@; -am__v_FCLD_1 = -SOURCES = $(libqmckl_la_SOURCES) -DIST_SOURCES = $(libqmckl_la_SOURCES) -RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ - ctags-recursive dvi-recursive html-recursive info-recursive \ - install-data-recursive install-dvi-recursive \ - install-exec-recursive install-html-recursive \ - install-info-recursive install-pdf-recursive \ - install-ps-recursive install-recursive installcheck-recursive \ - installdirs-recursive pdf-recursive ps-recursive \ - tags-recursive uninstall-recursive -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ - distclean-recursive maintainer-clean-recursive -am__recursive_targets = \ - $(RECURSIVE_TARGETS) \ - $(RECURSIVE_CLEAN_TARGETS) \ - $(am__extra_recursive_targets) -AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ - distdir distdir-am -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -# Read a list of newline-separated strings from the standard input, -# and print each of them once, without duplicates. Input order is -# *not* preserved. -am__uniquify_input = $(AWK) '\ - BEGIN { nonempty = 0; } \ - { items[$$0] = 1; nonempty = 1; } \ - END { if (nonempty) { for (i in items) print i; }; } \ -' -# Make sure the list of sources is unique. This is necessary because, -# e.g., the same source file might be shared among _SOURCES variables -# for different programs/libraries. -am__define_uniq_tagged_files = \ - list='$(am__tagged_files)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | $(am__uniquify_input)` -ETAGS = etags -CTAGS = ctags -DIST_SUBDIRS = $(SUBDIRS) -am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/generated.mk \ - $(top_srcdir)/depcomp -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -am__relativize = \ - dir0=`pwd`; \ - sed_first='s,^\([^/]*\)/.*$$,\1,'; \ - sed_rest='s,^[^/]*/*,,'; \ - sed_last='s,^.*/\([^/]*\)$$,\1,'; \ - sed_butlast='s,/*[^/]*$$,,'; \ - while test -n "$$dir1"; do \ - first=`echo "$$dir1" | sed -e "$$sed_first"`; \ - if test "$$first" != "."; then \ - if test "$$first" = ".."; then \ - dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ - dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ - else \ - first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ - if test "$$first2" = "$$first"; then \ - dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ - else \ - dir2="../$$dir2"; \ - fi; \ - dir0="$$dir0"/"$$first"; \ - fi; \ - fi; \ - dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ - done; \ - reldir="$$dir2" -ACLOCAL = @ACLOCAL@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CYGPATH_W = @CYGPATH_W@ -C_FILES = qmckl_ao.c qmckl_context.c qmckl_electron.c qmckl_error.c qmckl_memory.c qmckl_numprec.c -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -EMACS = @EMACS@ -EXEEXT = @EXEEXT@ -FC = @FC@ -FCFLAGS = @FCFLAGS@ -FCFLAGS_f90 = @FCFLAGS_f90@ -FCLIBS = @FCLIBS@ -FGREP = @FGREP@ -FH_FUNC_FILES = qmckl_ao_fh_func.f90 qmckl_context_fh_func.f90 qmckl_distance_fh_func.f90 qmckl_error_fh_func.f90 qmckl_numprec_fh_func.f90 -FH_TYPE_FILES = qmckl_context_fh_type.f90 qmckl_error_fh_type.f90 -F_FILES = qmckl_ao_f.f90 qmckl_distance_f.f90 qmckl_electron_f.f90 -GREP = @GREP@ -HAS_CPPCHECK = @HAS_CPPCHECK@ -H_FUNC_FILES = qmckl_ao_func.h qmckl_context_func.h qmckl_distance_func.h qmckl_electron_func.h qmckl_error_func.h qmckl_memory_func.h qmckl_numprec_func.h -H_PRIVATE_FUNC_FILES = qmckl_ao_private_func.h qmckl_electron_private_func.h qmckl_memory_private_func.h -H_PRIVATE_TYPE_FILES = qmckl_ao_private_type.h qmckl_context_private_type.h qmckl_electron_private_type.h qmckl_error_private_type.h qmckl_memory_private_type.h qmckl_numprec_private_type.h -H_TYPE_FILES = qmckl_context_type.h qmckl_error_type.h qmckl_numprec_type.h -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LIBOBJS = @LIBOBJS@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ -MAINT = @MAINT@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -ORG_FILES = @ORG_FILES@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PKG_CFLAGS = @PKG_CFLAGS@ -PKG_CONFIG = @PKG_CONFIG@ -PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ -PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ -PKG_LIBS = @PKG_LIBS@ -RANLIB = @RANLIB@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -STRIP = @STRIP@ -VERSION = @VERSION@ -VERSION_MAJOR = @VERSION_MAJOR@ -VERSION_MINOR = @VERSION_MINOR@ -VERSION_PATCH = @VERSION_PATCH@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -ac_ct_FC = @ac_ct_FC@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pdfdir = @pdfdir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -runstatedir = @runstatedir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -LC_MESSAGES = C -SUBDIRS = -libqmckl_la_version = $(VERSION_MAJOR).$(VERSION_MINOR) - -#lib_LTLIBRARIES = libqmckl-$(libqmckl_so_version).la -lib_LTLIBRARIES = libqmckl.la -C_TEST_FILES = test_qmckl_ao.c test_qmckl_context.c test_qmckl_distance.c test_qmckl_electron.c test_qmckl_error.c test_qmckl_memory.c test_qmckl_numprec.c -F_TEST_FILES = test_qmckl_ao_f.f90 test_qmckl_distance_f.f90 -qmckl_h = $(top_srcdir)/include/qmckl.h -qmckl_f = $(top_srcdir)/share/qmckl/fortran/qmckl_f.f90 -BUILT_SOURCES = $(C_FILES) $(F_FILES) $(FH_FUNC_FILES) $(FH_TYPE_FILES) $(H_FUNC_FILES) $(H_TYPE_FILES) $(H_PRIVATE_FUNC_FILES) $(H_PRIVATE_TYPE_FILES) -libqmckl_la_CPPFLAGS = -I$(srcdir) -I$(top_srcdir)/include -libqmckl_la_SOURCES = $(C_FILES) $(F_FILES) $(qmckl_h) $(qmckl_f) $(H_PRIVATE_FUNC_FILES) $(H_PRIVATE_TYPE_FILES) -tangle_verbose = $(tangle_verbose_@AM_V@) -tangle_verbose_ = $(tangle_verbose_@AM_DEFAULT_V@) -tangle_verbose_0 = @echo " TANGLE $@"; -cat_h_verbose = $(cat_h_verbose_@AM_V@) -cat_h_verbose_ = $(cat_h_verbose_@AM_DEFAULT_V@) -cat_h_verbose_0 = @echo " HEADER $@"; -SUFFIXES = .f90 .h .org .c -all: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) all-recursive - -.SUFFIXES: -.SUFFIXES: .f90 .h .org .c .lo .o .obj -$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(srcdir)/generated.mk $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu src/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --gnu src/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ - esac; -$(srcdir)/generated.mk $(am__empty): - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): - -install-libLTLIBRARIES: $(lib_LTLIBRARIES) - @$(NORMAL_INSTALL) - @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ - list2=; for p in $$list; do \ - if test -f $$p; then \ - list2="$$list2 $$p"; \ - else :; fi; \ - done; \ - test -z "$$list2" || { \ - echo " $(MKDIR_P) '$(DESTDIR)$(libdir)'"; \ - $(MKDIR_P) "$(DESTDIR)$(libdir)" || exit 1; \ - echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(libdir)'"; \ - $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(libdir)"; \ - } - -uninstall-libLTLIBRARIES: - @$(NORMAL_UNINSTALL) - @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ - for p in $$list; do \ - $(am__strip_dir) \ - echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(libdir)/$$f'"; \ - $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(libdir)/$$f"; \ - done - -clean-libLTLIBRARIES: - -test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES) - @list='$(lib_LTLIBRARIES)'; \ - locs=`for p in $$list; do echo $$p; done | \ - sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ - sort -u`; \ - test -z "$$locs" || { \ - echo rm -f $${locs}; \ - rm -f $${locs}; \ - } - -libqmckl.la: $(libqmckl_la_OBJECTS) $(libqmckl_la_DEPENDENCIES) $(EXTRA_libqmckl_la_DEPENDENCIES) - $(AM_V_FCLD)$(FCLINK) -rpath $(libdir) $(libqmckl_la_OBJECTS) $(libqmckl_la_LIBADD) $(LIBS) - -mostlyclean-compile: - -rm -f *.$(OBJEXT) - -distclean-compile: - -rm -f *.tab.c - -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libqmckl_la-qmckl_ao.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libqmckl_la-qmckl_context.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libqmckl_la-qmckl_electron.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libqmckl_la-qmckl_error.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libqmckl_la-qmckl_memory.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libqmckl_la-qmckl_numprec.Plo@am__quote@ # am--include-marker - -$(am__depfiles_remade): - @$(MKDIR_P) $(@D) - @echo '# dummy' >$@-t && $(am__mv) $@-t $@ - -am--depfiles: $(am__depfiles_remade) - -.c.o: -@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< - -.c.obj: -@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` - -.c.lo: -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< - -libqmckl_la-qmckl_ao.lo: qmckl_ao.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libqmckl_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT libqmckl_la-qmckl_ao.lo -MD -MP -MF $(DEPDIR)/libqmckl_la-qmckl_ao.Tpo -c -o libqmckl_la-qmckl_ao.lo `test -f 'qmckl_ao.c' || echo '$(srcdir)/'`qmckl_ao.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libqmckl_la-qmckl_ao.Tpo $(DEPDIR)/libqmckl_la-qmckl_ao.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='qmckl_ao.c' object='libqmckl_la-qmckl_ao.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libqmckl_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o libqmckl_la-qmckl_ao.lo `test -f 'qmckl_ao.c' || echo '$(srcdir)/'`qmckl_ao.c - -libqmckl_la-qmckl_context.lo: qmckl_context.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libqmckl_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT libqmckl_la-qmckl_context.lo -MD -MP -MF $(DEPDIR)/libqmckl_la-qmckl_context.Tpo -c -o libqmckl_la-qmckl_context.lo `test -f 'qmckl_context.c' || echo '$(srcdir)/'`qmckl_context.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libqmckl_la-qmckl_context.Tpo $(DEPDIR)/libqmckl_la-qmckl_context.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='qmckl_context.c' object='libqmckl_la-qmckl_context.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libqmckl_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o libqmckl_la-qmckl_context.lo `test -f 'qmckl_context.c' || echo '$(srcdir)/'`qmckl_context.c - -libqmckl_la-qmckl_electron.lo: qmckl_electron.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libqmckl_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT libqmckl_la-qmckl_electron.lo -MD -MP -MF $(DEPDIR)/libqmckl_la-qmckl_electron.Tpo -c -o libqmckl_la-qmckl_electron.lo `test -f 'qmckl_electron.c' || echo '$(srcdir)/'`qmckl_electron.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libqmckl_la-qmckl_electron.Tpo $(DEPDIR)/libqmckl_la-qmckl_electron.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='qmckl_electron.c' object='libqmckl_la-qmckl_electron.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libqmckl_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o libqmckl_la-qmckl_electron.lo `test -f 'qmckl_electron.c' || echo '$(srcdir)/'`qmckl_electron.c - -libqmckl_la-qmckl_error.lo: qmckl_error.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libqmckl_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT libqmckl_la-qmckl_error.lo -MD -MP -MF $(DEPDIR)/libqmckl_la-qmckl_error.Tpo -c -o libqmckl_la-qmckl_error.lo `test -f 'qmckl_error.c' || echo '$(srcdir)/'`qmckl_error.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libqmckl_la-qmckl_error.Tpo $(DEPDIR)/libqmckl_la-qmckl_error.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='qmckl_error.c' object='libqmckl_la-qmckl_error.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libqmckl_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o libqmckl_la-qmckl_error.lo `test -f 'qmckl_error.c' || echo '$(srcdir)/'`qmckl_error.c - -libqmckl_la-qmckl_memory.lo: qmckl_memory.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libqmckl_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT libqmckl_la-qmckl_memory.lo -MD -MP -MF $(DEPDIR)/libqmckl_la-qmckl_memory.Tpo -c -o libqmckl_la-qmckl_memory.lo `test -f 'qmckl_memory.c' || echo '$(srcdir)/'`qmckl_memory.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libqmckl_la-qmckl_memory.Tpo $(DEPDIR)/libqmckl_la-qmckl_memory.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='qmckl_memory.c' object='libqmckl_la-qmckl_memory.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libqmckl_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o libqmckl_la-qmckl_memory.lo `test -f 'qmckl_memory.c' || echo '$(srcdir)/'`qmckl_memory.c - -libqmckl_la-qmckl_numprec.lo: qmckl_numprec.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libqmckl_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT libqmckl_la-qmckl_numprec.lo -MD -MP -MF $(DEPDIR)/libqmckl_la-qmckl_numprec.Tpo -c -o libqmckl_la-qmckl_numprec.lo `test -f 'qmckl_numprec.c' || echo '$(srcdir)/'`qmckl_numprec.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libqmckl_la-qmckl_numprec.Tpo $(DEPDIR)/libqmckl_la-qmckl_numprec.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='qmckl_numprec.c' object='libqmckl_la-qmckl_numprec.lo' libtool=yes @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libqmckl_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o libqmckl_la-qmckl_numprec.lo `test -f 'qmckl_numprec.c' || echo '$(srcdir)/'`qmckl_numprec.c - -.f90.o: - $(AM_V_FC)$(FCCOMPILE) -c -o $@ $(FCFLAGS_f90) $< - -.f90.obj: - $(AM_V_FC)$(FCCOMPILE) -c -o $@ $(FCFLAGS_f90) `$(CYGPATH_W) '$<'` - -.f90.lo: - $(AM_V_FC)$(LTFCCOMPILE) -c -o $@ $(FCFLAGS_f90) $< - -qmckl_f.lo: $(top_srcdir)/share/qmckl/fortran/qmckl_f.f90 - $(AM_V_FC)$(LIBTOOL) $(AM_V_lt) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(FC) $(AM_FCFLAGS) $(FCFLAGS) -c -o qmckl_f.lo $(FCFLAGS_f90) `test -f '$(top_srcdir)/share/qmckl/fortran/qmckl_f.f90' || echo '$(srcdir)/'`$(top_srcdir)/share/qmckl/fortran/qmckl_f.f90 - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs - -# This directory's subdirectories are mostly independent; you can cd -# into them and run 'make' without going through this Makefile. -# To change the values of 'make' variables: instead of editing Makefiles, -# (1) if the variable is set in 'config.status', edit 'config.status' -# (which will cause the Makefiles to be regenerated when you run 'make'); -# (2) otherwise, pass the desired values on the 'make' command line. -$(am__recursive_targets): - @fail=; \ - if $(am__make_keepgoing); then \ - failcom='fail=yes'; \ - else \ - failcom='exit 1'; \ - fi; \ - dot_seen=no; \ - target=`echo $@ | sed s/-recursive//`; \ - case "$@" in \ - distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ - *) list='$(SUBDIRS)' ;; \ - esac; \ - for subdir in $$list; do \ - echo "Making $$target in $$subdir"; \ - if test "$$subdir" = "."; then \ - dot_seen=yes; \ - local_target="$$target-am"; \ - else \ - local_target="$$target"; \ - fi; \ - ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ - || eval $$failcom; \ - done; \ - if test "$$dot_seen" = "no"; then \ - $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ - fi; test -z "$$fail" - -ID: $(am__tagged_files) - $(am__define_uniq_tagged_files); mkid -fID $$unique -tags: tags-recursive -TAGS: tags - -tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - set x; \ - here=`pwd`; \ - if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ - include_option=--etags-include; \ - empty_fix=.; \ - else \ - include_option=--include; \ - empty_fix=; \ - fi; \ - list='$(SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ - test ! -f $$subdir/TAGS || \ - set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ - fi; \ - done; \ - $(am__define_uniq_tagged_files); \ - shift; \ - if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - if test $$# -gt 0; then \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - "$$@" $$unique; \ - else \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$unique; \ - fi; \ - fi -ctags: ctags-recursive - -CTAGS: ctags -ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) - $(am__define_uniq_tagged_files); \ - test -z "$(CTAGS_ARGS)$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && $(am__cd) $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) "$$here" -cscopelist: cscopelist-recursive - -cscopelist-am: $(am__tagged_files) - list='$(am__tagged_files)'; \ - case "$(srcdir)" in \ - [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ - *) sdir=$(subdir)/$(srcdir) ;; \ - esac; \ - for i in $$list; do \ - if test -f "$$i"; then \ - echo "$(subdir)/$$i"; \ - else \ - echo "$$sdir/$$i"; \ - fi; \ - done >> $(top_builddir)/cscope.files - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags - -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done - @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ - $(am__make_dryrun) \ - || test -d "$(distdir)/$$subdir" \ - || $(MKDIR_P) "$(distdir)/$$subdir" \ - || exit 1; \ - dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ - $(am__relativize); \ - new_distdir=$$reldir; \ - dir1=$$subdir; dir2="$(top_distdir)"; \ - $(am__relativize); \ - new_top_distdir=$$reldir; \ - echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ - echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ - ($(am__cd) $$subdir && \ - $(MAKE) $(AM_MAKEFLAGS) \ - top_distdir="$$new_top_distdir" \ - distdir="$$new_distdir" \ - am__remove_distdir=: \ - am__skip_length_check=: \ - am__skip_mode_fix=: \ - distdir) \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) check-recursive -all-am: Makefile $(LTLIBRARIES) -installdirs: installdirs-recursive -installdirs-am: - for dir in "$(DESTDIR)$(libdir)"; do \ - test -z "$$dir" || $(MKDIR_P) "$$dir"; \ - done -install: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) install-recursive -install-exec: install-exec-recursive -install-data: install-data-recursive -uninstall: uninstall-recursive - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-recursive -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." - -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) -clean: clean-recursive - -clean-am: clean-generic clean-libLTLIBRARIES clean-libtool \ - mostlyclean-am - -distclean: distclean-recursive - -rm -f ./$(DEPDIR)/libqmckl_la-qmckl_ao.Plo - -rm -f ./$(DEPDIR)/libqmckl_la-qmckl_context.Plo - -rm -f ./$(DEPDIR)/libqmckl_la-qmckl_electron.Plo - -rm -f ./$(DEPDIR)/libqmckl_la-qmckl_error.Plo - -rm -f ./$(DEPDIR)/libqmckl_la-qmckl_memory.Plo - -rm -f ./$(DEPDIR)/libqmckl_la-qmckl_numprec.Plo - -rm -f Makefile -distclean-am: clean-am distclean-compile distclean-generic \ - distclean-tags - -dvi: dvi-recursive - -dvi-am: - -html: html-recursive - -html-am: - -info: info-recursive - -info-am: - -install-data-am: - -install-dvi: install-dvi-recursive - -install-dvi-am: - -install-exec-am: install-libLTLIBRARIES - -install-html: install-html-recursive - -install-html-am: - -install-info: install-info-recursive - -install-info-am: - -install-man: - -install-pdf: install-pdf-recursive - -install-pdf-am: - -install-ps: install-ps-recursive - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-recursive - -rm -f ./$(DEPDIR)/libqmckl_la-qmckl_ao.Plo - -rm -f ./$(DEPDIR)/libqmckl_la-qmckl_context.Plo - -rm -f ./$(DEPDIR)/libqmckl_la-qmckl_electron.Plo - -rm -f ./$(DEPDIR)/libqmckl_la-qmckl_error.Plo - -rm -f ./$(DEPDIR)/libqmckl_la-qmckl_memory.Plo - -rm -f ./$(DEPDIR)/libqmckl_la-qmckl_numprec.Plo - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-recursive - -mostlyclean-am: mostlyclean-compile mostlyclean-generic \ - mostlyclean-libtool - -pdf: pdf-recursive - -pdf-am: - -ps: ps-recursive - -ps-am: - -uninstall-am: uninstall-libLTLIBRARIES - -.MAKE: $(am__recursive_targets) all check install install-am \ - install-strip - -.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am \ - am--depfiles check check-am clean clean-generic \ - clean-libLTLIBRARIES clean-libtool cscopelist-am ctags \ - ctags-am distclean distclean-compile distclean-generic \ - distclean-libtool distclean-tags distdir dvi dvi-am html \ - html-am info info-am install install-am install-data \ - install-data-am install-dvi install-dvi-am install-exec \ - install-exec-am install-html install-html-am install-info \ - install-info-am install-libLTLIBRARIES install-man install-pdf \ - install-pdf-am install-ps install-ps-am install-strip \ - installcheck installcheck-am installdirs installdirs-am \ - maintainer-clean maintainer-clean-generic mostlyclean \ - mostlyclean-compile mostlyclean-generic mostlyclean-libtool \ - pdf pdf-am ps ps-am tags tags-am uninstall uninstall-am \ - uninstall-libLTLIBRARIES - -.PRECIOUS: Makefile - -export LC_MESSAGES - -qmckl_ao.c: qmckl_ao.org qmckl_ao_func.h qmckl_ao_private_type.h qmckl_ao_private_func.h -qmckl_ao_f.f90: qmckl_ao.org qmckl_ao_fh_func.f90 qmckl_f.o -qmckl_ao_fh_func.f90: qmckl_ao.org -qmckl_ao_func.h: qmckl_ao.org -qmckl_ao_private_func.h: qmckl_ao.org -qmckl_ao_private_type.h: qmckl_ao.org -qmckl_context.c: qmckl_context.org qmckl_context_func.h qmckl_context_type.h qmckl_context_private_type.h -qmckl_context_f.f90: qmckl_context_fh_func.f90 qmckl_context_fh_type.f90 qmckl_f.o -qmckl_context_fh_func.f90: qmckl_context.org -qmckl_context_fh_type.f90: qmckl_context.org -qmckl_context_func.h: qmckl_context.org -qmckl_context_private_type.h: qmckl_context.org -qmckl_context_type.h: qmckl_context.org -qmckl_distance.c: qmckl_distance_func.h -qmckl_distance_f.f90: qmckl_distance.org qmckl_distance_fh_func.f90 qmckl_f.o -qmckl_distance_fh_func.f90: qmckl_distance.org -qmckl_distance_func.h: qmckl_distance.org -qmckl_electron.c: qmckl_electron.org qmckl_electron_func.h qmckl_electron_private_type.h qmckl_electron_private_func.h -qmckl_electron_f.f90: qmckl_electron.org qmckl_f.o -qmckl_electron_func.h: qmckl_electron.org -qmckl_electron_private_func.h: qmckl_electron.org -qmckl_electron_private_type.h: qmckl_electron.org -qmckl_error.c: qmckl_error.org qmckl_error_func.h qmckl_error_type.h qmckl_error_private_type.h -qmckl_error_f.f90: qmckl_error_fh_func.f90 qmckl_error_fh_type.f90 qmckl_f.o -qmckl_error_fh_func.f90: qmckl_error.org -qmckl_error_fh_type.f90: qmckl_error.org -qmckl_error_func.h: qmckl_error.org -qmckl_error_private_type.h: qmckl_error.org -qmckl_error_type.h: qmckl_error.org -qmckl_memory.c: qmckl_memory.org qmckl_memory_func.h qmckl_memory_private_type.h qmckl_memory_private_func.h -qmckl_memory_func.h: qmckl_memory.org -qmckl_memory_private_func.h: qmckl_memory.org -qmckl_memory_private_type.h: qmckl_memory.org -qmckl_numprec.c: qmckl_numprec.org qmckl_numprec_func.h qmckl_numprec_type.h qmckl_numprec_private_type.h -qmckl_numprec_f.f90: qmckl_numprec_fh_func.f90 qmckl_f.o -qmckl_numprec_fh_func.f90: qmckl_numprec.org -qmckl_numprec_func.h: qmckl_numprec.org -qmckl_numprec_private_type.h: qmckl_numprec.org -qmckl_numprec_type.h: qmckl_numprec.org -test_qmckl_ao.c: qmckl_ao.org qmckl_ao.org qmckl_ao_func.h qmckl_ao_private_type.h qmckl_ao_private_func.h -test_qmckl_ao_f.f90: qmckl_ao.org qmckl_f.o -test_qmckl_context.c: qmckl_context.org qmckl_context.org qmckl_context_func.h qmckl_context_type.h qmckl_context_private_type.h -test_qmckl_distance.c: qmckl_distance.org qmckl_distance_func.h -test_qmckl_distance_f.f90: qmckl_distance.org qmckl_f.o -test_qmckl_electron.c: qmckl_electron.org qmckl_electron.org qmckl_electron_func.h qmckl_electron_private_type.h qmckl_electron_private_func.h -test_qmckl_error.c: qmckl_error.org qmckl_error.org qmckl_error_func.h qmckl_error_type.h qmckl_error_private_type.h -test_qmckl_memory.c: qmckl_memory.org qmckl_memory.org qmckl_memory_func.h qmckl_memory_private_type.h qmckl_memory_private_func.h -test_qmckl_numprec.c: qmckl_numprec.org qmckl_numprec.org qmckl_numprec_func.h qmckl_numprec_type.h qmckl_numprec_private_type.h - -export top_srcdir - -Makefile.in: generated.mk - -generated.mk: $(ORG_FILES) - $(top_srcdir)/tools/create_makefile.sh - -qmckl.h qmckl_f.f90: $(FH_FUNC_FILES) $(H_FUNC_FILES) $(H_TYPE_FILES) - $(cat_h_verbose)$(top_srcdir)/tools/build_qmckl_h.sh - -.f90: $(ORG_FILES) - $(tangle_verbose)$(top_srcdir)/tools/tangle.sh $(ORG_FILES) - -.h: $(ORG_FILES) - $(tangle_verbose)$(top_srcdir)/tools/tangle.sh $(ORG_FILES) - -.org.c: - $(tangle_verbose)$(top_srcdir)/tools/tangle.sh $< - -$(qmckl_f): qmckl_f.f90 - mv qmckl_f.f90 $(qmckl_f) - -$(qmckl_h): qmckl.h - mv qmckl.h $(qmckl_h) - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/tools/build_doc.sh b/tools/build_doc.sh index 2d6f294..3c27b56 100755 --- a/tools/build_doc.sh +++ b/tools/build_doc.sh @@ -1,45 +1,39 @@ #!/bin/bash -# Script to build the documentation +# Script to build the documentation. + +set -e + +if [[ -z ${srcdir} ]] ; then + echo "Error: srcdir environment variable is not defined" + exit 1 +fi -readonly DOCS=${top_srcdir}/share/doc/qmckl/ -readonly SRC=${top_srcdir}/src/ +readonly DOCS=${srcdir}/share/doc/qmckl/ +readonly ORG=${srcdir}/org/ readonly HTMLIZE=${DOCS}/html/htmlize.el -readonly CONFIG_DOC=${top_srcdir}/tools/config_doc.el -readonly CONFIG_TANGLE=${top_srcdir}/tools/config_tangle.el +readonly CONFIG_DOC=${srcdir}/tools/config_doc.el +readonly CONFIG_TANGLE=${srcdir}/tools/config_tangle.el +# Checks that all the defined global variables correspond to files. - - - -function check_preconditions() -{ -# Checks that all the defined global variables correspond to files. - - if [[ -z ${top_srcdir} ]] +for dir in ${DOCS}/html ${DOCS}/text ${ORG} +do + if [[ ! -d ${dir} ]] then - print "top_srcdir is not defined" - exit 1 + print "${dir} not found" + exit 2 fi +done - for dir in ${DOCS}/html ${DOCS}/text ${SRC} - do - if [[ ! -d ${dir} ]] - then - print "${dir} not found" - exit 2 - fi - done - - for file in ${CONFIG_DOC} ${CONFIG_TANGLE} - do - if [[ ! -f ${file} ]] - then - print "${file} not found" - exit 3 - fi - done -} +for file in ${CONFIG_DOC} ${CONFIG_TANGLE} +do + if [[ ! -f ${file} ]] + then + print "${file} not found" + exit 3 + fi +done @@ -53,7 +47,7 @@ function install_htmlize() [[ -f ${HTMLIZE} ]] || ( cd ${DOCS}/html - git clone ${url} \ + ${srcdir}/missing git clone ${url} \ && cp ${repo}/htmlize.el ${HTMLIZE} \ && rm -rf ${repo} cd - @@ -71,8 +65,8 @@ function extract_doc() # Extracts documentation from an org-mode file. local org=$1 - local local_html=${SRC}/${org%.org}.html - local local_text=${SRC}/${org%.org}.txt + local local_html=${ORG}/${org%.org}.html + local local_text=${ORG}/${org%.org}.txt local html=${DOCS}/html/${org%.org}.html local text=${DOCS}/text/${org%.org}.txt @@ -80,7 +74,7 @@ function extract_doc() then return fi - emacs --batch \ + ${srcdir}/missing emacs --batch \ --load ${HTMLIZE} \ --load ${CONFIG_DOC} \ ${org} \ @@ -97,8 +91,6 @@ function extract_doc() function main() { - check_preconditions || exit 1 - # Install htmlize if needed install_htmlize || exit 2 @@ -108,7 +100,6 @@ function main() { for i in *.org do - echo echo "======= ${i} =======" extract_doc ${i} done @@ -122,5 +113,6 @@ function main() { else exit 3 fi + } main diff --git a/tools/build_makefile.sh b/tools/build_makefile.sh new file mode 100755 index 0000000..9641f80 --- /dev/null +++ b/tools/build_makefile.sh @@ -0,0 +1,197 @@ +#!/bin/bash +# +# Creates all the dependencies from the org-mode files + +set -e + +if [[ -z ${srcdir} ]] ; then + echo "Error: srcdir environment variable is not defined" + exit 1 +fi + +WD=$PWD + +function make_src() +{ + + cd ${srcdir} + + declare -A DEPS DEPS_ORG + + C_FILES= + F_FILES= + FH_FUNC_FILES= + FH_TYPE_FILES= + H_FUNC_FILES= + H_TYPE_FILES= + H_PRIVATE_FUNC_FILES= + H_PRIVATE_TYPE_FILES= + C_TEST_FILES= + F_TEST_FILES= + + for org in org/*.org ; do + ORG_FILES+="\$(srcdir)/$org " + i=${org%.org} + i="\$(srcdir)/src/${i#org/}" + c="${i}.c" + o="${i}.o" + h_func="${i}_func.h" + h_type="${i}_type.h" + h_private_func="${i}_private_func.h" + h_private_type="${i}_private_type.h" + f90="${i}_f.f90" + fo="${i}_f.o" + fh_func="${i}_fh_func.f90" + fh_type="${i}_fh_type.f90" + + grep -q "(eval c)" $org + if [[ $? -eq 0 ]] ; then + DEPS_ORG[$org]+="$c " + DEPS[$o]+=" $c " + C_FILES+=" $c" + C_O_FILES+=" $o" + fi + + grep -q "(eval h_func)" $org + if [[ $? -eq 0 ]] ; then + DEPS_ORG[$org]+="$h_func " + DEPS[$o]+=" $h_func" + H_FUNC_FILES+=" $h_func" + fi + + grep -q "(eval h_type)" $org + if [[ $? -eq 0 ]] ; then + DEPS_ORG[$org]+="$h_type " + DEPS[$o]+=" $h_type" + H_TYPE_FILES+=" $h_type" + fi + + grep -q "(eval h_private_type)" $org + if [[ $? -eq 0 ]] ; then + DEPS_ORG[$org]+="$h_private_type " + DEPS[$o]+=" $h_private_type" + H_PRIVATE_TYPE_FILES+=" $h_private_type" + fi + + grep -q "(eval h_private_func)" $org + if [[ $? -eq 0 ]] ; then + DEPS_ORG[$org]+="$h_private_func " + DEPS[$o]+=" $h_private_func" + H_PRIVATE_FUNC_FILES+=" $h_private_func" + fi + + grep -q "(eval f)" $org + if [[ $? -eq 0 ]] ; then + DEPS_ORG[$org]+="$f90 " + DEPS[$fo]+="$f90 " + F_FILES+=" $f90" + fi + + grep -q "(eval fh_func)" $org + if [[ $? -eq 0 ]] ; then + DEPS_ORG[$org]+="$fh_func " + DEPS[$fo]+=" $fh_func" + FH_FUNC_FILES+=" $fh_func" + fi + + grep -q "(eval fh_type)" $org + if [[ $? -eq 0 ]] ; then + DEPS_ORG[$org]+="$fh_type " + DEPS[$fo]+=" $fh_type" + FH_TYPE_FILES+=" $fh_type" + fi + done + + for org in org/*.org ; do + i=${org%.org} + i=${i#org/} + o="\$(srcdir)/src/${i}.o" + fo="\$(srcdir)/src/${i}_f.o" + c="\$(srcdir)/src/${i}.c" + f90="\$(srcdir)/src/${i}_f.f90" + c_test_o="\$(srcdir)/src/test_${i}.o" + f_test_o="\$(srcdir)/src/test_${i}_f.o" + c_test="\$(srcdir)/src/test_${i}.c" + f_test="\$(srcdir)/src/test_${i}_f.f90" + grep -q "(eval c_test)" $org + if [[ $? -eq 0 ]] ; then + DEPS_ORG[$org]+="$c_test " + DEPS[$c_test_o]+=" $c_test $o" + C_TEST_FILES+=" $c_test" + fi + + grep -q "(eval f_test)" $org + if [[ $? -eq 0 ]] ; then + DEPS_ORG[$org]+="$f_test " + DEPS[$f_test_o]+=" $f_test $fo" + F_TEST_FILES+=" $f_test" + fi + done + + for org in org/*.org ; do + i=${org%.org} + i="\$(srcdir)/src/${i#org/}" + c="${i}.c" + o="${i}.o" + fo="${i}_f.o" + for i in ${!DEPS[@]} ; do + extension="${i##*.}" + grep -q "$i" $org + if [[ $? -ne 0 ]] ; then + if [[ "$extension" == h ]] ; then + DEPS[$o]+=" $i" + elif [[ "$extension" == f90 ]] ; then + DEPS[$fo]+=" $i" + fi + fi + done + done + + for f in ${!DEPS[@]} ; do + if [[ "${f/_f.o/_f.ox}" == ${f}x ]] ; then + DEPS["${f}"]+=" qmckl_f.o" + elif [[ "${f/.o/.ox}" == ${f}x ]] ; then + DEPS["$f"]+=" \$(qmckl_h)" + fi + done + + OUTPUT=${WD}/generated.mk + echo > ${OUTPUT} + echo "## Source files" > ${OUTPUT} + echo >> ${OUTPUT} + echo "ORG_FILES=${ORG_FILES}" >> ${OUTPUT} + echo "C_FILES=${C_FILES}" >> ${OUTPUT} + echo "F_FILES=${F_FILES}" >> ${OUTPUT} + echo "C_O_FILES=${C_O_FILES}" >> ${OUTPUT} + echo "F_O_FILES=${F_O_FILES}" >> ${OUTPUT} + echo "FH_FUNC_FILES=${FH_FUNC_FILES}" >> ${OUTPUT} + echo "FH_TYPE_FILES=${FH_TYPE_FILES}" >> ${OUTPUT} + echo "H_FUNC_FILES=${H_FUNC_FILES}" >> ${OUTPUT} + echo "H_TYPE_FILES=${H_TYPE_FILES}" >> ${OUTPUT} + echo "H_PRIVATE_FUNC_FILES=${H_PRIVATE_FUNC_FILES}" >> ${OUTPUT} + echo "H_PRIVATE_TYPE_FILES=${H_PRIVATE_TYPE_FILES}" >> ${OUTPUT} + echo "C_TEST_FILES=${C_TEST_FILES}" >> ${OUTPUT} + echo "F_TEST_FILES=${F_TEST_FILES}" >> ${OUTPUT} + echo >> ${OUTPUT} + + echo >> ${OUTPUT} + echo "## Org-mode inherited dependencies" >> ${OUTPUT} + echo >> ${OUTPUT} + for f in ${!DEPS_ORG[@]} ; do + echo ${DEPS_ORG[$f]}: $f + echo " \$(tangle_verbose)\$(srcdir)/tools/tangle.sh $f" + echo "" + done >> ${OUTPUT} + echo >> ${OUTPUT} + + echo >> ${OUTPUT} + echo "## Source dependencies" >> ${OUTPUT} + echo >> ${OUTPUT} + for f in ${!DEPS[@]} ; do + echo ${f}: ${DEPS[$f]} + done | sort >> ${OUTPUT} +} + + +make_src + diff --git a/tools/build_qmckl_f.sh b/tools/build_qmckl_f.sh new file mode 100755 index 0000000..514a7c0 --- /dev/null +++ b/tools/build_qmckl_f.sh @@ -0,0 +1,91 @@ +#!/bin/bash +# Script to build the final qmckl_f.f90 file + +set -e + +# All the produced header files are concatenated in the =qmckl_f.f90= +# file, located in the share/qmckl/fortran directory. + + +# Check required environment variables +# ------------------------------------ + +if [[ -z ${srcdir} ]] ; then + echo "Error: srcdir environment variable is not defined" + exit 1 +fi + +if [[ -z ${qmckl_f} ]] ; then + echo "Error: qmckl_f environment variable is not defined" + exit 1 +fi + + + +# Generate Fortran interface file +# ------------------------------- + +HEADERS_TYPE="${srcdir}/src/qmckl_*_fh_type.f90" +HEADERS="${srcdir}/src/qmckl_*_fh_func.f90" + +OUTPUT="${qmckl_f}" +cat << EOF > ${OUTPUT} +! +! ------------------------------------------ +! QMCkl - Quantum Monte Carlo kernel library +! ------------------------------------------ +! +! Documentation : https://trex-coe.github.io/qmckl +! Issues : https://github.com/trex-coe/qmckl/issues +! +! BSD 3-Clause License +! +! Copyright (c) 2020, TREX Center of Excellence +! All rights reserved. +! +! Redistribution and use in source and binary forms, with or without +! modification, are permitted provided that the following conditions are met: +! +! 1. Redistributions of source code must retain the above copyright notice, this +! list of conditions and the following disclaimer. +! +! 2. Redistributions in binary form must reproduce the above copyright notice, +! this list of conditions and the following disclaimer in the documentation +! and/or other materials provided with the distribution. +! +! 3. Neither the name of the copyright holder nor the names of its +! contributors may be used to endorse or promote products derived from +! this software without specific prior written permission. +! +! THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +! AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +! IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +! DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +! FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +! DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +! SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +! CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +! OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +! OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +! +! +! +! +! +module qmckl + use, intrinsic :: iso_c_binding +EOF + +for i in ${HEADERS_TYPE} +do + cat $i >> ${OUTPUT} +done + +for i in ${HEADERS} +do + cat $i >> ${OUTPUT} +done + +cat << EOF >> ${OUTPUT} +end module qmckl +EOF diff --git a/tools/build_qmckl_h.sh b/tools/build_qmckl_h.sh index 6ab0dd2..78ae050 100755 --- a/tools/build_qmckl_h.sh +++ b/tools/build_qmckl_h.sh @@ -5,26 +5,38 @@ # file, located in the include directory. The =*_private.h= files # are excluded. -# Put =.h= files in the correct order: +set -e +# Check required environment variables +# ------------------------------------ + +if [[ -z ${srcdir} ]] ; then + echo "Error: srcdir environment variable is not defined" + exit 1 +fi + +if [[ -z ${qmckl_h} ]] ; then + echo "Error: qmckl_h environment variable is not defined" + exit 1 +fi + + +# Generate C header file +# ---------------------- + HEADERS="" -for i in $(cat table_of_contents) +for i in $(cat ${srcdir}/org/table_of_contents) do HEADERS+="${i%.org}_type.h " done -for i in $(cat table_of_contents) +for i in $(cat ${srcdir}/org/table_of_contents) do HEADERS+="${i%.org}_func.h " done - - -# Generate C header file - - -OUTPUT="qmckl.h" +OUTPUT=${qmckl_h} cat << EOF > ${OUTPUT} /* @@ -80,8 +92,9 @@ EOF for i in ${HEADERS} do - if [[ -f $i ]] ; then - cat $i >> ${OUTPUT} + header=${srcdir}/src/$i + if [[ -f $header ]] ; then + cat $header >> ${OUTPUT} fi done @@ -90,71 +103,3 @@ cat << EOF >> ${OUTPUT} EOF - -# Generate Fortran interface file from all =qmckl_*_fh.f90= files - - -HEADERS_TYPE="qmckl_*_fh_type.f90" -HEADERS="qmckl_*_fh_func.f90" - -OUTPUT="qmckl_f.f90" -cat << EOF > ${OUTPUT} -! -! ------------------------------------------ -! QMCkl - Quantum Monte Carlo kernel library -! ------------------------------------------ -! -! Documentation : https://trex-coe.github.io/qmckl -! Issues : https://github.com/trex-coe/qmckl/issues -! -! BSD 3-Clause License -! -! Copyright (c) 2020, TREX Center of Excellence -! All rights reserved. -! -! Redistribution and use in source and binary forms, with or without -! modification, are permitted provided that the following conditions are met: -! -! 1. Redistributions of source code must retain the above copyright notice, this -! list of conditions and the following disclaimer. -! -! 2. Redistributions in binary form must reproduce the above copyright notice, -! this list of conditions and the following disclaimer in the documentation -! and/or other materials provided with the distribution. -! -! 3. Neither the name of the copyright holder nor the names of its -! contributors may be used to endorse or promote products derived from -! this software without specific prior written permission. -! -! THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -! AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -! IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -! DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE -! FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -! DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -! SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -! CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, -! OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -! OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -! -! -! -! -! -module qmckl - use, intrinsic :: iso_c_binding -EOF - -for i in ${HEADERS_TYPE} -do - cat $i >> ${OUTPUT} -done - -for i in ${HEADERS} -do - cat $i >> ${OUTPUT} -done - -cat << EOF >> ${OUTPUT} -end module qmckl -EOF diff --git a/tools/config_tangle.el b/tools/config_tangle.el index 91c122f..acea6b2 100755 --- a/tools/config_tangle.el +++ b/tools/config_tangle.el @@ -34,16 +34,17 @@ ; The following is required to compute the file names (setq pwd (file-name-directory buffer-file-name)) +(setq wd (concat pwd "/../src/")) (setq name (file-name-nondirectory (substring buffer-file-name 0 -4))) -(setq f (concat pwd name "_f.f90")) -(setq fh_func (concat pwd name "_fh_func.f90")) -(setq fh_type (concat pwd name "_fh_type.f90")) -(setq c (concat pwd name ".c")) -(setq h_func (concat name "_func.h")) -(setq h_type (concat name "_type.h")) -(setq h_private_type (concat name "_private_type.h")) -(setq h_private_func (concat name "_private_func.h")) -(setq c_test (concat pwd "test_" name ".c")) -(setq f_test (concat pwd "test_" name "_f.f90")) +(setq f (concat wd name "_f.f90")) +(setq fh_func (concat wd name "_fh_func.f90")) +(setq fh_type (concat wd name "_fh_type.f90")) +(setq c (concat wd name ".c")) +(setq h_func (concat wd name "_func.h")) +(setq h_type (concat wd name "_type.h")) +(setq h_private_type (concat wd name "_private_type.h")) +(setq h_private_func (concat wd name "_private_func.h")) +(setq c_test (concat wd "test_" name ".c")) +(setq f_test (concat wd "test_" name "_f.f90")) (org-babel-lob-ingest "../tools/lib.org") diff --git a/tools/create_makefile.sh b/tools/create_makefile.sh deleted file mode 100755 index 53c99f8..0000000 --- a/tools/create_makefile.sh +++ /dev/null @@ -1,146 +0,0 @@ -#!/bin/bash - - -function org_files() { - echo ORG_FILES=$(echo *.org) -} - -declare -A DEPS - -C_FILES= -F_FILES= -FH_FUNC_FILES= -FH_TYPE_FILES= -H_FUNC_FILES= -H_TYPE_FILES= -H_PRIVATE_FUNC_FILES= -H_PRIVATE_TYPE_FILES= -C_TEST_FILES= -F_TEST_FILES= - -for org in qmckl_*.org ; do - i=${org%.org} - c=${i}.c - h_func=${i}_func.h - h_type=${i}_type.h - h_private_func=${i}_private_func.h - h_private_type=${i}_private_type.h - f90=${i}_f.f90 - fh_func=${i}_fh_func.f90 - fh_type=${i}_fh_type.f90 - - grep -q "(eval c)" $org - if [[ $? -eq 0 ]] ; then - DEPS["$c"]+=" $org" - C_FILES+=" $c" - fi - - grep -q "(eval h_func)" $org - if [[ $? -eq 0 ]] ; then - DEPS[$h_func]+=" $org" - DEPS[$c]+=" $h_func" - H_FUNC_FILES+=" $h_func" - fi - - grep -q "(eval h_type)" $org - if [[ $? -eq 0 ]] ; then - DEPS[$h_type]+=" $org" - DEPS[$c]+=" $h_type" - H_TYPE_FILES+=" $h_type" - fi - - grep -q "(eval h_private_type)" $org - if [[ $? -eq 0 ]] ; then - DEPS[$h_private_type]+=" $org" - DEPS[$c]+=" $h_private_type" - H_PRIVATE_TYPE_FILES+=" $h_private_type" - fi - - grep -q "(eval h_private_func)" $org - if [[ $? -eq 0 ]] ; then - DEPS[$h_private_func]+=" $org" - DEPS[$c]+=" $h_private_func" - H_PRIVATE_FUNC_FILES+=" $h_private_func" - fi - - grep -q "(eval f)" $org - if [[ $? -eq 0 ]] ; then - DEPS[$f90]+=" $org" - F_FILES+=" $f90" - fi - - grep -q "(eval fh_func)" $org - if [[ $? -eq 0 ]] ; then - DEPS[$fh_func]+=" $org" - DEPS[$f90]+=" $fh_func" - FH_FUNC_FILES+=" $fh_func" - fi - - grep -q "(eval fh_type)" $org - if [[ $? -eq 0 ]] ; then - DEPS[$fh_type]+=" $org" - DEPS[$f90]+=" $fh_type" - FH_TYPE_FILES+=" $fh_type" - fi -done - -for org in qmckl_*.org ; do - i=${org%.org} - c=${i}.c - f90=${i}.f90 - c_test=test_${i}.c - f_test=test_${i}_f.f90 - grep -q "(eval c_test)" $org - if [[ $? -eq 0 ]] ; then - DEPS[$c_test]+=" $org ${DEPS[$c]}" - C_TEST_FILES+=" $c_test" - fi - - grep -q "(eval f_test)" $org - if [[ $? -eq 0 ]] ; then - DEPS[$f_test]+=" $org ${DEPS[$f90]}" - F_TEST_FILES+=" $f_test" - fi -done - -for org in ${ORG_FILES} ; do - i=${org%.org} - c=${i}.c - f90=${i}.f90 - for f in ${!DEPS[@]} ; do - extension="${f##*.}" - grep -q "$f" $org - if [[ $? -ne 0 ]] ; then - if [[ extension == ".h" ]] ; then - DEPS[$c]+=" $f" - elif [[ extension == ".f90" ]] ; then - DEPS[$f90]+=" $f" - fi - fi - done -done - -for f in ${!DEPS[@]} ; do - if [[ "${f/_f.f90/_f.f90x}" == "${f}x" ]] ; then - DEPS["$f"]+=" qmckl_f.o" - fi -done - -echo > generated.mk -echo "C_FILES=${C_FILES}" >> generated.mk -echo "F_FILES=${F_FILES}" >> generated.mk -echo "FH_FUNC_FILES=${FH_FUNC_FILES}" >> generated.mk -echo "FH_TYPE_FILES=${FH_TYPE_FILES}" >> generated.mk -echo "H_FUNC_FILES=${H_FUNC_FILES}" >> generated.mk -echo "H_TYPE_FILES=${H_TYPE_FILES}" >> generated.mk -echo "H_PRIVATE_FUNC_FILES=${H_PRIVATE_FUNC_FILES}" >> generated.mk -echo "H_PRIVATE_TYPE_FILES=${H_PRIVATE_TYPE_FILES}" >> generated.mk -echo "C_TEST_FILES=${C_TEST_FILES}" >> generated.mk -echo "F_TEST_FILES=${F_TEST_FILES}" >> generated.mk -echo >> generated.mk - -for f in ${!DEPS[@]} ; do - echo ${f}: ${DEPS[$f]} -done | sort >> generated.mk - - diff --git a/tools/tangle.sh b/tools/tangle.sh index 0fb3c8c..63b8ded 100755 --- a/tools/tangle.sh +++ b/tools/tangle.sh @@ -8,12 +8,11 @@ # date of the org file is older than one of the tangled files. # The =missing= script is used to check if emacs is present on the system. -if [[ $(basename $PWD) != "src" ]] ; then - print "Error: $0 needs to be run from src directory" - exit 1 +if [[ -z ${srcdir} ]] ; then + print "Error: srcdir environment variable is not defined" + exit 1 fi - function tangle() { local org_file=$1 @@ -25,9 +24,9 @@ function tangle() elif [[ ${org_file} -ot ${f_file} ]] ; then return fi - ../missing \ + ./missing \ emacs --batch ${org_file} \ - --load=${top_srcdir}/tools/config_tangle.el \ + --load=${PWD}/tools/config_tangle.el \ -f org-babel-tangle }