Page 2 of 3 FirstFirst 123 LastLast
Results 11 to 20 of 23

Thread: Support for older gcc versions

  1. #11
    Join Date
    Feb 2010
    Location
    Germany
    Posts
    3,010

    Default Re: Support for older gcc versions

    Quote Originally Posted by eldiener View Post
    I found the latest packages for gcc4, gcc5, and gcc6 for Leap 42.3 on the website https://pkgs.org/. None of these packages, according to 'rpm -ql' , overwrite the main gcc package.
    You could also take a look at the following Leap 42.3 repository: <http://download.opensuse.org/reposit...p_42.3/x86_64/>.
    • gcc33 and gcc48 …

    BTW: ' > rpm --query --list --file «file name of the downloaded RPM package» ' …

    Be that all as it may, I'm still not convinced that, it's a good idea to attempt to maintain «old code» which needs «old compiler versions» with a «newest, latest, up-to-date» system which doesn't really support the compiler versions needed to maintain the code to be maintained …
    • There's too much danger in the compiler and library dependencies to ensure a reliable and correct maintenance process, IMNSHO …

    Therefore, I maintain my view that, if «old» code, which requires «old» compiler versions has to be be maintained then, it's usually more reliable, with verifiable results, to use an «older» system (with the last available patches installed) to perform the maintenance …
    • Given that, the maintenance team are using an isolated network segment ( which they should do anyway … ) the chances of a "security issue" due to the «old» system version are, IMNSHO, negligible -- read, can be safely ignored …


    [Not the Originator]:
    Please note that, there are situations where «old» code cannot be ported to matched to the current supported compiler version(s) for whatever reason and, therefore, «old» systems need to be kept available for any maintenance needed …

  2. #12
    Join Date
    Jun 2008
    Location
    San Diego, Ca, USA
    Posts
    12,165
    Blog Entries
    2

    Default Re: Support for older gcc versions

    Quote Originally Posted by eldiener View Post
    I found the latest packages for gcc4, gcc5, and gcc6 for Leap 42.3 on the website https://pkgs.org/. None of these packages, according to 'rpm -ql' , overwrite the main gcc package. I will try to install each one, for gcc c and gcc c++ into Leap 15.0. That https://pkgs.org is a wonderful website.
    To my eye,
    The danger still exists in this package repository, it's probably hardly different from any other that is likely a mirror of what once existed. There is no reason for anyone to modify or remove any packages.

    So,
    Again beware of packages which might over-write <defaults>.
    Packages which only add without changing defaults are the only ones that are "safe."

    Else,
    - Install and use the update-alternatives as I described, you can set gcc persistently regardless what is default
    - Do a "force install" of your gcc which should over-write anything that's been modified.

    TSU
    Beginner Wiki Quickstart - https://en.opensuse.org/User:Tsu2/Quickstart_Wiki
    Solved a problem recently? Create a wiki page for future personal reference!
    Learn something new?
    Attended a computing event?
    Post and Share!

  3. #13

    Default Re: Support for older gcc versions

    Quote Originally Posted by dcurtisfra View Post
    You could also take a look at the following Leap 42.3 repository: <http://download.opensuse.org/reposit...p_42.3/x86_64/>.
    • gcc33 and gcc48 …

    BTW: ' > rpm --query --list --file «file name of the downloaded RPM package» ' …

    Be that all as it may, I'm still not convinced that, it's a good idea to attempt to maintain «old code» which needs «old compiler versions» with a «newest, latest, up-to-date» system which doesn't really support the compiler versions needed to maintain the code to be maintained …
    • There's too much danger in the compiler and library dependencies to ensure a reliable and correct maintenance process, IMNSHO …

    Therefore, I maintain my view that, if «old» code, which requires «old» compiler versions has to be be maintained then, it's usually more reliable, with verifiable results, to use an «older» system (with the last available patches installed) to perform the maintenance …
    • Given that, the maintenance team are using an isolated network segment ( which they should do anyway … ) the chances of a "security issue" due to the «old» system version are, IMNSHO, negligible -- read, can be safely ignored …


    [Not the Originator]:
    Please note that, there are situations where «old» code cannot be ported to matched to the current supported compiler version(s) for whatever reason and, therefore, «old» systems need to be kept available for any maintenance needed …
    If you have created a library for others to use it is often the case that you must maintain that library with different compiler/versions, and not just the latest version(s) offered by a particular compiler. I am a Boost C++ developer so it is often important that I test code with earlier versions of compilers. Of course if you are creating an application strictly for your own use there is generally little problem using the latest version(s) of a compiler.

    OpenSuse previous to 15.0 did support some older versions of gcc. I can understand that they have dropped that support, but that does not solve my need. Other Linux distros do support some older versions of gcc, starting with 4.x on up through 7.3 and/or 8.1. I do not blame OpenSuse for not wanting to do so, but it is unfair to be criticized for attempting to solve my own problem when there is a totally valid reason for wanting to be able to install earlier versions.

  4. #14

    Default Re: Support for older gcc versions

    Quote Originally Posted by tsu2 View Post
    To my eye,
    The danger still exists in this package repository, it's probably hardly different from any other that is likely a mirror of what once existed. There is no reason for anyone to modify or remove any packages.

    So,
    Again beware of packages which might over-write <defaults>.
    Packages which only add without changing defaults are the only ones that are "safe."

    Else,
    - Install and use the update-alternatives as I described, you can set gcc persistently regardless what is default
    - Do a "force install" of your gcc which should over-write anything that's been modified.

    TSU
    Each of the versions above installs all files to version specific directories or creates version specific filenames. I do not see how such actions can override defaults. None of them replace /usr/bin/gcc or /usr/bin/g++ or any supporting files for the default version of gcc/g++.

  5. #15
    Join Date
    Jun 2008
    Location
    San Diego, Ca, USA
    Posts
    12,165
    Blog Entries
    2

    Default Re: Support for older gcc versions

    Quote Originally Posted by eldiener View Post
    Each of the versions above installs all files to version specific directories or creates version specific filenames. I do not see how such actions can override defaults. None of them replace /usr/bin/gcc or /usr/bin/g++ or any supporting files for the default version of gcc/g++.
    I think you're looking at the wrong things.
    As you describe, you should always see each gcc version in its own directory, and each of these gcc can be invoked by specifying the <exact> binary final name, but what about the default when you simply invoke gcc without specifying a specific version?

    In each openSUSE release, there will be one gcc which will be configured as the default where gcc (no version specified) will point (possibly link) to a gcc in its own directory.
    This means that if you install one of these "default gcc" packages from an old version of openSUSE, you will likely change the default and this can have consequences... GPU modules are often compiled on the fly during boot, other kernel modules and apps might also be built automatically and you will want those built with the gcc that's recommended for your openSUSE (nowadays likely LEAP 15 or TW). You don't want to be building modules with a gcc that was default for LEAP 42.1 or even 13.2 or earlier.

    So,
    As I described, I highly recommend you take care not to leave your system with a non-default gcc configured as your default by accident.

    TSU
    Beginner Wiki Quickstart - https://en.opensuse.org/User:Tsu2/Quickstart_Wiki
    Solved a problem recently? Create a wiki page for future personal reference!
    Learn something new?
    Attended a computing event?
    Post and Share!

  6. #16

    Default Re: Support for older gcc versions

    Quote Originally Posted by tsu2 View Post
    I think you're looking at the wrong things.
    As you describe, you should always see each gcc version in its own directory, and each of these gcc can be invoked by specifying the <exact> binary final name, but what about the default when you simply invoke gcc without specifying a specific version?

    In each openSUSE release, there will be one gcc which will be configured as the default where gcc (no version specified) will point (possibly link) to a gcc in its own directory.
    This means that if you install one of these "default gcc" packages from an old version of openSUSE, you will likely change the default and this can have consequences... GPU modules are often compiled on the fly during boot, other kernel modules and apps might also be built automatically and you will want those built with the gcc that's recommended for your openSUSE (nowadays likely LEAP 15 or TW). You don't want to be building modules with a gcc that was default for LEAP 42.1 or even 13.2 or earlier.

    So,
    As I described, I highly recommend you take care not to leave your system with a non-default gcc configured as your default by accident.

    TSU
    All three packages are from 42.3. Are you saying that OpenSuse will somehow replace the default gcc with one of these if I install it in 15.0 ? If so how can I know in advance if this will happen ? As I explained the rpm itself for each of these packages shows the filenames for gcc and g++ as gcc-n and g++-n and not as gcc and g++ along with support files in directories of somedirectory'n' and not the equivalent somedirectory of the default gcc or g++. So why would an attempted install of one of these earler versions of gcc/g++ from Laep 42.3 install itself as the default gcc/g++ on 15.0 ?

  7. #17
    Join Date
    Jun 2008
    Location
    San Diego, Ca, USA
    Posts
    12,165
    Blog Entries
    2

    Default Re: Support for older gcc versions

    Quote Originally Posted by eldiener View Post
    All three packages are from 42.3. Are you saying that OpenSuse will somehow replace the default gcc with one of these if I install it in 15.0 ? If so how can I know in advance if this will happen ? As I explained the rpm itself for each of these packages shows the filenames for gcc and g++ as gcc-n and g++-n and not as gcc and g++ along with support files in directories of somedirectory'n' and not the equivalent somedirectory of the default gcc or g++. So why would an attempted install of one of these earler versions of gcc/g++ from Laep 42.3 install itself as the default gcc/g++ on 15.0 ?
    If you inspected the package contents and didn't find a generic gcc file, you should be OK with those packages.

    As I described in my Wiki, you can always doublecheck by querying your system default
    Code:
    gcc --version
    TSU
    Beginner Wiki Quickstart - https://en.opensuse.org/User:Tsu2/Quickstart_Wiki
    Solved a problem recently? Create a wiki page for future personal reference!
    Learn something new?
    Attended a computing event?
    Post and Share!

  8. #18
    Join Date
    Feb 2010
    Location
    Germany
    Posts
    3,010

    Exclamation Re: Support for older gcc versions

    Quote Originally Posted by eldiener View Post
    I am a Boost C++ developer so it is often important that I test code with earlier versions of compilers.
    Yes!
    And, therefore, my suggestion is, that, you should attempt to have more than a few, physical, platforms running with the last available patches/updates of «older» operating systems with the (from then) supported GCC versions -- for testing purposes -- forget about the security implications -- you're maintaining a test environment/laboratory -- which should be isolated from the rest of the world anyway …
    • Putting my ISTQB certified Tester hat on: AFAICS it's not a good idea to attempt to run a test environment which «needs» older GCC versions on «newer» platforms which do not support the «older» compiler versions …

  9. #19
    Join Date
    Feb 2010
    Location
    Germany
    Posts
    3,010

    Exclamation Re: Support for older gcc versions

    Please note that, the support for openSUSE Leap 42.3 has been extended -- news out today at 14:19 Central European Summer Time:


    openSUSE News: <https://news.opensuse.org/>.

  10. #20
    Join Date
    Jun 2008
    Location
    San Diego, Ca, USA
    Posts
    12,165
    Blog Entries
    2

    Default Re: Support for older gcc versions

    Quote Originally Posted by dcurtisfra View Post
    Yes!
    And, therefore, my suggestion is, that, you should attempt to have more than a few, physical, platforms running with the last available patches/updates of «older» operating systems with the (from then) supported GCC versions -- for testing purposes -- forget about the security implications -- you're maintaining a test environment/laboratory -- which should be isolated from the rest of the world anyway …
    • Putting my ISTQB certified Tester hat on: AFAICS it's not a good idea to attempt to run a test environment which «needs» older GCC versions on «newer» platforms which do not support the «older» compiler versions …
    I dunno...
    People who have seen a list of vms in my vm manager have often remarked about the long list...
    And I do absolutely run all my development in virtual machines (because they break) and to isolate environments to prevent cross-contamination,

    But if a gcc version build is the only diff between what is done,
    I wouldn't likely create a whole vm just for that kind of test because it's too easy, almost trivial to run each test without contamination.

    TSU
    Beginner Wiki Quickstart - https://en.opensuse.org/User:Tsu2/Quickstart_Wiki
    Solved a problem recently? Create a wiki page for future personal reference!
    Learn something new?
    Attended a computing event?
    Post and Share!

Page 2 of 3 FirstFirst 123 LastLast

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •