[MacPorts] #51520: llvm-3.9 @3.9-r270400_0+assertions+debug build failure on snow leopard due to missing strnlen function - and fix
MacPorts
noreply at macports.org
Thu Jun 9 09:49:08 PDT 2016
#51520: llvm-3.9 @3.9-r270400_0+assertions+debug build failure on snow leopard due
to missing strnlen function - and fix
-------------------------------------+-------------------------
Reporter: kenneth.f.cunningham@… | Owner: jeremyhu@…
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version: 2.3.4
Resolution: | Keywords: snowleopard
Port: llvm-3.9 |
-------------------------------------+-------------------------
Comment (by kenneth.f.cunningham@…):
I went through the process of installing
<https://trac.macports.org/wiki/LibcxxOnOlderSystems> and then rebuilt
clang-3.9, but this didn't fix the missing definition.
This issue seems to apply to other software as well, of course.
<http://stackoverflow.com/questions/32468480/strnlen-does-not-exist-in-
gcc-4-2-1-on-mac-os-x-10-6-8-how-to-define-it>.
Given SL's market share, it may not be reasonable to expect all upstream
authors to support systems without strnlen. What do you think of the idea
of modifying /usr/include/string.h on snow leopard to static inline the
rare missing functions in the header file? I realize it's not a purist
approach -- probably first class of first day of computer science school
tells you not to do that.
If that is not acceptable, there a way to override string.h, calling one
in the /opt directory first that inlines the few missing functions after
calling the original /usr/include/string.h. That at least leaves the
factory distribution unmodified.
--
Ticket URL: <https://trac.macports.org/ticket/51520#comment:3>
MacPorts <https://www.macports.org/>
Ports system for OS X
More information about the macports-tickets
mailing list