when installing idevicerestore i get errors saying i`m missing libraries

The prerequisites are listed in the README or alternatively on the github idevicerestore project page

Development Packages of:
    libimobiledevice
    libirecovery
    libusbmuxd
    libplist
    libzip
    openssl

On Debian-based systems, development packages generally use a -dev suffix. The following packages should be available from the Ubuntu repositories:

libimobiledevice-dev libusbmuxd-dev libplist-dev libzip-dev

openssl is a bit of a special case - you will need to choose between

libcurl4-gnutls-dev - development files and documentation for libcurl (GnuTLS flavour)
libcurl4-nss-dev - development files and documentation for libcurl (NSS flavour)
libcurl4-openssl-dev - development files and documentation for libcurl (OpenSSL flavour)

As far as I know, Ubuntu repositories do not contain a pre-built version of libirecovery so you will need to locate and build that yourself