diff --git a/src/analysis/Analysis.cpp b/src/analysis/Analysis.cpp
index d12c7b4698416c338419713256914fa4f60a5781..10b3e7204cd6c8d46c7f3da2425165a00dac929f 100644
--- a/src/analysis/Analysis.cpp
+++ b/src/analysis/Analysis.cpp
@@ -1,11 +1,11 @@
 /* +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
    Copyright (c) 2012 The plumed team
    (see the PEOPLE file at the root of the distribution for a list of names)
-  
+
    See http://www.plumed-code.org for more information.
-  
+
    This file is part of plumed, version 2.0.
-  
+
    plumed is free software: you can redistribute it and/or modify
    it under the terms of the GNU Lesser General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
diff --git a/src/analysis/Analysis.h b/src/analysis/Analysis.h
index 1c5534ff7a9165b0e236b10f6bbb3ecba3773ee5..8b59cecca836fe6e80b7a8f74041b86da4f7c13f 100644
--- a/src/analysis/Analysis.h
+++ b/src/analysis/Analysis.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_Analysis_h
-#define __PLUMED_Colvar_h
+#ifndef __PLUMED_analysis_Analysis_h
+#define __PLUMED_analysis_Analysis_h
 
 #include "core/ActionPilot.h"
 #include "core/ActionWithArguments.h"
diff --git a/src/bias/ActionRegister.h b/src/bias/ActionRegister.h
index 732046c8f75a2263f6615ad8caf56ff2b5ef7de5..c0f89150a56d16824b6f561e032d5985e60c2384 100644
--- a/src/bias/ActionRegister.h
+++ b/src/bias/ActionRegister.h
@@ -1 +1,25 @@
+/* +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+   Copyright (c) 2012 The plumed team
+   (see the PEOPLE file at the root of the distribution for a list of names)
+
+   See http://www.plumed-code.org for more information.
+
+   This file is part of plumed, version 2.0.
+
+   plumed is free software: you can redistribute it and/or modify
+   it under the terms of the GNU Lesser General Public License as published by
+   the Free Software Foundation, either version 3 of the License, or
+   (at your option) any later version.
+
+   plumed is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+   GNU Lesser General Public License for more details.
+
+   You should have received a copy of the GNU Lesser General Public License
+   along with plumed.  If not, see <http://www.gnu.org/licenses/>.
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
+#ifndef __PLUMED_bias_ActionRegister_h
+#define __PLUMED_bias_ActionRegister_h
 #include "core/ActionRegister.h"
+#endif
diff --git a/src/bias/Bias.h b/src/bias/Bias.h
index 68f126135138970668f25b4cb86edc427de95f1b..496205dea3852f0163dc4ba9074f255f4712a74c 100644
--- a/src/bias/Bias.h
+++ b/src/bias/Bias.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_Bias_h
-#define __PLUMED_Bias_h
+#ifndef __PLUMED_bias_Bias_h
+#define __PLUMED_bias_Bias_h
 
 #include "core/ActionPilot.h"
 #include "core/ActionWithValue.h"
diff --git a/src/cltools/CLTool.h b/src/cltools/CLTool.h
index ec6cf24fb8c08b35edde00683b521f2509551615..b043e98baed8b34595efaddbabc33efaf3fa262a 100644
--- a/src/cltools/CLTool.h
+++ b/src/cltools/CLTool.h
@@ -1 +1,25 @@
+/* +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+   Copyright (c) 2012 The plumed team
+   (see the PEOPLE file at the root of the distribution for a list of names)
+
+   See http://www.plumed-code.org for more information.
+
+   This file is part of plumed, version 2.0.
+
+   plumed is free software: you can redistribute it and/or modify
+   it under the terms of the GNU Lesser General Public License as published by
+   the Free Software Foundation, either version 3 of the License, or
+   (at your option) any later version.
+
+   plumed is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+   GNU Lesser General Public License for more details.
+
+   You should have received a copy of the GNU Lesser General Public License
+   along with plumed.  If not, see <http://www.gnu.org/licenses/>.
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
+#ifndef __PLUMED_cltools_CLTool_h
+#define __PLUMED_cltools_CLTool_h
 #include "core/CLTool.h"
+#endif
diff --git a/src/cltools/CLToolRegister.h b/src/cltools/CLToolRegister.h
index 024736fafde8dcf74a5f7e5b4f0f7ec9e3f534a8..f3718481bd7ec8eddb794a4d9230264e059bec50 100644
--- a/src/cltools/CLToolRegister.h
+++ b/src/cltools/CLToolRegister.h
@@ -1 +1,25 @@
+/* +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+   Copyright (c) 2012 The plumed team
+   (see the PEOPLE file at the root of the distribution for a list of names)
+
+   See http://www.plumed-code.org for more information.
+
+   This file is part of plumed, version 2.0.
+
+   plumed is free software: you can redistribute it and/or modify
+   it under the terms of the GNU Lesser General Public License as published by
+   the Free Software Foundation, either version 3 of the License, or
+   (at your option) any later version.
+
+   plumed is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+   GNU Lesser General Public License for more details.
+
+   You should have received a copy of the GNU Lesser General Public License
+   along with plumed.  If not, see <http://www.gnu.org/licenses/>.
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
+#ifndef __PLUMED_cltools_CLToolRegister_h
+#define __PLUMED_cltools_CLToolRegister_h
 #include "core/CLToolRegister.h"
+#endif
diff --git a/src/colvar/ActionRegister.h b/src/colvar/ActionRegister.h
index 732046c8f75a2263f6615ad8caf56ff2b5ef7de5..1a7b61b8fdabe1d27752fd818e6d9e7bd579334a 100644
--- a/src/colvar/ActionRegister.h
+++ b/src/colvar/ActionRegister.h
@@ -1 +1,25 @@
+/* +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+   Copyright (c) 2012 The plumed team
+   (see the PEOPLE file at the root of the distribution for a list of names)
+
+   See http://www.plumed-code.org for more information.
+
+   This file is part of plumed, version 2.0.
+
+   plumed is free software: you can redistribute it and/or modify
+   it under the terms of the GNU Lesser General Public License as published by
+   the Free Software Foundation, either version 3 of the License, or
+   (at your option) any later version.
+
+   plumed is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+   GNU Lesser General Public License for more details.
+
+   You should have received a copy of the GNU Lesser General Public License
+   along with plumed.  If not, see <http://www.gnu.org/licenses/>.
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
+#ifndef __PLUMED_colvar_ActionRegister_h
+#define __PLUMED_colvar_ActionRegister_h
 #include "core/ActionRegister.h"
+#endif
diff --git a/src/colvar/Colvar.h b/src/colvar/Colvar.h
index fab079d4d31b8f7670919f96cb121600e84f7875..506299b8e1e0dcc42062e482b004b1a8350b1a5c 100644
--- a/src/colvar/Colvar.h
+++ b/src/colvar/Colvar.h
@@ -1 +1,25 @@
+/* +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+   Copyright (c) 2012 The plumed team
+   (see the PEOPLE file at the root of the distribution for a list of names)
+
+   See http://www.plumed-code.org for more information.
+
+   This file is part of plumed, version 2.0.
+
+   plumed is free software: you can redistribute it and/or modify
+   it under the terms of the GNU Lesser General Public License as published by
+   the Free Software Foundation, either version 3 of the License, or
+   (at your option) any later version.
+
+   plumed is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+   GNU Lesser General Public License for more details.
+
+   You should have received a copy of the GNU Lesser General Public License
+   along with plumed.  If not, see <http://www.gnu.org/licenses/>.
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
+#ifndef __PLUMED_colvar_Colvar_h
+#define __PLUMED_colvar_Colvar_h
 #include "core/Colvar.h"
+#endif
diff --git a/src/colvar/ColvarPathMSDBase.h b/src/colvar/ColvarPathMSDBase.h
index eb514bda0d575ccf848689ea8ea9191e70a2d71b..7882e1cb5391065a5387c17f5227fa4ecda515df 100644
--- a/src/colvar/ColvarPathMSDBase.h
+++ b/src/colvar/ColvarPathMSDBase.h
@@ -19,9 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-
-#ifndef __PLUMED_ColvarPathMSDBase
-#define __PLUMED_ColvarPathMSDBase
+#ifndef __PLUMED_colvar_ColvarPathMSDBase_h
+#define __PLUMED_colvar_ColvarPathMSDBase_h
 
 #include <cmath>
 
diff --git a/src/core/Action.h b/src/core/Action.h
index 2e832864522c2ed3612b72cbb5dc518f2b9f7f86..3be08dae5fdb81b284faf78bd0c604b575df82da 100644
--- a/src/core/Action.h
+++ b/src/core/Action.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_Action_h
-#define __PLUMED_Action_h
+#ifndef __PLUMED_core_Action_h
+#define __PLUMED_core_Action_h
 #include <vector>
 #include <string>
 #include <set>
diff --git a/src/core/ActionAtomistic.h b/src/core/ActionAtomistic.h
index f05cfe2d74695210a9fe2d926529b9f77569d6f7..48960bacf1f49ea87735ab694ae2fff804d577aa 100644
--- a/src/core/ActionAtomistic.h
+++ b/src/core/ActionAtomistic.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_ActionAtomistic_h
-#define __PLUMED_ActionAtomistic_h
+#ifndef __PLUMED_core_ActionAtomistic_h
+#define __PLUMED_core_ActionAtomistic_h
 
 #include "Action.h"
 #include "tools/Tensor.h"
diff --git a/src/core/ActionPilot.h b/src/core/ActionPilot.h
index 42b337780fea5500100c250d586fe5d4378e5b1d..ebcf24da8c826b4125a84ef89565fe36859d8d04 100644
--- a/src/core/ActionPilot.h
+++ b/src/core/ActionPilot.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_ActionPilot_h
-#define __PLUMED_ActionPilot_h
+#ifndef __PLUMED_core_ActionPilot_h
+#define __PLUMED_core_ActionPilot_h
 
 #include "Action.h"
 
diff --git a/src/core/ActionRegister.h b/src/core/ActionRegister.h
index 7fab120c8a2a85f378bf88e18486083c6e421e8c..3734bbd333a52c6691d0c28609cf4c5f59163b96 100644
--- a/src/core/ActionRegister.h
+++ b/src/core/ActionRegister.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_ActionRegister_h
-#define __PLUMED_ActionRegister_h
+#ifndef __PLUMED_core_ActionRegister_h
+#define __PLUMED_core_ActionRegister_h
 
 #include <string>
 #include <map>
diff --git a/src/core/ActionSet.h b/src/core/ActionSet.h
index c997d9c5174a457bf90f67dc108eea3200e43897..0e9aceeaec2a667bb51993d5ec30fb682f05f1ba 100644
--- a/src/core/ActionSet.h
+++ b/src/core/ActionSet.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_ActionSet_h
-#define __PLUMED_ActionSet_h
+#ifndef __PLUMED_core_ActionSet_h
+#define __PLUMED_core_ActionSet_h
 
 #include "Action.h"
 
diff --git a/src/core/ActionSetup.h b/src/core/ActionSetup.h
index 565c905393f49b46614fdc001c17a1a5c65208cd..725fb2fa008a05bfbb6efc23072951f8f65464d0 100644
--- a/src/core/ActionSetup.h
+++ b/src/core/ActionSetup.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_ActionSetup_h
-#define __PLUMED_ActionSetup_h
+#ifndef __PLUMED_core_ActionSetup_h
+#define __PLUMED_core_ActionSetup_h
 
 #include "Action.h"
 
diff --git a/src/core/ActionWithArguments.h b/src/core/ActionWithArguments.h
index 85d9e0b7885f3a97506cbcca8f0379747ef90b1e..891769fdd22b0f966ced692ba9faeb7ca4168fb5 100644
--- a/src/core/ActionWithArguments.h
+++ b/src/core/ActionWithArguments.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_ActionWithArguments_h
-#define __PLUMED_ActionWithArguments_h
+#ifndef __PLUMED_core_ActionWithArguments_h
+#define __PLUMED_core_ActionWithArguments_h
 
 #include "Action.h"
 #include "Value.h"
diff --git a/src/core/ActionWithValue.h b/src/core/ActionWithValue.h
index 95e0fffa64f0a4761ac9fc61109a2fc7085cb928..2bb744a9a81557e4ede0a1677a6a53f71954c2e9 100644
--- a/src/core/ActionWithValue.h
+++ b/src/core/ActionWithValue.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_ActionWithValue_h
-#define __PLUMED_ActionWithValue_h
+#ifndef __PLUMED_core_ActionWithValue_h
+#define __PLUMED_core_ActionWithValue_h
 
 #include "Action.h"
 #include "Value.h"
diff --git a/src/core/ActionWithVirtualAtom.h b/src/core/ActionWithVirtualAtom.h
index 5e008467df4d9d71368af7ff8b6482fc6c525d66..cbff60063e41a6f7d2b6c33330d76e331745fd1e 100644
--- a/src/core/ActionWithVirtualAtom.h
+++ b/src/core/ActionWithVirtualAtom.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_ActionWithVirtualAtom_h
-#define __PLUMED_ActionWithVirtualAtom_h
+#ifndef __PLUMED_core_ActionWithVirtualAtom_h
+#define __PLUMED_core_ActionWithVirtualAtom_h
 
 #include "ActionAtomistic.h"
 #include "tools/AtomNumber.h"
diff --git a/src/core/Atoms.h b/src/core/Atoms.h
index be61dc562c814aa9bb2698ace0fb16d3ed09ae84..b048b7619be357efc14e79bfb460800118cad600 100644
--- a/src/core/Atoms.h
+++ b/src/core/Atoms.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_Atoms_h
-#define __PLUMED_Atoms_h
+#ifndef __PLUMED_core_Atoms_h
+#define __PLUMED_core_Atoms_h
 
 #include "tools/PlumedCommunicator.h"
 #include "tools/Tensor.h"
diff --git a/src/core/CLTool.h b/src/core/CLTool.h
index 16ca6b166a3eed70445636625679b0a9b7d5e0a9..abe404a31490669be818cf12c0a4456874e10c93 100644
--- a/src/core/CLTool.h
+++ b/src/core/CLTool.h
@@ -19,9 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-
-#ifndef __PLUMED_CLTool_h
-#define __PLUMED_CLTool_h
+#ifndef __PLUMED_core_CLTool_h
+#define __PLUMED_core_CLTool_h
 #include <cstdio>
 #include <vector>
 #include <string>
diff --git a/src/core/CLToolMain.h b/src/core/CLToolMain.h
index 405d735b3cb65735c87522a2c2f5dcae24749119..279d388f880136282f6316df6d60ba6fdc9bcb0f 100644
--- a/src/core/CLToolMain.h
+++ b/src/core/CLToolMain.h
@@ -19,9 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-
-#ifndef __PLUMED_CLToolMain_h
-#define __PLUMED_CLToolMain_h
+#ifndef __PLUMED_core_CLToolMain_h
+#define __PLUMED_core_CLToolMain_h
 #include <cstdio>
 #include <vector>
 #include <string>
diff --git a/src/core/CLToolRegister.h b/src/core/CLToolRegister.h
index 739acb19e37fed0b6713d8d3bda8893d2b5943e9..d4e67629593ed969ab9fe4f934ec0c6e30181871 100644
--- a/src/core/CLToolRegister.h
+++ b/src/core/CLToolRegister.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_CLToolRegister_h
-#define __PLUMED_CLToolRegister_h
+#ifndef __PLUMED_core_CLToolRegister_h
+#define __PLUMED_core_CLToolRegister_h
 
 #include <string>
 #include <map>
diff --git a/src/core/Colvar.h b/src/core/Colvar.h
index a2988eacf84ce18ccd8e68a2283eb9e5cf19c384..31758b1567f0bbd788c98eb8727329e7ff744f7f 100644
--- a/src/core/Colvar.h
+++ b/src/core/Colvar.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_Colvar_h
-#define __PLUMED_Colvar_h
+#ifndef __PLUMED_core_Colvar_h
+#define __PLUMED_core_Colvar_h
 
 #include "ActionAtomistic.h"
 #include "ActionWithValue.h"
diff --git a/src/core/CubicInterpolation.h b/src/core/CubicInterpolation.h
index 9a42d9eb2dfc8449a456f64220414e59e2272432..d952ead362ed318d7121ef072221b570553491dd 100644
--- a/src/core/CubicInterpolation.h
+++ b/src/core/CubicInterpolation.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_CubitInterpolation_h
-#define __PLUMED_CubitInterpolation_h
+#ifndef __PLUMED_core_CubicInterpolation_h
+#define __PLUMED_core_CubicInterpolation_h
 
 #include <vector>
 #include "tools/Matrix.h"
diff --git a/src/core/ExchangePatterns.h b/src/core/ExchangePatterns.h
index 292cdb54d8b38d87c1786cb5d51c9841e4ab2b59..0795cd190bc04434f3df5f988e013244c3563a6c 100644
--- a/src/core/ExchangePatterns.h
+++ b/src/core/ExchangePatterns.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_ExchangePatterns_h
-#define __PLUMED_ExchangePatterns_h
+#ifndef __PLUMED_core_ExchangePatterns_h
+#define __PLUMED_core_ExchangePatterns_h
 
 namespace PLMD {
 class Random;
diff --git a/src/core/FlexibleBin.h b/src/core/FlexibleBin.h
index da5ef6c146a17dfbdfbdbf5fd94bcb22acd64411..9ee167890df5e6947b6a17b8b4a868d1c69bb9a5 100644
--- a/src/core/FlexibleBin.h
+++ b/src/core/FlexibleBin.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_FlexibleBin_h
-#define __PLUMED_FlexibleBin_h
+#ifndef __PLUMED_core_FlexibleBin_h
+#define __PLUMED_core_FlexibleBin_h
 
 #include<vector>
 using namespace std;
diff --git a/src/core/GREX.h b/src/core/GREX.h
index 73f304c57003b58703688f0664f177b7de4146e8..4cc6a517ac56cbdd2714d219958634c379f67741 100644
--- a/src/core/GREX.h
+++ b/src/core/GREX.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_Grex_h
-#define __PLUMED_Grex_h
+#ifndef __PLUMED_core_GREX_h
+#define __PLUMED_core_GREX_h
 
 #include "WithCmd.h"
 #include <string>
diff --git a/src/core/MDAtoms.h b/src/core/MDAtoms.h
index 758f7a5bae9d6a9076e0feee4e4782bd7e4b7f6b..e3b9b6ccfe3cf99045ddfa5f535c7fde4a4822fc 100644
--- a/src/core/MDAtoms.h
+++ b/src/core/MDAtoms.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_MDAtoms_h
-#define __PLUMED_MDAtoms_h
+#ifndef __PLUMED_core_MDAtoms_h
+#define __PLUMED_core_MDAtoms_h
 
 #include "tools/Tensor.h"
 #include "tools/Vector.h"
diff --git a/src/core/PlumedMain.h b/src/core/PlumedMain.h
index d182f56eb8db97a36ab3bc18abb67d100a6df11f..a99ccdd7f65d980a0fc50bd98c4032ebcbc35bb6 100644
--- a/src/core/PlumedMain.h
+++ b/src/core/PlumedMain.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_PlumedMain_h
-#define __PLUMED_PlumedMain_h
+#ifndef __PLUMED_core_PlumedMain_h
+#define __PLUMED_core_PlumedMain_h
 
 #include "WithCmd.h"
 #include <cstdio>
diff --git a/src/core/SetupMolInfo.h b/src/core/SetupMolInfo.h
index 57e793c10f3b14f792060014864cef4cf62d1974..09ec126024c2cc61de0177b7f0693d173acfcae7 100644
--- a/src/core/SetupMolInfo.h
+++ b/src/core/SetupMolInfo.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_MolInfo_h
-#define __PLUMED_MolInfo_h
+#ifndef __PLUMED_core_SetupMolInfo_h
+#define __PLUMED_core_SetupMolInfo_h
 
 #include "ActionSetup.h"
 #include "ActionAtomistic.h"
diff --git a/src/core/TargetDist.h b/src/core/TargetDist.h
index c926de917a30e1cd6b6c69dd79d536f0f746b58b..1f8b409b949b8818bed8112c8e5951aeff86421f 100644
--- a/src/core/TargetDist.h
+++ b/src/core/TargetDist.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_TargetDist_h
-#define __PLUMED_TargetDist_h
+#ifndef __PLUMED_core_TargetDist_h
+#define __PLUMED_core_TargetDist_h
 
 #include <vector>
 #include <string>
diff --git a/src/core/Value.h b/src/core/Value.h
index 23c07eec81cc536113bec6d84a7f9a1927c7149b..49ed49585b825b28b120d9dda777dae9ba315afd 100644
--- a/src/core/Value.h
+++ b/src/core/Value.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_Value_h
-#define __PLUMED_Value_h
+#ifndef __PLUMED_core_Value_h
+#define __PLUMED_core_Value_h
 
 #include <vector>
 #include <string>
diff --git a/src/core/WithCmd.h b/src/core/WithCmd.h
index c1fc2a480ba228a769bdd4e29d599fd86c26130b..e6ab41022674665df3f317a073063a08573a3538 100644
--- a/src/core/WithCmd.h
+++ b/src/core/WithCmd.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_WithCmd_h
-#define __PLUMED_WithCmd_h
+#ifndef __PLUMED_core_WithCmd_h
+#define __PLUMED_core_WithCmd_h
 
 #include <string>
 
diff --git a/src/function/ActionRegister.h b/src/function/ActionRegister.h
index 732046c8f75a2263f6615ad8caf56ff2b5ef7de5..923749a5b254ca3f995269f26af444bf6ece8361 100644
--- a/src/function/ActionRegister.h
+++ b/src/function/ActionRegister.h
@@ -1 +1,25 @@
+/* +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+   Copyright (c) 2012 The plumed team
+   (see the PEOPLE file at the root of the distribution for a list of names)
+
+   See http://www.plumed-code.org for more information.
+
+   This file is part of plumed, version 2.0.
+
+   plumed is free software: you can redistribute it and/or modify
+   it under the terms of the GNU Lesser General Public License as published by
+   the Free Software Foundation, either version 3 of the License, or
+   (at your option) any later version.
+
+   plumed is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+   GNU Lesser General Public License for more details.
+
+   You should have received a copy of the GNU Lesser General Public License
+   along with plumed.  If not, see <http://www.gnu.org/licenses/>.
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
+#ifndef __PLUMED_function_ActionRegister_h
+#define __PLUMED_function_ActionRegister_h
 #include "core/ActionRegister.h"
+#endif
diff --git a/src/function/Function.h b/src/function/Function.h
index 2ed50420af683e83a55f318c8cd2d61248a91bc0..f7e7445d2736b9bd45ad517139d8566b41a36c1f 100644
--- a/src/function/Function.h
+++ b/src/function/Function.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_Function_h
-#define __PLUMED_Function_h
+#ifndef __PLUMED_function_Function_h
+#define __PLUMED_function_Function_h
 
 #include "core/ActionWithValue.h"
 #include "core/ActionWithArguments.h"
diff --git a/src/header.sh b/src/header.sh
index ec032aef98e9ac4b8e1022ccf48d55283af62529..15421719f9b4d524d75c32c69e484be99262e871 100755
--- a/src/header.sh
+++ b/src/header.sh
@@ -50,6 +50,38 @@ awk -v plus=$plus 'BEGIN{
 
 } > $file.tmp
 
+case "$file" in
+(*h)
+guard="${file//\//_}"
+guard="${guard//./_}"
+guard="__PLUMED_${guard//-/_}"
+
+awk -v plus=$plus -v guard=$guard '
+{
+  if(past==1){
+    if($1=="#ifndef"){
+      line=-10;
+    } else if($1=="#define" && line==-9){
+      found=1;
+    }
+    else if(found!=1 && NF==0);
+    else past=2;
+  }
+  if(past==0 || past==2) print $0;
+  if(past==0 && $1==plus && $2=="*/") {
+    past=1;
+    print "#ifndef "guard
+    print "#define "guard
+  }
+  if(NF>0)line++;
+}END{
+if(!found) print "#endif"
+}' $file.tmp > $file.tmp2
+mv $file.tmp2 $file.tmp
+
+esac
+
+
 cmp -s $file $file.tmp || cp $file.tmp $file
 
 rm $file.tmp
diff --git a/src/imd/ActionIMD.cpp b/src/imd/ActionIMD.cpp
index b57bd5bdcb47146c06447ef78e7891c7f4e42d60..c71f5ac38f3ecd16e70a90c7b16a99121084aece 100644
--- a/src/imd/ActionIMD.cpp
+++ b/src/imd/ActionIMD.cpp
@@ -1,3 +1,24 @@
+/* +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+   Copyright (c) 2012 The plumed team
+   (see the PEOPLE file at the root of the distribution for a list of names)
+
+   See http://www.plumed-code.org for more information.
+
+   This file is part of plumed, version 2.0.
+
+   plumed is free software: you can redistribute it and/or modify
+   it under the terms of the GNU Lesser General Public License as published by
+   the Free Software Foundation, either version 3 of the License, or
+   (at your option) any later version.
+
+   plumed is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+   GNU Lesser General Public License for more details.
+
+   You should have received a copy of the GNU Lesser General Public License
+   along with plumed.  If not, see <http://www.gnu.org/licenses/>.
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
 #include "../core/ActionRegister.h"
 #include "../core/ActionAtomistic.h"
 #include "../core/ActionPilot.h"
diff --git a/src/multicolvar/ActionVolume.h b/src/multicolvar/ActionVolume.h
index 89bb57d2fafee429cb254c673f2f9b1c5b974294..834fe6c15035c42325d32ae39b31f217fe349efd 100644
--- a/src/multicolvar/ActionVolume.h
+++ b/src/multicolvar/ActionVolume.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_ActionVolume_h
-#define __PLUMED_ActionVolume_h
+#ifndef __PLUMED_multicolvar_ActionVolume_h
+#define __PLUMED_multicolvar_ActionVolume_h
 
 #include "core/ActionAtomistic.h"
 #include "tools/HistogramBead.h"
diff --git a/src/multicolvar/MultiColvar.h b/src/multicolvar/MultiColvar.h
index c4249ca1d1b5f53d82d4c32085a2e027fcc799bd..6ab9a5a0aa0b9c71b952bbe7af3c939d64d56422 100644
--- a/src/multicolvar/MultiColvar.h
+++ b/src/multicolvar/MultiColvar.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_MultiColvar_h
-#define __PLUMED_MultiColvar_h
+#ifndef __PLUMED_multicolvar_MultiColvar_h
+#define __PLUMED_multicolvar_MultiColvar_h
 
 #include "core/ActionAtomistic.h"
 #include "core/ActionWithValue.h"
diff --git a/src/multicolvar/MultiColvarSecondaryStructureRMSD.h b/src/multicolvar/MultiColvarSecondaryStructureRMSD.h
index dc469bb3c7723de7edbe303ced66a1598c6468bb..5685aa8bb14739a7d82dade293d050786217084f 100644
--- a/src/multicolvar/MultiColvarSecondaryStructureRMSD.h
+++ b/src/multicolvar/MultiColvarSecondaryStructureRMSD.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_MultiColvarSecondaryStructureRMSD_h
-#define __PLUMED_MultiColvarSecondaryStructureRMSD_h
+#ifndef __PLUMED_multicolvar_MultiColvarSecondaryStructureRMSD_h
+#define __PLUMED_multicolvar_MultiColvarSecondaryStructureRMSD_h
 
 #include "MultiColvar.h"
 #include <vector>
diff --git a/src/tools/Angle.h b/src/tools/Angle.h
index 9f0784dbdc320e7d5e0be4b1f5131289431a2156..d6e81319cc71f5667d131d1dda9fc78b383aa237 100644
--- a/src/tools/Angle.h
+++ b/src/tools/Angle.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_Angle_h
-#define __PLUMED_Angle_h
+#ifndef __PLUMED_tools_Angle_h
+#define __PLUMED_tools_Angle_h
 
 #include "Vector.h"
 
diff --git a/src/tools/AtomNumber.h b/src/tools/AtomNumber.h
index fdcac2e70b0da42f5b8d5b5a79ba964dcd0b716b..f72990a5b6ead05858d62bf132d7b862278f0167 100644
--- a/src/tools/AtomNumber.h
+++ b/src/tools/AtomNumber.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_AtomNumber_h
-#define __PLUMED_AtomNumber_h
+#ifndef __PLUMED_tools_AtomNumber_h
+#define __PLUMED_tools_AtomNumber_h
 
 #include "PlumedException.h"
 #include <limits>
diff --git a/src/tools/Citations.h b/src/tools/Citations.h
index 79fb95a4e84bbf17d79b4bda2fdf56021f512813..8f2d0a228489b8a433f61b08e35e5103d8de5d64 100644
--- a/src/tools/Citations.h
+++ b/src/tools/Citations.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_Citations_h
-#define __PLUMED_Citations_h
+#ifndef __PLUMED_tools_Citations_h
+#define __PLUMED_tools_Citations_h
 
 #include <vector>
 #include <string>
diff --git a/src/tools/DLLoader.h b/src/tools/DLLoader.h
index dbb07fdaeb59c1d46660d05db2d0e8777df98f16..a61b6732d270bf56a2b30ff4a43bd786fb4f4c46 100644
--- a/src/tools/DLLoader.h
+++ b/src/tools/DLLoader.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_DLLoader_h
-#define __PLUMED_DLLoader_h
+#ifndef __PLUMED_tools_DLLoader_h
+#define __PLUMED_tools_DLLoader_h
 
 #include <stack>
 #include <string>
diff --git a/src/tools/DRMSD.h b/src/tools/DRMSD.h
index b9ce260d55fbf14404042e528fe4466884d2b1e9..e0dfbabbe7466ba846ec27620247079732a1e64d 100644
--- a/src/tools/DRMSD.h
+++ b/src/tools/DRMSD.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_DRMSD_h
-#define __PLUMED_DRMSD_h
+#ifndef __PLUMED_tools_DRMSD_h
+#define __PLUMED_tools_DRMSD_h
 
 #include "Tensor.h"
 #include "Vector.h"
diff --git a/src/tools/DynamicList.h b/src/tools/DynamicList.h
index 1fc824047dc7b4743e87f143f181a8d35c26b7fe..26fe9d22c0001ce3c6c9cb6a5baf956f40fa16b0 100644
--- a/src/tools/DynamicList.h
+++ b/src/tools/DynamicList.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_DynamicList_h
-#define __PLUMED_DynamicList_h
+#ifndef __PLUMED_tools_DynamicList_h
+#define __PLUMED_tools_DynamicList_h
 
 #include "PlumedCommunicator.h"
 
diff --git a/src/tools/Grid.h b/src/tools/Grid.h
index 47493720736966b575b936d813e01e5dd904f995..d3999f17a0dbb85ee17f31f935f7c35035f35505 100644
--- a/src/tools/Grid.h
+++ b/src/tools/Grid.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_Grid_h
-#define __PLUMED_Grid_h
+#ifndef __PLUMED_tools_Grid_h
+#define __PLUMED_tools_Grid_h
 
 #include <vector>
 #include <string>
diff --git a/src/tools/HistogramBead.h b/src/tools/HistogramBead.h
index 5568be77f0ce62cf910ea55e69a00308af686ecb..5cbe75cf53af2aa7a1df6deafc0ddbc381568c29 100644
--- a/src/tools/HistogramBead.h
+++ b/src/tools/HistogramBead.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_HistogramBead_h
-#define __PLUMED_HistogramBead_h
+#ifndef __PLUMED_tools_HistogramBead_h
+#define __PLUMED_tools_HistogramBead_h
 
 #include <cassert>
 #include <cmath>
diff --git a/src/tools/Kearsley.h b/src/tools/Kearsley.h
index 68e9f1d06f5103c359150d140c33e393962efefd..4ed16e664ed3810fc4cbf3fe811f2b3dbe1e2396 100644
--- a/src/tools/Kearsley.h
+++ b/src/tools/Kearsley.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_Kearsley_h
-#define __PLUMED_Kearsley_h
+#ifndef __PLUMED_tools_Kearsley_h
+#define __PLUMED_tools_Kearsley_h
 
 #include "Vector.h"
 #include "Tensor.h"
diff --git a/src/tools/KernelFunctions.cpp b/src/tools/KernelFunctions.cpp
index 395014e06d67bf35c1c5ab07c746fd54af1ddb28..3cc37830c9f90060f7249ad87d178d7ba0debe3c 100644
--- a/src/tools/KernelFunctions.cpp
+++ b/src/tools/KernelFunctions.cpp
@@ -1,3 +1,24 @@
+/* +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+   Copyright (c) 2012 The plumed team
+   (see the PEOPLE file at the root of the distribution for a list of names)
+
+   See http://www.plumed-code.org for more information.
+
+   This file is part of plumed, version 2.0.
+
+   plumed is free software: you can redistribute it and/or modify
+   it under the terms of the GNU Lesser General Public License as published by
+   the Free Software Foundation, either version 3 of the License, or
+   (at your option) any later version.
+
+   plumed is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+   GNU Lesser General Public License for more details.
+
+   You should have received a copy of the GNU Lesser General Public License
+   along with plumed.  If not, see <http://www.gnu.org/licenses/>.
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
 #include "KernelFunctions.h"
 
 namespace PLMD {
diff --git a/src/tools/KernelFunctions.h b/src/tools/KernelFunctions.h
index 1c13c3e47a3c4d25437e9a147eca88edcf9259a6..3a7b7e72840e45ad7d4c199ff0db486d50b48aaf 100644
--- a/src/tools/KernelFunctions.h
+++ b/src/tools/KernelFunctions.h
@@ -3,24 +3,24 @@
    (see the PEOPLE file at the root of the distribution for a list of names)
 
    See http://www.plumed-code.org for more information.
-  
+
    This file is part of plumed, version 2.0.
-  
+
    plumed is free software: you can redistribute it and/or modify
    it under the terms of the GNU Lesser General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
    (at your option) any later version.
-  
+
    plumed is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU Lesser General Public License for more details.
-  
+
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_KernelFunctions_h
-#define __PLUMED_KernelFunctions_h
+#ifndef __PLUMED_tools_KernelFunctions_h
+#define __PLUMED_tools_KernelFunctions_h
 
 #include "Tools.h"
 #include "Matrix.h"
diff --git a/src/tools/Keywords.h b/src/tools/Keywords.h
index 05c57a7cce5f311ba6e13e2ec390c1f1cf4922df..6c3f428eddb2f895cd446b5e9a5bdb141de188b8 100644
--- a/src/tools/Keywords.h
+++ b/src/tools/Keywords.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_Keywords_h
-#define __PLUMED_Keywords_h
+#ifndef __PLUMED_tools_Keywords_h
+#define __PLUMED_tools_Keywords_h
 #include <vector>
 #include <string>
 #include <set>
diff --git a/src/tools/LatticeReduction.h b/src/tools/LatticeReduction.h
index e3104d5ebe356dc28da16b7776bda6fff441c1ea..21dba0bba7b05931d778264b5362ec46933825b0 100644
--- a/src/tools/LatticeReduction.h
+++ b/src/tools/LatticeReduction.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_LatticeReduction_h
-#define __PLUMED_LatticeReduction_h
+#ifndef __PLUMED_tools_LatticeReduction_h
+#define __PLUMED_tools_LatticeReduction_h
 
 #include "Vector.h"
 #include "Tensor.h"
diff --git a/src/tools/Log.h b/src/tools/Log.h
index b112c01649e3a29f2876cfe7db754fd50642981c..cdd6b6e7977408969d97db6b3d5d0dcbda758f19 100644
--- a/src/tools/Log.h
+++ b/src/tools/Log.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_Log_h
-#define __PLUMED_Log_h
+#ifndef __PLUMED_tools_Log_h
+#define __PLUMED_tools_Log_h
 
 #include <cstdio>
 #include <string>
diff --git a/src/tools/Matrix.h b/src/tools/Matrix.h
index 253de806d4567b4005f88cc5701f43e1b725aa1b..680cb5b944a20006db4820eebf604a3814549aa8 100644
--- a/src/tools/Matrix.h
+++ b/src/tools/Matrix.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_Matrix_h
-#define __PLUMED_Matrix_h
+#ifndef __PLUMED_tools_Matrix_h
+#define __PLUMED_tools_Matrix_h
 #include <vector>
 #include <string>
 #include <set>
diff --git a/src/tools/MatrixSquareBracketsAccess.h b/src/tools/MatrixSquareBracketsAccess.h
index 5a25af1655b1e4f6f49d4f391acaeea870f6093d..593606927bfaa53509923216ca1040b2937ef5dd 100644
--- a/src/tools/MatrixSquareBracketsAccess.h
+++ b/src/tools/MatrixSquareBracketsAccess.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_MatrixSquareBracketsAccess_h
-#define __PLUMED_MatrixSquareBracketsAccess_h
+#ifndef __PLUMED_tools_MatrixSquareBracketsAccess_h
+#define __PLUMED_tools_MatrixSquareBracketsAccess_h
 
 namespace PLMD{
 
diff --git a/src/tools/NeighborList.h b/src/tools/NeighborList.h
index 42a99c52c063787cc8035b261ef14d95e9f088f8..e169e0be293e37bfb8dc1c33bb529b7955ccb56f 100644
--- a/src/tools/NeighborList.h
+++ b/src/tools/NeighborList.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_NeighborList_h
-#define __PLUMED_NeighborList_h
+#ifndef __PLUMED_tools_NeighborList_h
+#define __PLUMED_tools_NeighborList_h
 
 #include "Vector.h"
 #include "AtomNumber.h"
diff --git a/src/tools/OptimalAlignment.h b/src/tools/OptimalAlignment.h
index 89cfa7e3c85b662073a519ffdb6c4bc1cbf32e2b..1051a2181209fbe518df7704a3226ea513b6f1f9 100644
--- a/src/tools/OptimalAlignment.h
+++ b/src/tools/OptimalAlignment.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_OptimalAlignment_h
-#define __PLUMED_OptimalAlignment_h
+#ifndef __PLUMED_tools_OptimalAlignment_h
+#define __PLUMED_tools_OptimalAlignment_h
 
 #include "Vector.h"
 #include "Tensor.h"
diff --git a/src/tools/PDB.h b/src/tools/PDB.h
index 4482b0e349978d9e6cc27c4a4101f375ef17c02e..fcf0b052bbdc600608d48b182d1c5b0e17510bcc 100644
--- a/src/tools/PDB.h
+++ b/src/tools/PDB.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_PDB_h
-#define __PLUMED_PDB_h
+#ifndef __PLUMED_tools_PDB_h
+#define __PLUMED_tools_PDB_h
 
 #include "AtomNumber.h"
 #include "Vector.h"
diff --git a/src/tools/Pbc.h b/src/tools/Pbc.h
index 4d9762ada2d75fe4be63a4464ea6be79b4a3258f..bb193146d02087f5df5868e69fe0ca33bc4bcf83 100644
--- a/src/tools/Pbc.h
+++ b/src/tools/Pbc.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_Pbc_h
-#define __PLUMED_Pbc_h
+#ifndef __PLUMED_tools_Pbc_h
+#define __PLUMED_tools_Pbc_h
 
 #include "Vector.h"
 #include "Tensor.h"
diff --git a/src/tools/PlumedCommunicator.h b/src/tools/PlumedCommunicator.h
index 664ded8c38cc81647c481c0fc640e7320a705d7c..0b2fb8d5efe038048f6e53662bbc99201926da2b 100644
--- a/src/tools/PlumedCommunicator.h
+++ b/src/tools/PlumedCommunicator.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_PlumedCommunicator_h
-#define __PLUMED_PlumedCommunicator_h
+#ifndef __PLUMED_tools_PlumedCommunicator_h
+#define __PLUMED_tools_PlumedCommunicator_h
 #ifdef __PLUMED_MPI
 #include <mpi.h>
 #endif
diff --git a/src/tools/PlumedException.h b/src/tools/PlumedException.h
index 855572ccdd51026387df0c5e5996d8c696cfb961..a7b85a9b2c9f12aae1583b000a29c773cd650a5c 100644
--- a/src/tools/PlumedException.h
+++ b/src/tools/PlumedException.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_PlumedException_h
-#define __PLUMED_PlumedException_h
+#ifndef __PLUMED_tools_PlumedException_h
+#define __PLUMED_tools_PlumedException_h
 
 #include <string>
 #include <stdexcept>
diff --git a/src/tools/PlumedFile.h b/src/tools/PlumedFile.h
index 430553be851de6587c06fdc0cb9bcfc0ef47051c..c40ee3713c5882c99c3a711ebf289c1a4452c46f 100644
--- a/src/tools/PlumedFile.h
+++ b/src/tools/PlumedFile.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_PlumedFile_h
-#define __PLUMED_PlumedFile_h
+#ifndef __PLUMED_tools_PlumedFile_h
+#define __PLUMED_tools_PlumedFile_h
 
 #include <cstdio>
 #include <vector>
diff --git a/src/tools/RMSD.h b/src/tools/RMSD.h
index 8ed72c97f04389ed49130c2bd95af7a578723c64..64f4e3f77405a7ca784a4283e385ebf1f76d892a 100644
--- a/src/tools/RMSD.h
+++ b/src/tools/RMSD.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_RMSD_h
-#define __PLUMED_RMSD_h
+#ifndef __PLUMED_tools_RMSD_h
+#define __PLUMED_tools_RMSD_h
 
 #include "Vector.h"
 #include <vector>
diff --git a/src/tools/Random.h b/src/tools/Random.h
index 3cf1a7d96d56bc13f8bf916972b406d8e4f95ebf..70ef22a4d91f74dfa9bb002c5fac6dbce5aa59cb 100644
--- a/src/tools/Random.h
+++ b/src/tools/Random.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __RANDOM_H
-#define __RANDOM_H
+#ifndef __PLUMED_tools_Random_h
+#define __PLUMED_tools_Random_h
 
 #include <string>
 #include <iosfwd>
diff --git a/src/tools/Stopwatch.h b/src/tools/Stopwatch.h
index ec9d0032a3236d5841ce84d5b625e50bb024b8ac..7b87dd6de08750c7073cfff7a8e9f612e472b95e 100644
--- a/src/tools/Stopwatch.h
+++ b/src/tools/Stopwatch.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_Stopwatch_h
-#define __PLUMED_Stopwatch_h
+#ifndef __PLUMED_tools_Stopwatch_h
+#define __PLUMED_tools_Stopwatch_h
 
 #include <string>
 #include <map>
diff --git a/src/tools/SwitchingFunction.h b/src/tools/SwitchingFunction.h
index 6ea12ca00de184671254ac3bec90d62fe616a6fc..410107a5b91a925fde7010fea59e68d041be8179 100644
--- a/src/tools/SwitchingFunction.h
+++ b/src/tools/SwitchingFunction.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_SwitchingFunction_h
-#define __PLUMED_SwitchingFunction_h
+#ifndef __PLUMED_tools_SwitchingFunction_h
+#define __PLUMED_tools_SwitchingFunction_h
 
 #include <string>
 
diff --git a/src/tools/Tensor.h b/src/tools/Tensor.h
index 895d352fffa7d2fade0a6c0bced21a3f4f2cce88..bfd87772bfa747d76d015b777ac28c7ee6fb59a0 100644
--- a/src/tools/Tensor.h
+++ b/src/tools/Tensor.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_Tensor_h
-#define __PLUMED_Tensor_h
+#ifndef __PLUMED_tools_Tensor_h
+#define __PLUMED_tools_Tensor_h
 
 #include "MatrixSquareBracketsAccess.h"
 #include "Vector.h"
diff --git a/src/tools/Tools.h b/src/tools/Tools.h
index c7ef12112c19db5141fb56b5b77706ccce0da5b0..b8a9c2c9430d879bea7b4fa88a4adea33499334c 100644
--- a/src/tools/Tools.h
+++ b/src/tools/Tools.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_Tools_h
-#define __PLUMED_Tools_h
+#ifndef __PLUMED_tools_Tools_h
+#define __PLUMED_tools_Tools_h
 
 #include "AtomNumber.h"
 #include <vector>
diff --git a/src/tools/Torsion.h b/src/tools/Torsion.h
index 82bbb97e35d928aae8df9f5b47fdf690049d834a..69199730fc3f22ab4989e1aa01c98604b291d373 100644
--- a/src/tools/Torsion.h
+++ b/src/tools/Torsion.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_Torsion_h
-#define __PLUMED_Torsion_h
+#ifndef __PLUMED_tools_Torsion_h
+#define __PLUMED_tools_Torsion_h
 
 #include "Vector.h"
 
diff --git a/src/tools/Units.h b/src/tools/Units.h
index be025f3288f1d5e3489a4c0c0ac00f49c2e4f00e..f2027e4ce483e8afc8b7ee518e80f0686f269c66 100644
--- a/src/tools/Units.h
+++ b/src/tools/Units.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_Units_h
-#define __PLUMED_Units_h
+#ifndef __PLUMED_tools_Units_h
+#define __PLUMED_tools_Units_h
 
 #include <string>
 
diff --git a/src/tools/Vector.h b/src/tools/Vector.h
index 6ba0477222cdf83e8543d183c04ef2355840d0ca..1e8a251756ffc768b683d996020b04f521adf3ce 100644
--- a/src/tools/Vector.h
+++ b/src/tools/Vector.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_Vector_h
-#define __PLUMED_Vector_h
+#ifndef __PLUMED_tools_Vector_h
+#define __PLUMED_tools_Vector_h
 
 #include <cmath>
 
diff --git a/src/vessel-base/ActionWithVessel.h b/src/vessel-base/ActionWithVessel.h
index 744ffd16809c83031afc74d6f68887d3b0b6cad4..fcf19aa061280164e117b725f9077004974e1584 100644
--- a/src/vessel-base/ActionWithVessel.h
+++ b/src/vessel-base/ActionWithVessel.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_ActionWithVessel_h
-#define __PLUMED_ActionWithVessel_h
+#ifndef __PLUMED_vessel_base_ActionWithVessel_h
+#define __PLUMED_vessel_base_ActionWithVessel_h
 
 #include "core/ActionWithValue.h"
 #include "core/ActionAtomistic.h"
diff --git a/src/vessel-base/NormedSumVessel.h b/src/vessel-base/NormedSumVessel.h
index a8f6f82f8c6c8c92c98fc12fc12f941af3c3356f..3af883a8d9dbd4ac3b37aa54cae8ae42d3c0943a 100644
--- a/src/vessel-base/NormedSumVessel.h
+++ b/src/vessel-base/NormedSumVessel.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_NormedSumVessel_h
-#define __PLUMED_NormedSumVessel_h
+#ifndef __PLUMED_vessel_base_NormedSumVessel_h
+#define __PLUMED_vessel_base_NormedSumVessel_h
 
 #include <string>
 #include <cstring>
diff --git a/src/vessel-base/SumVessel.h b/src/vessel-base/SumVessel.h
index 55fecf72eb87719047f65b5e7425ce9f128adef9..e4b0306dc44d313f7d6161c425bfd36205e12110 100644
--- a/src/vessel-base/SumVessel.h
+++ b/src/vessel-base/SumVessel.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_SumVessel_h
-#define __PLUMED_SumVessel_h
+#ifndef __PLUMED_vessel_base_SumVessel_h
+#define __PLUMED_vessel_base_SumVessel_h
 
 #include <string>
 #include <cstring>
diff --git a/src/vessel-base/Vessel.h b/src/vessel-base/Vessel.h
index 9bf23f2a5e4ce68143336d7f1178ae05e324086e..1ab1ddeafbde78f8b6328ff81181fbf71ec61849 100644
--- a/src/vessel-base/Vessel.h
+++ b/src/vessel-base/Vessel.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_Vessel_h
-#define __PLUMED_Vessel_h
+#ifndef __PLUMED_vessel_base_Vessel_h
+#define __PLUMED_vessel_base_Vessel_h
 
 #include <string>
 #include <cstring>
diff --git a/src/vessel-base/VesselAccumulator.h b/src/vessel-base/VesselAccumulator.h
index 8f5b97a103c15ae2a45bbb0dea601252b080f477..465e8e4983ee2fe6872e8e3e37a52ad85abbf274 100644
--- a/src/vessel-base/VesselAccumulator.h
+++ b/src/vessel-base/VesselAccumulator.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_VesselAccumulator_h
-#define __PLUMED_VesselAccumulator_h
+#ifndef __PLUMED_vessel_base_VesselAccumulator_h
+#define __PLUMED_vessel_base_VesselAccumulator_h
 
 #include <string>
 #include <cstring>
diff --git a/src/vessel-base/VesselRegister.h b/src/vessel-base/VesselRegister.h
index 585f3ed5982968f1b66b4f81adeba7a5dfd9673a..84a7aaaf4d394f32454a72bd6da5b18014331247 100644
--- a/src/vessel-base/VesselRegister.h
+++ b/src/vessel-base/VesselRegister.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_VesselRegister_h
-#define __PLUMED_VesselRegister_h
+#ifndef __PLUMED_vessel_base_VesselRegister_h
+#define __PLUMED_vessel_base_VesselRegister_h
 
 #include <string>
 #include <cstring>
diff --git a/src/vessel-base/VesselStoreAllValues.h b/src/vessel-base/VesselStoreAllValues.h
index e0a93ca26da08b3178ab6c578f6286bd813843ec..cd3bccc50c352e3904c271015ba14e9f99d9b90f 100644
--- a/src/vessel-base/VesselStoreAllValues.h
+++ b/src/vessel-base/VesselStoreAllValues.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_VesselStoreAllValues_h
-#define __PLUMED_VesselStoreAllValues_h
+#ifndef __PLUMED_vessel_base_VesselStoreAllValues_h
+#define __PLUMED_vessel_base_VesselStoreAllValues_h
 
 #include <string>
 #include <cstring>
diff --git a/src/vessel-base/VesselValueAccess.h b/src/vessel-base/VesselValueAccess.h
index 16211398ae3ab993d5c8a4b2f633eaeefe0433e0..a89a9983b5b77240952fd27c9af52e3781cc603b 100644
--- a/src/vessel-base/VesselValueAccess.h
+++ b/src/vessel-base/VesselValueAccess.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_VesselValueAccess_h
-#define __PLUMED_VesselValueAccess_h
+#ifndef __PLUMED_vessel_base_VesselValueAccess_h
+#define __PLUMED_vessel_base_VesselValueAccess_h
 
 #include <string>
 #include <cstring>
diff --git a/src/wrapper/Plumed.h b/src/wrapper/Plumed.h
index 2d477314a634cb0be8dc5b5e41f1851f8dc785e9..77f93716df521a306e858db6b34660ca542fa2b3 100644
--- a/src/wrapper/Plumed.h
+++ b/src/wrapper/Plumed.h
@@ -19,8 +19,8 @@
    You should have received a copy of the GNU Lesser General Public License
    along with plumed.  If not, see <http://www.gnu.org/licenses/>.
 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ */
-#ifndef __PLUMED_Plumed_h
-#define __PLUMED_Plumed_h
+#ifndef __PLUMED_wrapper_Plumed_h
+#define __PLUMED_wrapper_Plumed_h
 
 /**
 \page ReferencePlumedH Reference for interfacing MD codes with PLUMED