Opened 4 years ago

Closed 4 years ago

#61122 closed defect (fixed)

RigCtldGUI: Doesn't use MacPorts LDFLAGS

Reported by: ryandesign (Ryan Carsten Schmidt) Owned by: ra1nb0w
Priority: Normal Milestone:
Component: ports Version: 2.6.3
Keywords: Cc:
Port: RigCtldGUI

Description

RigCtldGUI fails to build on 10.6 because although it includes the legacysupport portgroup it evidently doesn't use MacPorts LDFLAGS so it still fails to link with the legacysupport library which would have provided getline:

https://build.macports.org/builders/ports-10.6_x86_64-builder/builds/33613/steps/install-port/logs/stdio

/opt/local/bin/clang++-mp-9.0 -o RigCtl Rig.o Hamlib.o Winkey.o rigctl_parse.o dumpcaps.o sprintflst.o fmemopen.o -lfltk -lportaudio -lhamlib -lpthread
Undefined symbols for architecture x86_64:
  "_getline", referenced from:
      get_token(__sFILE*, char*, int, char*, int) in Rig.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

Change History (2)

comment:1 Changed 4 years ago by ryandesign (Ryan Carsten Schmidt)

Note also that this is using clang++ to link but isn't using MacPorts CXXFLAGS to do so (note the absence of the -stdlib flag) so that flag should be added to LDFLAGS manually when the C++ compiler is clang:

if {[string match *clang* ${configure.cxx}]} {
    configure.ldflags-append -stdlib=${configure.cxx_stdlib}
}

comment:2 Changed 4 years ago by Davide Gerhard <ra1nb0w@…>

Resolution: fixed
Status: assignedclosed

In b12e72b56db7944b22c05066237da5a62429ee6e/macports-ports (master):

RigCtldGUI: fix LDFLAGS usage

thanks ryan!

Closes: #61122

Note: See TracTickets for help on using tickets.