Skip to content
Snippets Groups Projects
Commit 4a74c076 authored by Giovanni Bussi's avatar Giovanni Bussi
Browse files

Faster manual build

Manual building calls "plumed" many times. Using the --no-mpi flag
it is possible to skip initialization of MPI. On my workstation,
this makes manual build way faster.
parent b59abe73
No related branches found
No related tags found
No related merge requests found
...@@ -2,12 +2,12 @@ ...@@ -2,12 +2,12 @@
# Making sure that plumed executable is available # Making sure that plumed executable is available
echo -n "Searching for plumed ..." echo -n "Searching for plumed ..."
if plumed 2>/dev/null 1>/dev/null ; then if plumed --no-mpi 2>/dev/null 1>/dev/null ; then
echo " found" echo " found"
else else
echo " not found" echo " not found"
echo -n "Sourcing sourceme.sh and searching again ..." echo -n "Sourcing sourceme.sh and searching again ..."
if source ../sourceme.sh && plumed 2>/dev/null 1>/dev/null ; then if source ../sourceme.sh && plumed --no-mpi 2>/dev/null 1>/dev/null ; then
echo " found" echo " found"
else else
echo "ERROR: you should compile plumed first!" echo "ERROR: you should compile plumed first!"
...@@ -21,8 +21,8 @@ rm -f errors ...@@ -21,8 +21,8 @@ rm -f errors
rm -rf automatic rm -rf automatic
mkdir automatic mkdir automatic
long_version="$(plumed info --long-version)" long_version="$(plumed --no-mpi info --long-version)"
git_version="$(plumed info --git-version)" git_version="$(plumed --no-mpi info --git-version)"
cat > automatic/version.tmp << EOF cat > automatic/version.tmp << EOF
This manual has been compiled from PLUMED version <b> $long_version </b> This manual has been compiled from PLUMED version <b> $long_version </b>
...@@ -50,7 +50,7 @@ do ...@@ -50,7 +50,7 @@ do
echo "- \subpage $mytag " >> automatic/codes.list echo "- \subpage $mytag " >> automatic/codes.list
echo "/**" >> automatic/$myengine.txt echo "/**" >> automatic/$myengine.txt
echo "\page $mytag $myengine" >> automatic/$myengine.txt echo "\page $mytag $myengine" >> automatic/$myengine.txt
plumed patch -e $myengine -i -q >> automatic/$myengine.txt plumed --no-mpi patch -e $myengine -i -q >> automatic/$myengine.txt
echo "*/" >> automatic/$myengine.txt echo "*/" >> automatic/$myengine.txt
done done
...@@ -188,7 +188,7 @@ do ...@@ -188,7 +188,7 @@ do
if grep -q '//+PLUMEDOC INTERNAL' $file 1>/dev/null 2>/dev/null ; then if grep -q '//+PLUMEDOC INTERNAL' $file 1>/dev/null 2>/dev/null ; then
cp $file automatic/$flag.txt cp $file automatic/$flag.txt
else else
if ! plumed manual --action=$flag > automatic/$flag.man 2> /dev/null ; then if ! plumed --no-mpi manual --action=$flag > automatic/$flag.man 2> /dev/null ; then
echo Full manual for action $flag will not be generated as you are building the manual from a code where this action was not compiled >> errors echo Full manual for action $flag will not be generated as you are building the manual from a code where this action was not compiled >> errors
elif ! grep -q "\par Examples" $file 1>/dev/null 2>/dev/null elif ! grep -q "\par Examples" $file 1>/dev/null 2>/dev/null
then then
......
...@@ -2,12 +2,12 @@ ...@@ -2,12 +2,12 @@
# Making sure that plumed executable is available # Making sure that plumed executable is available
echo -n "Searching for plumed ..." echo -n "Searching for plumed ..."
if plumed 2>/dev/null 1>/dev/null ; then if plumed --no-mpi 2>/dev/null 1>/dev/null ; then
echo " found" echo " found"
else else
echo " not found" echo " not found"
echo -n "Sourcing sourceme.sh and searching again ..." echo -n "Sourcing sourceme.sh and searching again ..."
if source ../sourceme.sh && plumed 2>/dev/null 1>/dev/null ; then if source ../sourceme.sh && plumed --no-mpi 2>/dev/null 1>/dev/null ; then
echo " found" echo " found"
else else
echo "ERROR: you should compile plumed first!" echo "ERROR: you should compile plumed first!"
...@@ -21,7 +21,7 @@ LIST=" ...@@ -21,7 +21,7 @@ LIST="
{ {
cat Doxyfile cat Doxyfile
echo "PROJECT_NUMBER = \"$(plumed info --long-version)\"" echo "PROJECT_NUMBER = \"$(plumed --no-mpi info --long-version)\""
echo "INPUT+=" $LIST echo "INPUT+=" $LIST
# add this to manually control layout: # add this to manually control layout:
# echo "LAYOUT_FILE=PlumedLayout.xml" # echo "LAYOUT_FILE=PlumedLayout.xml"
...@@ -29,7 +29,7 @@ LIST=" ...@@ -29,7 +29,7 @@ LIST="
for file in html/*.html for file in html/*.html
do do
awk -v version=$(plumed info --version) '{ awk -v version=$(plumed --no-mpi info --version) '{
if(match($0,"<span>Main&#160;Page</span>")){ if(match($0,"<span>Main&#160;Page</span>")){
sub("Main","Home",$0); sub("Main","Home",$0);
sub("Page","(v"version")",$0); sub("Page","(v"version")",$0);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment