Mechanical properties and structural integrity of devices based on sol–gel mesoporous oxides thin films