There are many different ways to connect to a wireless network over distance and even more choices of equipment. The following are three typical examples of what maybe used to connect an Access Point over 5kms in the right conditions such as: Line of Sight (LOS) , Polarization and Fresnel Zone Clearance.

Image A uses a router which can be flashed with openWRT and although this requires some coding skills it allows for the implementation of many network functions such as firewalls, routing rules and subnet allocations.
Image B uses a standard Ethernet Bridge and would represent the cheapest setup for wireless users. The limitations are that only one IP is usable and therefore will require an additional server or router if you wish to deploy subnet IP ranges over your local network.
Image C represents simplest form of set-up where the wireless device (eg: CM9) is installed into a computer or server. This offers a great number of advantages as well as its clear simplicity. The disadvantages are that the computer needs to be located closer to the Antenna, or is used with expensive low-loss coax cable which may reduce link performance.
Information on Power Over Ethernet (PoE) can be found here: http://www.air-stream.org.au/poe