Re: Linker issue when moving from RHEL 6 to Fedora/RHEL7

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Dec 16, 2015 at 12:32 PM, Richard Shaw <hobbes1069@xxxxxxxxx> wrote:
On Wed, Dec 16, 2015 at 1:15 PM, Dave Johansen <davejohansen@xxxxxxxxx> wrote:
I'm running into a linker issue when moving code that builds on RHEL 6 to Fedora or RHEL 7. Here's a simple reproducer:

Download simple.c from https://github.com/markkilgard/glut/blob/master/progs/examples/simple.c and then run:
g++ simple.c -lglut -o simple

My SWG would be that for some reason on EL 6 you're getting the symbols for free perhaps due to the transitive nature of linking dynamic libraries? 

Since all you need to add is "-lGL" and it won't hurt anything on EL 6, seems like a pretty straight forward fix.

Yes, in this simple example the fix is easy, but in our actual code it would mean changing the build command for hundreds of programs and several of them depend on multiple libraries which depend on multiple libraries, so it would be pretty time consuming. Plus, that's not even to mention the complexity and confusion that will be added when everyone wonders why a program is linking against a library it doesn't use.
--
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxxx
http://lists.fedoraproject.org/admin/lists/devel@xxxxxxxxxxxxxxxxxxxxxxx

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Fedora Announce]     [Fedora Kernel]     [Fedora Testing]     [Fedora Formulas]     [Fedora PHP Devel]     [Kernel Development]     [Fedora Legacy]     [Fedora Maintainers]     [Fedora Desktop]     [PAM]     [Red Hat Development]     [Gimp]     [Yosemite News]
  Powered by Linux