Page MenuHomeFreeBSD

Compile textproc/hunspell with C++11 instead of default
ClosedPublic

Authored by jhibbits on Sep 27 2017, 7:13 PM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, May 31, 5:27 PM
Unknown Object (File)
Thu, May 23, 3:41 AM
Unknown Object (File)
May 6 2024, 6:40 PM
Unknown Object (File)
Apr 27 2024, 12:40 PM
Unknown Object (File)
Apr 27 2024, 12:40 PM
Unknown Object (File)
Apr 27 2024, 11:45 AM
Unknown Object (File)
Apr 27 2024, 11:44 AM
Unknown Object (File)
Apr 27 2024, 11:11 AM
Subscribers

Details

Summary

www/firefox is built with c++11 and needs hunspell built with c++11 for various
ABI related symbols, using lang/gcc6 as the compiler. clang with libc++ seems to be fine.

Test Plan

Built www/firefox. Might need to build more (freshports shows ~35 direct dependents)

Diff Detail

Repository
rP FreeBSD ports repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

Can you show the error message the change tries to fix? If it affects ABI of hunspell (rather than libstdc++) you may need an exp-run or to check all consumers yourself.

textproc/hunspell/Makefile
6 ↗(On Diff #33499)

Bump PORTREVISION after this line to force rebuild of the binary package.

22 ↗(On Diff #33499)

USES=compiler:c++11-lib would be slightly more correct for WITH_CLANG=1 + WITHOUT_CLANG_IS_CC=1 (in src.conf) on i386/amd64 which was default for FreeBSD 9.x. Other archs default to GCC, so there's no difference.

24 ↗(On Diff #33499)

Re-indent with tabs instead of spaces.

Can you show the error message the change tries to fix? If it affects ABI of hunspell (rather than libstdc++) you may need an exp-run or to check all consumers yourself.

../../extensions/spellcheck/hunspell/glue/Unified_cpp_hunspell_glue0.o: In function `mozHunspell::SetDictionary(char16_t const*)':
Unified_cpp_hunspell_glue0.cpp:(.text._ZN11mozHunspell13SetDictionaryEPKDs+0x4a4): undefined reference to `Hunspell::get_dict_encoding[abi:cxx11]() const'
../../extensions/spellcheck/hunspell/glue/Unified_cpp_hunspell_glue0.o: In function `mozHunspell::Check(char16_t const*, bool*)':
Unified_cpp_hunspell_glue0.cpp:(.text._ZN11mozHunspell5CheckEPKDsPb+0x148): undefined reference to `Hunspell::spell(std::cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, int*, std::cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >*)'
../../extensions/spellcheck/hunspell/glue/Unified_cpp_hunspell_glue0.o: In function `mozHunspell::Suggest(char16_t const*, char16_t***, unsigned int*)':
Unified_cpp_hunspell_glue0.cpp:(.text._ZN11mozHunspell7SuggestEPKDsPPPDsPj+0x16c): undefined reference to `Hunspell::suggest(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)'

I'll post a new diff after my current poudriere run completes.

textproc/hunspell/Makefile
6 ↗(On Diff #33499)

Oops, sorry. Always forget that.

22 ↗(On Diff #33499)

What's the difference in behavior between the two?

Libreoffice and qt5 don't build for powerpc64 (other bugs are filed for those), so I can't test build those myself.

This revision was automatically updated to reflect the committed changes.