This content originally appeared on DEV Community and was authored by Sam Erickson
I recently ran into some issues installing diesel_cli on openSUSE. I wanted to use the package with postgres
only so I tried entering the following command from their getting started page:
# The package that is required according to the docs
zypper install libpq5
cargo install diesel_cli --no-default-features --features postgres
Then I get met with this fun error message:
The last few lines are of interest:
= note: /usr/lib64/gcc/x86_64-suse-linux/13/../../../../x86_64-suse-linux/bin/ld: cannot find -lpq: No such file or directory
collect2: error: ld returned 1 exit status
I started just installing all packages that I could find using zypper search
that related to postgres and tried the installation process of diesel_cli
after each one. Eventually, after much trial and error I found the missing package:
sudo zypper install ghc-postgresql-libpq-devel
After installing this I was able to build diesel
.
This content originally appeared on DEV Community and was authored by Sam Erickson
Sam Erickson | Sciencx (2023-04-07T18:06:50+00:00) Installing diesel_cli on OpenSUSE Tumbleweed. Retrieved from https://www.scien.cx/2023/04/07/installing-diesel_cli-on-opensuse-tumbleweed/
Please log in to upload a file.
There are no updates yet.
Click the Upload button above to add an update.