[MacPorts] #55733: lz4 @1.8.1.2: fails to build on systems following LibcxxOnOlderSystems (was: lz4 fails to build on Snow Leopard)
MacPorts
noreply at macports.org
Tue Jan 23 04:36:58 UTC 2018
#55733: lz4 @1.8.1.2: fails to build on systems following LibcxxOnOlderSystems
-------------------------+-------------------
Reporter: grumpybozo | Owner:
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version: 2.4.2
Resolution: | Keywords:
Port: lz4 |
-------------------------+-------------------
Changes (by ryandesign):
* keywords: haspatch snowleopard i386 =>
Old description:
> Errors are typical of missing C++11 support, even on a system where
> libcxx is installed and the procedure at
> https://trac.macports.org/wiki/LibcxxOnOlderSystems has been followed. A
> snippet:
>
> {{{
> make[1]: Entering directory
> `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_archivers_lz4/lz4/work/lz4-1.8.1.2/contrib/gen_manual'
> /opt/local/bin/clang++-mp-5.0 -arch i386 -O3 -Wall -Wextra -Wcast-qual
> -Wcast-align -Wshadow -Wstrict-aliasing=1 -Wswitch-enum -Wno-comment
> gen_manual.cpp -o gen_manual
> Undefined symbols for architecture i386:
> "std::ctype<char>::_M_widen_init() const", referenced from:
> print_line(std::__cxx11::basic_stringstream<char,
> std::char_traits<char>, std::allocator<char> >&,
> std::__cxx11::basic_string<char, std::char_traits<char>,
> std::allocator<char> >) in gen_manual-327bb0.o
> _main in gen_manual-327bb0.o
> "std::__cxx11::basic_string<char, std::char_traits<char>,
> std::allocator<char> >::find_last_not_of(char const*, unsigned long,
> unsigned long) const", referenced from:
> trim(std::__cxx11::basic_string<char, std::char_traits<char>,
> std::allocator<char> >&, std::__cxx11::basic_string<char,
> std::char_traits<char>, std::allocator<char> >) in gen_manual-327bb0.o
> "std::__cxx11::basic_string<char, std::char_traits<char>,
> std::allocator<char> >::find_first_not_of(char const*, unsigned long,
> unsigned long) const", referenced from:
> trim(std::__cxx11::basic_string<char, std::char_traits<char>,
> std::allocator<char> >&, std::__cxx11::basic_string<char,
> std::char_traits<char>, std::allocator<char> >) in gen_manual-327bb0.o
> "std::__cxx11::basic_string<char, std::char_traits<char>,
> std::allocator<char> >::find(char const*, unsigned long, unsigned long)
> const", referenced from:
>
> }}}
>
> This is solved by adding these lines to the Portfile:
>
> {{{
> depends_lib-append lib:libc++.1:libcxx
> configure.cxxflags -stdlib=libc++
> configure.cxx clang++ -stdlib=libc++
> }}}
New description:
Errors are typical of missing C++11 support, even on a system where libcxx
is installed and the procedure at LibcxxOnOlderSystems has been followed.
A snippet:
{{{
make[1]: Entering directory
`/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_archivers_lz4/lz4/work/lz4-1.8.1.2/contrib/gen_manual'
/opt/local/bin/clang++-mp-5.0 -arch i386 -O3 -Wall -Wextra -Wcast-qual
-Wcast-align -Wshadow -Wstrict-aliasing=1 -Wswitch-enum -Wno-comment
gen_manual.cpp -o gen_manual
Undefined symbols for architecture i386:
"std::ctype<char>::_M_widen_init() const", referenced from:
print_line(std::__cxx11::basic_stringstream<char,
std::char_traits<char>, std::allocator<char> >&,
std::__cxx11::basic_string<char, std::char_traits<char>,
std::allocator<char> >) in gen_manual-327bb0.o
_main in gen_manual-327bb0.o
"std::__cxx11::basic_string<char, std::char_traits<char>,
std::allocator<char> >::find_last_not_of(char const*, unsigned long,
unsigned long) const", referenced from:
trim(std::__cxx11::basic_string<char, std::char_traits<char>,
std::allocator<char> >&, std::__cxx11::basic_string<char,
std::char_traits<char>, std::allocator<char> >) in gen_manual-327bb0.o
"std::__cxx11::basic_string<char, std::char_traits<char>,
std::allocator<char> >::find_first_not_of(char const*, unsigned long,
unsigned long) const", referenced from:
trim(std::__cxx11::basic_string<char, std::char_traits<char>,
std::allocator<char> >&, std::__cxx11::basic_string<char,
std::char_traits<char>, std::allocator<char> >) in gen_manual-327bb0.o
"std::__cxx11::basic_string<char, std::char_traits<char>,
std::allocator<char> >::find(char const*, unsigned long, unsigned long)
const", referenced from:
}}}
This is solved by adding these lines to the Portfile:
{{{
depends_lib-append lib:libc++.1:libcxx
configure.cxxflags -stdlib=libc++
configure.cxx clang++ -stdlib=libc++
}}}
--
Comment:
This is occurring because the port uses `use_configure no`, which means
the portfile is responsible for supplying the correct flags to the build
system, and this portfile has failed to do so.
--
Ticket URL: <https://trac.macports.org/ticket/55733#comment:3>
MacPorts <https://www.macports.org/>
Ports system for macOS
More information about the macports-tickets
mailing list