diff --git a/Geo/Makefile b/Geo/Makefile
index ad13d501a84bc72fa721f432b9c62addfc49c091..7abff5c43d152f9ddf2190d804c409bf5b8abd59 100644
--- a/Geo/Makefile
+++ b/Geo/Makefile
@@ -8,8 +8,8 @@ include ../variables
 LIB = ../lib/libGmshGeo${LIBEXT}
 
 INC = ${DASH}I../Common ${DASH}I../Geo ${DASH}I../Mesh\
-      ${DASH}I../Post ${DASH}I../Numeric ${DASH}I../Parser ${DASH}I../Fltk\
-      ${DASH}I../contrib/NR ${DASH}I../contrib/ANN/include\
+      ${DASH}I../Post ${DASH}I../Numeric ${DASH}I../Parser\
+      ${DASH}I../contrib/ANN/include\
       ${DASH}I../contrib/MathEval ${DASH}I../contrib/gmm
 
 CFLAGS = ${OPTIM} ${FLAGS} ${INC} ${SYSINCLUDE}
diff --git a/Mesh/Makefile b/Mesh/Makefile
index 037996debbb9ce3aab0235a009d5213647cbba1d..27a17868cb576b16086bff97140a2be093e22846 100644
--- a/Mesh/Makefile
+++ b/Mesh/Makefile
@@ -8,8 +8,7 @@ include ../variables
 LIB = ../lib/libGmshMesh${LIBEXT}
 
 INC = ${DASH}I../Numeric ${DASH}I../Common ${DASH}I../Geo\
-      ${DASH}I../Mesh ${DASH}I../Post ${DASH}I../Graphics\
-      ${DASH}I../Fltk ${DASH}I../contrib/NR ${DASH}I../contrib/Triangle\
+      ${DASH}I../Mesh ${DASH}I../Post\
       ${DASH}I../contrib/Tetgen ${DASH}I../contrib/Netgen\
       ${DASH}I../contrib/Netgen/libsrc/include\
       ${DASH}I../contrib/Netgen/libsrc/interface\
diff --git a/Numeric/Makefile b/Numeric/Makefile
index d028f3999c6a2e24f62b03679333ce9992611363..42ebd6e9c4e1258bd666df9d0f35629ba6e1f5f1 100644
--- a/Numeric/Makefile
+++ b/Numeric/Makefile
@@ -7,7 +7,7 @@ include ../variables
 
 LIB = ../lib/libGmshNumeric${LIBEXT}
 
-INC = ${DASH}I../Common ${DASH}I../Numeric ${DASH}I../contrib/NR ${DASH}I../Geo
+INC = ${DASH}I../Common ${DASH}I../Numeric ${DASH}I../Geo
 
 CFLAGS = ${OPTIM} ${FLAGS} ${INC} ${SYSINCLUDE}
 
diff --git a/Plugin/Makefile b/Plugin/Makefile
index c6b7555b220713134436a2c359e4f31d229ce26e..736f01abce6f9473e559838570d90eafefd8b6c6 100644
--- a/Plugin/Makefile
+++ b/Plugin/Makefile
@@ -9,8 +9,7 @@ LIB = ../lib/libGmshPlugin${LIBEXT}
 
 INC = ${DASH}I../Common ${DASH}I../Graphics ${DASH}I../Geo\
       ${DASH}I../Mesh ${DASH}I../Post ${DASH}I../Fltk ${DASH}I../Numeric\
-      ${DASH}I../contrib/ANN/include ${DASH}I../contrib/Triangle\
-      ${DASH}I../contrib/MathEval
+      ${DASH}I../contrib/ANN/include ${DASH}I../contrib/MathEval
 
 CFLAGS = ${OPTIM} ${FLAGS} ${INC} ${SYSINCLUDE}
 
@@ -165,7 +164,8 @@ LongitudeLatitude${OBJEXT}: LongitudeLatitude.cpp LongitudeLatitude.h Plugin.h \
   ../Common/Options.h ../Post/ColorTable.h ../Common/GmshMessage.h \
   ../Post/PView.h ../Geo/SPoint3.h ../Post/PViewDataList.h \
   ../Post/PViewData.h ../Geo/SBoundingBox3d.h ../Geo/SPoint3.h \
-  ../Numeric/GmshMatrix.h ../Common/GmshConfig.h ../Common/ListUtils.h
+  ../Numeric/GmshMatrix.h ../Common/GmshConfig.h ../Common/ListUtils.h \
+  ../Common/OpenFile.h
 Triangulate${OBJEXT}: Triangulate.cpp ../Geo/GModel.h ../Geo/GVertex.h \
   ../Geo/GEntity.h ../Geo/Range.h ../Geo/SPoint3.h \
   ../Geo/SBoundingBox3d.h ../Geo/SPoint3.h ../Geo/GPoint.h \
@@ -201,19 +201,18 @@ Skin${OBJEXT}: Skin.cpp Skin.h Plugin.h ../Common/Options.h ../Post/ColorTable.h
   ../Common/ListUtils.h ../Common/TreeUtils.h ../Common/avl.h \
   ../Common/ListUtils.h ../Common/MallocUtils.h ../Common/Context.h \
   ../Geo/CGNSOptions.h ../Mesh/meshPartitionOptions.h
-GSHHS${OBJEXT}: GSHHS.cpp GSHHS.h Plugin.h ../Common/Options.h \
-  ../Post/ColorTable.h ../Common/GmshMessage.h ../Post/PView.h \
-  ../Geo/SPoint3.h ../Post/PViewDataList.h ../Post/PViewData.h \
-  ../Geo/SBoundingBox3d.h ../Geo/SPoint3.h ../Numeric/GmshMatrix.h \
-  ../Common/GmshConfig.h ../Common/ListUtils.h ../Mesh/Field.h \
-  ../Geo/GModel.h ../Geo/GVertex.h ../Geo/GEntity.h ../Geo/Range.h \
-  ../Geo/SPoint3.h ../Geo/SBoundingBox3d.h ../Geo/GPoint.h \
-  ../Geo/SPoint2.h ../Geo/GEdge.h ../Geo/GEntity.h ../Geo/GVertex.h \
-  ../Geo/SVector3.h ../Geo/SPoint3.h ../Geo/SPoint3.h ../Geo/SPoint2.h \
-  ../Geo/GFace.h ../Geo/GEntity.h ../Geo/GPoint.h ../Geo/GEdgeLoop.h \
-  ../Geo/GEdge.h ../Geo/SPoint2.h ../Geo/SVector3.h ../Geo/Pair.h \
-  ../Geo/GRegion.h ../Geo/GEntity.h ../Geo/SPoint3.h \
-  ../Geo/SBoundingBox3d.h
+GSHHS${OBJEXT}: GSHHS.cpp ../Mesh/Field.h ../Common/GmshConfig.h ../Post/PView.h \
+  ../Geo/SPoint3.h ../Geo/SPoint2.h GSHHS.h Plugin.h ../Common/Options.h \
+  ../Post/ColorTable.h ../Common/GmshMessage.h ../Post/PViewDataList.h \
+  ../Post/PViewData.h ../Geo/SBoundingBox3d.h ../Geo/SPoint3.h \
+  ../Numeric/GmshMatrix.h ../Common/ListUtils.h ../Geo/GModel.h \
+  ../Geo/GVertex.h ../Geo/GEntity.h ../Geo/Range.h ../Geo/SPoint3.h \
+  ../Geo/SBoundingBox3d.h ../Geo/GPoint.h ../Geo/SPoint2.h ../Geo/GEdge.h \
+  ../Geo/GEntity.h ../Geo/GVertex.h ../Geo/SVector3.h ../Geo/SPoint3.h \
+  ../Geo/SPoint3.h ../Geo/SPoint2.h ../Geo/GFace.h ../Geo/GEntity.h \
+  ../Geo/GPoint.h ../Geo/GEdgeLoop.h ../Geo/GEdge.h ../Geo/SPoint2.h \
+  ../Geo/SVector3.h ../Geo/Pair.h ../Geo/GRegion.h ../Geo/GEntity.h \
+  ../Geo/SPoint3.h ../Geo/SBoundingBox3d.h
 Extract${OBJEXT}: Extract.cpp ../Common/GmshConfig.h Extract.h Plugin.h \
   ../Common/Options.h ../Post/ColorTable.h ../Common/GmshMessage.h \
   ../Post/PView.h ../Geo/SPoint3.h ../Post/PViewDataList.h \
diff --git a/Post/Makefile b/Post/Makefile
index 1c5e550467cfff0e63445e3337753529649d7457..bfa6bec1693d67b3f2e26af99caafd1f155f021d 100644
--- a/Post/Makefile
+++ b/Post/Makefile
@@ -135,6 +135,9 @@ adaptiveData${OBJEXT}: adaptiveData.cpp adaptiveData.h ../Numeric/GmshMatrix.h \
   ../Geo/SPoint3.h ../Post/PViewDataList.h ../Post/PViewData.h \
   ../Geo/SBoundingBox3d.h ../Geo/SPoint3.h ../Common/ListUtils.h \
   ../Common/OS.h
+shapeFunctions${OBJEXT}: shapeFunctions.cpp shapeFunctions.h \
+  ../Numeric/Numeric.h ../Numeric/NumericEmbedded.h \
+  ../Numeric/GmshMatrix.h ../Common/GmshConfig.h ../Common/GmshMessage.h
 OctreePost${OBJEXT}: OctreePost.cpp ../Common/Octree.h \
   ../Common/OctreeInternals.h OctreePost.h ../Common/ListUtils.h PView.h \
   ../Geo/SPoint3.h PViewDataList.h PViewData.h ../Geo/SBoundingBox3d.h \