Opened 4 months ago

Closed 4 months ago

#70381 closed defect (fixed)

kismet @2022-08-R1: error: no template named 'binary_function' in namespace 'std'

Reported by: cbitterfield (Colin Bitterfield) Owned by: ryandesign (Ryan Carsten Schmidt)
Priority: Normal Milestone:
Component: ports Version:
Keywords: Cc:
Port: kismet

Description

:info:build In file included from trackedelement.cc:32:
:info:build ./alphanum.hpp:307:38: error: no template named 'binary_function' in namespace 'std'; did you mean '__binary_function'?
:info:build   struct alphanum_less : public std::binary_function<Ty, Ty, bool>
:info:build                                 ~~~~~^~~~~~~~~~~~~~~
:info:build                                      __binary_function
:info:build /Library/Developer/CommandLineTools/SDKs/MacOSX14.sdk/usr/include/c++/v1/__functional/binary_function.h:49:1: note: '__binary_function' declared here
:info:build using __binary_function = __binary_function_keep_layout_base<_Arg1, _Arg2, _Result>;
:info:build ^
:info:build 1 error generated.
:info:build gnumake: *** [trackedelement.cc.o] Error 1
:info:build gnumake: *** Waiting for unfinished jobs....

Attachments (1)

main.log (269.9 KB) - added by cbitterfield (Colin Bitterfield) 4 months ago.
Build Log

Download all attachments as: .zip

Change History (3)

Changed 4 months ago by cbitterfield (Colin Bitterfield)

Attachment: main.log added

Build Log

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

Summary: Kismet doesn't build - Sonoma ARMkismet @2022-08-R1: error: no template named 'binary_function' in namespace 'std'

This code is compiling with -std=gnu++17, putting the compiler in C++17 mode, but it also uses std::binary_function which was deprecated in C++11 and removed in C++17.

See this bug report: https://github.com/kismetwireless/kismet/issues/476

And this fix: https://github.com/kismetwireless/kismet/commit/5bae9c68ce45940e03fda7d8abbbfda0fca9e95c

Also we should update the port to the latest version.

comment:2 Changed 4 months ago by ryandesign (Ryan Carsten Schmidt)

Owner: set to ryandesign
Resolution: fixed
Status: newclosed

In d7c34602fe98e357b996e5c7df374184ab3e5bf4/macports-ports (master):

kismet: Remove use of std::binary_function

Fixes build with newer clang compilers.

Closes: #70381

Note: See TracTickets for help on using tickets.