At 5 meters, your actually well within the allowed length of duct work allowed for a dryer vent (depending on how many bends you have).
International Residential Code (IRC) 2012
Section M1502 Clothes Dryer Exhaust
M1502.4.1 Material and size.
Exhaust ducts shall have a smooth interior finish and be constructed of metal having a minimum thickness of 0.0157 inches (0.3950 mm) (No. 28 gage). The duct shall be 4 inches (102 mm) nominal in diameter.
M1502.4.2 Duct installation.
Exhaust ducts shall be supported at intervals not to exceed 12 feet (3658 mm) and shall be secured in place. The insert end of the duct shall extend into the adjoining duct or fitting in the direction of airflow. Exhaust duct joints shall be sealed in accordance with Section M1601.4.1 and shall be mechanically fastened. Ducts shall not be joined with screws or similar fasteners that protrude more than 1/8 inch (3.2 mm) into the inside of the duct.
M1502.4.4 Duct length.
The maximum allowable exhaust duct length shall be determined by one of the methods specified in Section M1502.4.4.1 or M1502.4.4.2.
M1502.4.4.1 Specified length.
The maximum length of the exhaust duct shall be 35 feet (10 668 mm) from the connection to the transition duct from the dryer to the outlet terminal. Where fittings are used, the maximum length of the exhaust duct shall be reduced in accordance with Table M1502.4.4.1. The maximum length of the exhaust duct does not include the transition duct.
M1502.4.4.2 Manufacturer’s instructions.
The size and maximum length of the exhaust duct shall be determined by the dryer manufacturer’s installation instructions. The code official shall be provided with a copy of the installation instructions for the make and model of the dryer at the concealment inspection. In the absence of fitting equivalent length calculations from the clothes dryer manufacturer, Table M1502.4.4.1 shall be used.
Just make sure you construct the duct with rigid metal and you should be fine.
Moisture in a dryer vent (water) may be caused by a blockage due to lint - make sure the lint trap is clean and using a rigid duct would allow air to flow more freely.