[GRASS-dev] [GRASS GIS] #1757: LD_SEARCH_FLAGS incorrect for NetBSD

GRASS GIS trac at osgeo.org
Thu Mar 21 14:37:51 PDT 2013

#1757: LD_SEARCH_FLAGS incorrect for NetBSD
 Reporter:  brook        |       Owner:  grass-dev@…              
     Type:  defect       |      Status:  new                      
 Priority:  critical     |   Milestone:  7.0.0                    
Component:  Default      |     Version:  svn-trunk                
 Keywords:               |    Platform:  Other Unix               
      Cpu:  Unspecified  |  

Comment(by glynn):

 Replying to [comment:5 mmetz]:

 > I think I discovered inconsistencies, if not errors, in the G7 Make
 system: flags meant for cc are also passed to ld and vice versa, probably
 because it is assumed that ld = cc.

 Programs written in C are linked with $(CC). Programs written in C++ are
 linked with $(CXX). Shared libraries are linked with $(SHLIB_LD). All
 three are passed $(LDFLAGS). $(SHLIB_LD) is additionally passed

 In practical terms, this requires that both programs and shared libraries
 are linked using the compiler front-end. The build system doesn't use
 $(LD) (which is normally the underlying linker).

 The main problem with separating the two is that configure doesn't attempt
 to maintain any distinction, e.g. it only has one LDFLAGS variable.
 Simlarly, "pkg-config --libs ..." will generate switches suitable for
 passing to the compiler (i.e. with the -Wl, prefix).

Ticket URL: <https://trac.osgeo.org/grass/ticket/1757#comment:6>
GRASS GIS <http://grass.osgeo.org>

More information about the grass-dev mailing list