Re: packagers note: do not run ld directly

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

 



On Wed, 2007-08-08 at 12:46 -0700, Roland McGrath wrote:
> An easy mistake sometimes made in packages' build setup is to run ld
> directly rather than via gcc, e.g. when creating a shared library.
> It is always wrong to run ld directly when a linking user-mode
> executable or shared library.  This rule is not Fedora-specific, so
> be sure to get the makefile fixes upstream.
> 
> e.g. a makefile line:
> 
> 	$(LD) -shared -o $@ $(objs)
> 
> should be:	
> 
> 	$(CC) -shared -o $@ $(objs)
> 
> Best practice is to use consistently the flags otherwise passed to
> the compiler, and also use LDFLAGS, i.e.:
> 
> 	$(CC) $(CFLAGS) $(LDFLAGS) -shared -o $@ $(objs)

This fix will also fix sparc64, we've been sending patches to fix this
upstream for some time now (but only for core libs).

~spot

-- 
fedora-devel-list mailing list
fedora-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/fedora-devel-list

[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