mirror of
https://github.com/TREX-CoE/qmckl.git
synced 2024-07-14 07:04:54 +02:00
parallel tangle OK
This commit is contained in:
parent
c61556ef77
commit
90474fee2d
30
.gitignore
vendored
30
.gitignore
vendored
@ -1,20 +1,24 @@
|
|||||||
docs/index.html
|
.deps/
|
||||||
docs/htmlize.el
|
compile
|
||||||
autom4te.cache/
|
depcomp
|
||||||
config.log
|
generated.mk
|
||||||
config.status
|
stamp-h1
|
||||||
src/auto/
|
libtool
|
||||||
src/ltximg/
|
ltmain.sh
|
||||||
src/qmckl.mod
|
m4/libtool.m4
|
||||||
*.swp
|
m4/ltoptions.m4
|
||||||
*.tar.gz
|
m4/ltsugar.m4
|
||||||
|
m4/ltversion.m4
|
||||||
|
m4/lt~obsolete.m4
|
||||||
|
missing
|
||||||
Makefile
|
Makefile
|
||||||
aclocal.m4
|
aclocal.m4
|
||||||
|
autom4te.cache/
|
||||||
config.guess
|
config.guess
|
||||||
|
config.log
|
||||||
|
config.status
|
||||||
config.sub
|
config.sub
|
||||||
configure
|
configure
|
||||||
configure.ac.dist
|
|
||||||
include/config.h
|
|
||||||
*~
|
|
||||||
install-sh
|
install-sh
|
||||||
qmckl.pc
|
qmckl.pc
|
||||||
|
|
||||||
|
@ -52,15 +52,13 @@ fortran_DATA = $(qmckl_f)
|
|||||||
|
|
||||||
export srcdir qmckl_f qmckl_h
|
export srcdir qmckl_f qmckl_h
|
||||||
|
|
||||||
sources_tangled = src/qmckl_ao.c
|
|
||||||
|
|
||||||
|
|
||||||
if QMCKL_DEVEL
|
if QMCKL_DEVEL
|
||||||
# <-----
|
# <-----
|
||||||
dist_src_DATA = $(ORG_FILES)
|
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)
|
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)
|
CLEANFILES += $(BUILT_SOURCES) $(C_TEST_FILES) $(F_TEST_FILES) $(TANGLED_FILES)
|
||||||
|
|
||||||
# ----->
|
# ----->
|
||||||
endif
|
endif
|
||||||
|
1111
Makefile.in
1111
Makefile.in
File diff suppressed because it is too large
Load Diff
1
org/.gitignore
vendored
Normal file
1
org/.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
|||||||
|
*.tangled
|
3
src/.gitignore
vendored
3
src/.gitignore
vendored
@ -6,6 +6,3 @@
|
|||||||
*.html
|
*.html
|
||||||
*~
|
*~
|
||||||
*.so
|
*.so
|
||||||
Makefile.generated
|
|
||||||
test_qmckl
|
|
||||||
merged_qmckl.org
|
|
||||||
|
@ -2,13 +2,12 @@
|
|||||||
#
|
#
|
||||||
# Creates all the dependencies from the org-mode files
|
# Creates all the dependencies from the org-mode files
|
||||||
|
|
||||||
set -e
|
|
||||||
|
|
||||||
if [[ -z ${srcdir} ]] ; then
|
if [[ -z ${srcdir} ]] ; then
|
||||||
echo "Error: srcdir environment variable is not defined"
|
echo "Error: srcdir environment variable is not defined"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
WD=$PWD
|
WD=$PWD
|
||||||
|
|
||||||
function make_src()
|
function make_src()
|
||||||
@ -28,10 +27,17 @@ function make_src()
|
|||||||
H_PRIVATE_TYPE_FILES=
|
H_PRIVATE_TYPE_FILES=
|
||||||
C_TEST_FILES=
|
C_TEST_FILES=
|
||||||
F_TEST_FILES=
|
F_TEST_FILES=
|
||||||
|
TANGLED_FILES=
|
||||||
|
|
||||||
for org in org/*.org ; do
|
for org in org/*.org ; do
|
||||||
ORG_FILES+="\$(srcdir)/$org "
|
tangled="\$(srcdir)/${org%.org}.tangled"
|
||||||
|
|
||||||
i=${org%.org}
|
i=${org%.org}
|
||||||
|
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"
|
||||||
|
|
||||||
i="\$(srcdir)/src/${i#org/}"
|
i="\$(srcdir)/src/${i#org/}"
|
||||||
c="${i}.c"
|
c="${i}.c"
|
||||||
o="${i}.o"
|
o="${i}.o"
|
||||||
@ -44,9 +50,13 @@ function make_src()
|
|||||||
fh_func="${i}_fh_func.f90"
|
fh_func="${i}_fh_func.f90"
|
||||||
fh_type="${i}_fh_type.f90"
|
fh_type="${i}_fh_type.f90"
|
||||||
|
|
||||||
|
ORG_FILES+="\$(srcdir)/$org "
|
||||||
|
TANGLED_FILES+="$tangled "
|
||||||
|
DEPS_ORG["\$(srcdir)/$org"]=$tangled
|
||||||
|
|
||||||
grep -q "(eval c)" $org
|
grep -q "(eval c)" $org
|
||||||
if [[ $? -eq 0 ]] ; then
|
if [[ $? -eq 0 ]] ; then
|
||||||
DEPS_ORG[$org]+="$c "
|
DEPS[$c]+=" $tangled"
|
||||||
DEPS[$o]+=" $c "
|
DEPS[$o]+=" $c "
|
||||||
C_FILES+=" $c"
|
C_FILES+=" $c"
|
||||||
C_O_FILES+=" $o"
|
C_O_FILES+=" $o"
|
||||||
@ -54,76 +64,64 @@ function make_src()
|
|||||||
|
|
||||||
grep -q "(eval h_func)" $org
|
grep -q "(eval h_func)" $org
|
||||||
if [[ $? -eq 0 ]] ; then
|
if [[ $? -eq 0 ]] ; then
|
||||||
DEPS_ORG[$org]+="$h_func "
|
|
||||||
DEPS[$o]+=" $h_func"
|
DEPS[$o]+=" $h_func"
|
||||||
|
DEPS[$h_func]+=" $tangled"
|
||||||
H_FUNC_FILES+=" $h_func"
|
H_FUNC_FILES+=" $h_func"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
grep -q "(eval h_type)" $org
|
grep -q "(eval h_type)" $org
|
||||||
if [[ $? -eq 0 ]] ; then
|
if [[ $? -eq 0 ]] ; then
|
||||||
DEPS_ORG[$org]+="$h_type "
|
|
||||||
DEPS[$o]+=" $h_type"
|
DEPS[$o]+=" $h_type"
|
||||||
|
DEPS[$h_type]+=" $tangled"
|
||||||
H_TYPE_FILES+=" $h_type"
|
H_TYPE_FILES+=" $h_type"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
grep -q "(eval h_private_type)" $org
|
grep -q "(eval h_private_type)" $org
|
||||||
if [[ $? -eq 0 ]] ; then
|
if [[ $? -eq 0 ]] ; then
|
||||||
DEPS_ORG[$org]+="$h_private_type "
|
|
||||||
DEPS[$o]+=" $h_private_type"
|
DEPS[$o]+=" $h_private_type"
|
||||||
|
DEPS[$h_private_type]+=" $tangled"
|
||||||
H_PRIVATE_TYPE_FILES+=" $h_private_type"
|
H_PRIVATE_TYPE_FILES+=" $h_private_type"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
grep -q "(eval h_private_func)" $org
|
grep -q "(eval h_private_func)" $org
|
||||||
if [[ $? -eq 0 ]] ; then
|
if [[ $? -eq 0 ]] ; then
|
||||||
DEPS_ORG[$org]+="$h_private_func "
|
|
||||||
DEPS[$o]+=" $h_private_func"
|
DEPS[$o]+=" $h_private_func"
|
||||||
|
DEPS[$h_private_func]+=" $tangled"
|
||||||
H_PRIVATE_FUNC_FILES+=" $h_private_func"
|
H_PRIVATE_FUNC_FILES+=" $h_private_func"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
grep -q "(eval f)" $org
|
grep -q "(eval f)" $org
|
||||||
if [[ $? -eq 0 ]] ; then
|
if [[ $? -eq 0 ]] ; then
|
||||||
DEPS_ORG[$org]+="$f90 "
|
DEPS[$f90]+="$tangled "
|
||||||
DEPS[$fo]+="$f90 "
|
DEPS[$fo]+="$f90 "
|
||||||
F_FILES+=" $f90"
|
F_FILES+=" $f90"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
grep -q "(eval fh_func)" $org
|
grep -q "(eval fh_func)" $org
|
||||||
if [[ $? -eq 0 ]] ; then
|
if [[ $? -eq 0 ]] ; then
|
||||||
DEPS_ORG[$org]+="$fh_func "
|
|
||||||
DEPS[$fo]+=" $fh_func"
|
DEPS[$fo]+=" $fh_func"
|
||||||
|
DEPS[$fh_func]+=" $tangled"
|
||||||
FH_FUNC_FILES+=" $fh_func"
|
FH_FUNC_FILES+=" $fh_func"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
grep -q "(eval fh_type)" $org
|
grep -q "(eval fh_type)" $org
|
||||||
if [[ $? -eq 0 ]] ; then
|
if [[ $? -eq 0 ]] ; then
|
||||||
DEPS_ORG[$org]+="$fh_type "
|
|
||||||
DEPS[$fo]+=" $fh_type"
|
DEPS[$fo]+=" $fh_type"
|
||||||
|
DEPS[$fh_type]+=" $tangled"
|
||||||
FH_TYPE_FILES+=" $fh_type"
|
FH_TYPE_FILES+=" $fh_type"
|
||||||
fi
|
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
|
grep -q "(eval c_test)" $org
|
||||||
if [[ $? -eq 0 ]] ; then
|
if [[ $? -eq 0 ]] ; then
|
||||||
DEPS_ORG[$org]+="$c_test "
|
DEPS["$c_test"]="${tangled} "
|
||||||
DEPS[$c_test_o]+=" $c_test $o"
|
DEPS["$c_test_o"]+=" $c_test $o"
|
||||||
C_TEST_FILES+=" $c_test"
|
C_TEST_FILES+=" $c_test"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
grep -q "(eval f_test)" $org
|
grep -q "(eval f_test)" $org
|
||||||
if [[ $? -eq 0 ]] ; then
|
if [[ $? -eq 0 ]] ; then
|
||||||
DEPS_ORG[$org]+="$f_test "
|
DEPS["$f_test"]+="${tangled} "
|
||||||
DEPS[$f_test_o]+=" $f_test $fo"
|
DEPS["$f_test_o"]+=" $f_test $fo"
|
||||||
F_TEST_FILES+=" $f_test"
|
F_TEST_FILES+=" $f_test"
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
@ -160,6 +158,7 @@ function make_src()
|
|||||||
echo "## Source files" > ${OUTPUT}
|
echo "## Source files" > ${OUTPUT}
|
||||||
echo >> ${OUTPUT}
|
echo >> ${OUTPUT}
|
||||||
echo "ORG_FILES=${ORG_FILES}" >> ${OUTPUT}
|
echo "ORG_FILES=${ORG_FILES}" >> ${OUTPUT}
|
||||||
|
echo "TANGLED_FILES=${TANGLED_FILES}" >> ${OUTPUT}
|
||||||
echo "C_FILES=${C_FILES}" >> ${OUTPUT}
|
echo "C_FILES=${C_FILES}" >> ${OUTPUT}
|
||||||
echo "F_FILES=${F_FILES}" >> ${OUTPUT}
|
echo "F_FILES=${F_FILES}" >> ${OUTPUT}
|
||||||
echo "C_O_FILES=${C_O_FILES}" >> ${OUTPUT}
|
echo "C_O_FILES=${C_O_FILES}" >> ${OUTPUT}
|
||||||
|
@ -32,6 +32,10 @@ function tangle()
|
|||||||
|
|
||||||
for i in $@
|
for i in $@
|
||||||
do
|
do
|
||||||
# echo "--- ${i} ----"
|
tangled=${i%.org}.tangled
|
||||||
tangle ${i}
|
NOW=$(date +"%m%d%H%M.%S")
|
||||||
|
tangle ${i} &> $tangled
|
||||||
|
|
||||||
|
# Make log file older than the tangled files
|
||||||
|
touch -t ${NOW} $tangled
|
||||||
done
|
done
|
||||||
|
Loading…
Reference in New Issue
Block a user