Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 730340

Summary: app-office/lyx-2.3.3 CXXFLAGS=-std=c++14 - insets/ExternalTemplate.cpp:194:2: error: ‘for_each’ was not declared in this scope
Product: Gentoo Linux Reporter: Paweł Metelski <pabou88>
Component: Current packagesAssignee: Alexis Ballier <aballier>
Status: RESOLVED DUPLICATE    
Severity: normal CC: cjk, dirk
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: emerge --info
build.log
lyx 2.3.3 build fix

Description Paweł Metelski 2020-07-01 11:23:30 UTC
insets/ExternalTemplate.cpp: In member function ‘void lyx::external::Template::dumpFormats(std::ostream&) const’:
insets/ExternalTemplate.cpp:194:2: error: ‘for_each’ was not declared in this scope
  for_each(formats.begin(), formats.end(), DumpFormat(os));
  ^~~~~~~~
Comment 1 Andreas Sturmlechner gentoo-dev 2020-07-01 12:39:16 UTC
emerge --info, build.log, you should know the drill.
Comment 2 Jeroen Roovers (RETIRED) gentoo-dev 2020-07-01 12:40:44 UTC
Please post your `emerge --info' output in a comment.
Please attach the entire build log to this bug report.
Comment 3 Jeroen Roovers (RETIRED) gentoo-dev 2020-07-01 12:41:13 UTC
Are you actually setting CXXFLAGS=-std=c++14 ??
Comment 4 emerald 2020-07-03 07:09:39 UTC
Created attachment 647442 [details]
emerge --info

emerge --info
Comment 5 emerald 2020-07-03 07:10:02 UTC
Created attachment 647444 [details]
build.log
Comment 6 emerald 2020-07-03 07:12:45 UTC
Created attachment 647448 [details, diff]
lyx 2.3.3 build fix

It appears lyx 2.3.3 is missing the <algorithm> include for for_each, however what made the change for it not to be included anymore i don't know (maybe boost 1.73?).
Most other source code files contain the algorithm include, so i assume it was an oversight by the developers.
Comment 7 Ulrich Müller gentoo-dev 2020-07-13 19:52:05 UTC

*** This bug has been marked as a duplicate of bug 721962 ***