<div dir="ltr"><div>Including it also fixes the build in my cross-build environment. Did you indicate you were initially building with MSVC? That might explain the difference.</div><div><br></div><div>--Greg</div></div><br><div class="gmail_quote gmail_quote_container"><div dir="ltr" class="gmail_attr">On Tue, Jul 8, 2025 at 9:54 PM DM Smith <<a href="mailto:dmsmith@crosswire.org">dmsmith@crosswire.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div>While I don’t get the error in my local build environment, I get it on the crosswire server. If I include <cstring>, it compiles just fine.<div>I’ll guess that my build environment includes it indirectly.<br><div><br></div><div>DM<br id="m_-4153283895800732367lineBreakAtBeginningOfMessage"><div><br><blockquote type="cite"><div>On Jul 8, 2025, at 10:40 PM, DM Smith <<a href="mailto:dmsmith@crosswire.org" target="_blank">dmsmith@crosswire.org</a>> wrote:</div><br><div><div>Greg,<div>Could you try 2 different things and let me know what the result is?<div>a) include <cstring> as I didn’t include it, but somehow “It works for me”.</div><div>b) remove the namespace.</div><div><br></div><div>I’ll try the same on the crosswire server.</div><div><br></div><div>Thanks,</div><div><span style="white-space:pre-wrap"> </span>DM<br id="m_-4153283895800732367lineBreakAtBeginningOfMessage"><div><br><blockquote type="cite"><div>On Jul 8, 2025, at 9:35 PM, Greg Hellings <<a href="mailto:greg.hellings@gmail.com" target="_blank">greg.hellings@gmail.com</a>> wrote:</div><br><div><div dir="ltr"><div>DM,</div><div><br></div><div>As mentioned elsewhere, here is the compile error from gcc when trying to cross-build osis2mod. It appears to be a case where the function exists but is not namespaced to `std::` in whichever version of C++ is the default version. From a quick glance around it appears there is a difference between <string.h>, which defines the function for C and <cstring> which defines the function for C++ within the `std` namespace.</div><div><br></div><div>--Greg</div><div><br></div><div>sword> osis2mod.cpp:371:19: error: 'strpbrk' is not a member of 'std'; did you mean 'strpbrk'?<br>sword> 371 | if (!std::strpbrk(bufStart, "! :")) {<br>sword> | ^~~~~~~<br>sword> In file included from /nix/store/np3pb3a6wd1bf55hp0rl3i64mfzrcilm-x86_64-w64-mingw32-gcc-14.2.1.20250322/x86_64-w64-mingw32/sys-include/io.h:<br>10,<br>sword> from /nix/store/np3pb3a6wd1bf55hp0rl3i64mfzrcilm-x86_64-w64-mingw32-gcc-14.2.1.20250322/x86_64-w64-mingw32/sys-include/fcntl<br>.h:8,<br>sword> from osis2mod.cpp:29:<br>sword> /nix/store/np3pb3a6wd1bf55hp0rl3i64mfzrcilm-x86_64-w64-mingw32-gcc-14.2.1.20250322/x86_64-w64-mingw32/sys-include/string.h:92:31: note: 'strp<br>brk' declared here<br>sword> 92 | _CONST_RETURN char *__cdecl strpbrk(const char *_Str,const char *_Control);<br>sword> | ^~~~~~~<br>sword> osis2mod.cpp:392:40: error: 'strpbrk' is not a member of 'std'; did you mean 'strpbrk'?<br>sword> 392 | char* lookahead = std::strpbrk(bufRead, ": -");<br>sword> | ^~~~~~~<br>sword> /nix/store/np3pb3a6wd1bf55hp0rl3i64mfzrcilm-x86_64-w64-mingw32-gcc-14.2.1.20250322/x86_64-w64-mingw32/sys-include/string.h:92:31: note: 'strp<br>brk' declared here<br>sword> 92 | _CONST_RETURN char *__cdecl strpbrk(const char *_Str,const char *_Control);<br>sword> | ^~~~~~~<br>sword> osis2mod.cpp:411:34: error: 'strpbrk' is not a member of 'std'; did you mean 'strpbrk'?<br>sword> 411 | lookahead = std::strpbrk(bufRead, "! -");<br>sword> | ^~~~~~~<br>sword> /nix/store/np3pb3a6wd1bf55hp0rl3i64mfzrcilm-x86_64-w64-mingw32-gcc-14.2.1.20250322/x86_64-w64-mingw32/sys-include/string.h:92:31: note: 'strp<br>brk' declared here<br>sword> 92 | _CONST_RETURN char *__cdecl strpbrk(const char *_Str,const char *_Control);<br>sword> osis2mod.cpp:434:40: error: 'strpbrk' is not a member of 'std'; did you mean 'strpbrk'?<br>sword> 434 | bufRead = std::strpbrk(tokenStart, " -");<br>sword> | ^~~~~~~<br>sword> /nix/store/np3pb3a6wd1bf55hp0rl3i64mfzrcilm-x86_64-w64-mingw32-gcc-14.2.1.20250322/x86_64-w64-mingw32/sys-include/string.h:92:31: note: 'strp<br>brk' declared here<br>sword> 92 | _CONST_RETURN char *__cdecl strpbrk(const char *_Str,const char *_Control);<br>sword> | ^~~~~~~<br><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, Jul 7, 2025 at 4:14 PM DM Smith <<a href="mailto:dmsmith@crosswire.org" target="_blank">dmsmith@crosswire.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div>I have just committed revision 3907 for osis2mod, adding location information to messages so that one can more readily tie reported events to the OSIS input file.<div><br></div><div>I have updated the osis2mod wiki entry to document it more fully: <a href="https://wiki.crosswire.org/Osis2mod#Messages" target="_blank">https://wiki.crosswire.org/Osis2mod#Messages</a><br><div><br><div>MODTOOLS-25 give location in input for messages.<br><br>Created identifyMsg which creates a standardized message for reporting<br>and used it for all messages to standard out.<br><br>The message is of the form:<br> type(kind)[linePos,charPos] osisID=osisID: message<br><br>Where:<br> type The message type (e.g., "ERROR", "WARNING", "INFO").<br> kind The message category or kind (e.g., "REF", "PARSE").<br> linePos The position in the file of the last line that was read.<br> charPos The position in the line of the last character that was read.<br> osisID (Optional) The current OSIS ID to include. May be nullptr or empty.<br> message event description with details<br><br>* If linePos is 0, the position ([linePos,charPos]) is omitted.<br>* If osisID is nullptr or empty, the osisID part is omitted.<br>* The returned string always ends with a colon and a trailing space (": “).</div><div><br></div><div>In Him,</div><div><span style="white-space:pre-wrap"> </span>DM<br><br></div></div></div></div>_______________________________________________<br>
sword-devel mailing list: <a href="mailto:sword-devel@crosswire.org" target="_blank">sword-devel@crosswire.org</a><br>
<a href="http://crosswire.org/mailman/listinfo/sword-devel" rel="noreferrer" target="_blank">http://crosswire.org/mailman/listinfo/sword-devel</a><br>
Instructions to unsubscribe/change your settings at above page<br>
</blockquote></div>
_______________________________________________<br>sword-devel mailing list: <a href="mailto:sword-devel@crosswire.org" target="_blank">sword-devel@crosswire.org</a><br><a href="http://crosswire.org/mailman/listinfo/sword-devel" target="_blank">http://crosswire.org/mailman/listinfo/sword-devel</a><br>Instructions to unsubscribe/change your settings at above page<br></div></blockquote></div><br></div></div></div></div></blockquote></div><br></div></div></div>_______________________________________________<br>
sword-devel mailing list: <a href="mailto:sword-devel@crosswire.org" target="_blank">sword-devel@crosswire.org</a><br>
<a href="http://crosswire.org/mailman/listinfo/sword-devel" rel="noreferrer" target="_blank">http://crosswire.org/mailman/listinfo/sword-devel</a><br>
Instructions to unsubscribe/change your settings at above page<br>
</blockquote></div>