0

I need to build a c++ project in SLES (SUSE Linux Enterprise Server) environment. While trying to installing build tools I am facing issue (add repo is failing) in installing c++ (gcc) compiler. Issues are as follows:

  • I tried to install it with the command:

    $ sudo zypper install gcc-c++

  • It is throwing the below error.

   Loading repository data...
   Reading installed packages...
   No matching items found.
  • I tried to add the repo with the command:
   $ sudo zypper addrepo https://download.opensuse.org/repositories/openSUSE:Leap:15.2/standard/openSUSE:Leap:15.2.repo
  • It throws the below error.
   File '/repositories/openSUSE:Leap:15.2/standard/openSUSE:Leap:15.2.repo' not found on medium 'https://download.opensuse.org/'
  • I listed the added repo with command:

    $ zypper lr -d

    # | Alias                | Name                                 | Enabled | GPG Check | Refresh | Priority | Type   | URI                                                                       | Service
    --+----------------------+--------------------------------------+---------+-----------+---------+----------+--------+---------------------------------------------------------------------------+--------
    1 | devel_tools_building | Tools for building software (SLE_15) | Yes     | (r ) Yes  | No      |   99     | rpm-md | https://download.opensuse.org/repositories/devel:/tools:/building/SLE_15/ |
  • I looked into the repo, and didn't find any gcc compiler there.

Does anyone have idea why sudo zypper addrepo command is failing and how to resolve it?

Thanks in advance.

1 Answer 1

1

I have installed it from here,

localhost:/etc/zypp/repos.d # cat OSS.repo
[OSS]
name=OSS (openSUSE_Tumbleweed)
enabled=1
autorefresh=0
baseurl=https://download.opensuse.org/tumbleweed/repo/oss/
type=rpm-md
gpgcheck=1
gpgkey=https://download.opensuse.org/tumbleweed/repo/oss/repodata/repomd.xml.key

localhost:/etc/zypp/repos.d # zypper refresh

localhost:/etc/zypp/repos.d # zypper install gcc-c++

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .