Build Gmsh also as library

This allows other software to link to gmsh and onelab, e.g. getDP.