5

I'm trying to install the ROOT CERN packages on linux, using Ubuntu 18.04, and whenever I get into the prerequisites download, with this command:

sudo apt-get install dpkg-dev cmake g++ gcc binutils libx11-dev libxpm-dev libxft-dev libxext-dev python openssl-dev

I get the following output:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: Unable to locate package openssl-dev

I've tried correcting this by configurating my repository as was suggested in this thread, yet the problem still persisted.

Would like to know how is it possible to fix this. Thank you.

Edit:

The complete output of the sudo apt update command is:

Hit:1 http://us.archive.ubuntu.com/ubuntu bionic InRelease
Hit:2 http://security.ubuntu.com/ubuntu bionic-security InRelease
Hit:3 http://us.archive.ubuntu.com/ubuntu bionic-updates InRelease
Reading package lists... Done                     
Building dependency tree       
Reading state information... Done
All packages are up to date.

I've also tried installing the libssl-dev package with sudo apt install libssl1.0-dev and the outcome remains unchanged.

pseyfert
  • 3,263
  • 3
  • 21
  • 47

3 Answers3

19

openssl-dev is for RedHat and CentOS systems.
Install openssl and libssl-dev instead, which works on Ubuntu and Debian.

sudo apt-get install openssl libssl-dev
de Broglie
  • 317
  • 2
  • 7
  • 1
    I am sorry, but for Fedora derivates (such as RHEL and CentOS), the package is called `openssl-devel`, not `openssl-dev`. Shortening `-devel` to `-dev` in package names is typically for Debian (and derivates). – rsc Mar 27 '21 at 23:29
  • Is it necessary to install the `openssl` package as well as `libssl-dev`? Assuming just a development use case. – Paul Rooney Feb 02 '22 at 02:41
1

Type: sudo apt install libssl-dev without the version number, that worked for me. I am using Ubuntu 20.04.1 LTS.

  • Actually, if you are using https://root.cern/install/dependencies/#ubuntu-and-other-debian-based-distributions, follow the instructions for Debian. – Diana Rojas Jan 14 '21 at 11:43
  • The easiest way to install root on Ubuntu is with snap: https://snapcraft.io/install/root-framework/ubuntu – Diana Rojas Jan 14 '21 at 12:16
0

May you can install it by using def command (if it's available!)

eg.: sudo dnf install openssl-devel

ghillo
  • 31
  • 1