<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><br class=""><div><br class=""><blockquote type="cite" class=""><div class="">On 23 Nov 2019, at 1:56 pm, Steven Smith <<a href="mailto:steve.t.smith@gmail.com" class="">steve.t.smith@gmail.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><meta http-equiv="Content-Type" content="text/html; charset=utf-8" class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div class="">Per <a href="https://guide.macports.org/#reference.phases.installation.list-modifiers" class="">https://guide.macports.org/#reference.phases.installation.list-modifiers</a>, I’ll try starting with a blanket -delete of everything, try to get to the basic working make, and divide-and-conquer to isolate the issue. Maybe this?</div><div class=""><br class=""></div><div class=""><blockquote type="cite" class=""><div class="">configure.cflags-delete</div><div class="">configure.ldflags-delete</div><div class="">…</div></blockquote></div><div class=""><div class=""><br class=""></div><div class="">Is there an equivalent build.cflags, build.ldflags, etc.?</div><div class=""><br class=""></div><div class="">There is not configure step necessary for this repo. Are these MacPorts configure flags used in the build stage?</div></div></div></div></blockquote><div><br class=""></div><div>you can get a detailed summary of what is set for each phase, by running with</div><div><br class=""></div><div>> port -d …..</div><div><br class=""></div><div>Chris</div><br class=""><blockquote type="cite" class=""><div class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div class=""><div class=""><br class=""></div><div class="">Here’s the current not-working Portfile:<div class=""><br class=""></div><div class=""><a href="https://github.com/macports/macports-ports/blob/4a9cd2d6b34e6d48e22bfb608529e900f49f8dcb/devel/jsonnet/Portfile" class="">https://github.com/macports/macports-ports/blob/4a9cd2d6b34e6d48e22bfb608529e900f49f8dcb/devel/jsonnet/Portfile</a></div><div class=""><br class=""></div></div><div class=""><br class=""><blockquote type="cite" class=""><div class="">On Nov 23, 2019, at 8:25 AM, Chris Jones <<a href="mailto:jonesc@hep.phy.cam.ac.uk" class="">jonesc@hep.phy.cam.ac.uk</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><meta http-equiv="content-type" content="text/html; charset=utf-8" class=""><div dir="auto" class=""><div dir="ltr" class=""><br class=""></div><div dir="ltr" class=""><br class=""><blockquote type="cite" class="">On 23 Nov 2019, at 12:57 pm, Steven Smith <<a href="mailto:steve.t.smith@gmail.com" class="">steve.t.smith@gmail.com</a>> wrote:<br class=""><br class=""></blockquote></div><blockquote type="cite" class=""><div dir="ltr" class=""><meta http-equiv="content-type" content="text/html; charset=utf-8" class=""><blockquote type="cite" class="">You need to try and isolate the one causing the issue, if you believe it is something MacPorts is appending to the env, and then address that specifically.</blockquote><div dir="ltr" class=""><span class=""><br class=""></span></div><div dir="ltr" class=""><span class="">That’s what I’m asking for help to do.</span></div><div dir="ltr" class=""><br class=""></div><div dir="ltr" class="">How are these flags and environment variables set within a Portfile?<br class=""><span class=""></span><br class=""><span class="">I don’t know enough about the MacPorts build design or clang options enough to go through all the combinatoric flag settings, or to divide-and-conquer the problem.</span><br class=""><span class=""></span><br class=""><div class="" style="-webkit-text-size-adjust: auto;">Here are the flags set by Google’s upstream repo, <<a href="https://github.com/google/jsonnet/blob/master/Makefile" class="">https://github.com/google/jsonnet/blob/master/Makefile</a>>:</div><div class="" style="-webkit-text-size-adjust: auto;"><blockquote type="cite" class=""><div class="x-apple-transform-wrapper" style="height: 67.85603895887304px;"><table class="js-file-line-container highlight tab-size" data-tab-size="8" style="box-sizing: border-box; border-spacing: 0px; border-collapse: collapse; tab-size: 8; caret-color: rgb(36, 41, 46); color: rgb(36, 41, 46); font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji"; font-size: 14px; transform-origin: 0px 0px; transform: scale(0.4241002434929565); width: 1399.328125px !important; height: 160px !important;"><tbody class="" style="box-sizing: border-box;"><tr class="" style="box-sizing: border-box;"></tr><tr class="" style="box-sizing: border-box;"><td id="LC32" class="js-file-line blob-code-inner blob-code" style="box-sizing: border-box; padding: 0px 10px; position: relative; line-height: 20px; vertical-align: top; overflow: visible; font-family: SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace; font-size: 12px; word-wrap: normal; white-space: pre;"></td></tr><tr class="" style="box-sizing: border-box;"><td id="L34" class="blob-num js-line-number" data-line-number="34" style="box-sizing: border-box; padding: 0px 10px; width: 50px; min-width: 50px; font-family: SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace; font-size: 12px; line-height: 20px; color: rgba(27, 31, 35, 0.298039); text-align: right; white-space: nowrap; vertical-align: top; cursor: pointer; -webkit-user-select: none;"></td><td id="LC34" class="js-file-line blob-code-inner blob-code" style="box-sizing: border-box; padding: 0px 10px; position: relative; line-height: 20px; vertical-align: top; overflow: visible; font-family: SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace; font-size: 12px; word-wrap: normal; white-space: pre;"><span class="pl-smi" style="box-sizing: border-box;">CXXFLAGS</span> ?= -g <span class="pl-s" style="box-sizing: border-box; color: rgb(3, 47, 98);">$(<span class="pl-smi" style="box-sizing: border-box; color: rgb(36, 41, 46);">OPT</span>)</span> -Wall -Wextra -Woverloaded-virtual -pedantic -std=c++0x -fPIC</td></tr><tr class="" style="box-sizing: border-box;"><td id="L35" class="blob-num js-line-number" data-line-number="35" style="box-sizing: border-box; padding: 0px 10px; width: 50px; min-width: 50px; font-family: SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace; font-size: 12px; line-height: 20px; color: rgba(27, 31, 35, 0.298039); text-align: right; white-space: nowrap; vertical-align: top; cursor: pointer; -webkit-user-select: none;"></td><td id="LC35" class="js-file-line blob-code-inner blob-code" style="box-sizing: border-box; padding: 0px 10px; position: relative; line-height: 20px; vertical-align: top; overflow: visible; font-family: SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace; font-size: 12px; word-wrap: normal; white-space: pre;"><span class="pl-smi" style="box-sizing: border-box;">CXXFLAGS</span> += -Iinclude -Ithird_party/md5 -Ithird_party/json</td></tr><tr class="" style="box-sizing: border-box;"><td id="L36" class="blob-num js-line-number" data-line-number="36" style="box-sizing: border-box; padding: 0px 10px; width: 50px; min-width: 50px; font-family: SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace; font-size: 12px; line-height: 20px; color: rgba(27, 31, 35, 0.298039); text-align: right; white-space: nowrap; vertical-align: top; cursor: pointer; -webkit-user-select: none;"></td><td id="LC36" class="js-file-line blob-code-inner blob-code" style="box-sizing: border-box; padding: 0px 10px; position: relative; line-height: 20px; vertical-align: top; overflow: visible; font-family: SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace; font-size: 12px; word-wrap: normal; white-space: pre;"><span class="pl-smi" style="box-sizing: border-box;">CFLAGS</span> ?= -g <span class="pl-s" style="box-sizing: border-box; color: rgb(3, 47, 98);">$(<span class="pl-smi" style="box-sizing: border-box; color: rgb(36, 41, 46);">OPT</span>)</span> -Wall -Wextra -pedantic -std=c99 -fPIC</td></tr><tr class="" style="box-sizing: border-box;"><td id="L37" class="blob-num js-line-number" data-line-number="37" style="box-sizing: border-box; padding: 0px 10px; width: 50px; min-width: 50px; font-family: SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace; font-size: 12px; line-height: 20px; color: rgba(27, 31, 35, 0.298039); text-align: right; white-space: nowrap; vertical-align: top; cursor: pointer; -webkit-user-select: none;"></td><td id="LC37" class="js-file-line blob-code-inner blob-code" style="box-sizing: border-box; padding: 0px 10px; position: relative; line-height: 20px; vertical-align: top; overflow: visible; font-family: SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace; font-size: 12px; word-wrap: normal; white-space: pre;"><span class="pl-smi" style="box-sizing: border-box;">CFLAGS</span> += -Iinclude</td></tr><tr class="" style="box-sizing: border-box;"><td id="L38" class="blob-num js-line-number" data-line-number="38" style="box-sizing: border-box; padding: 0px 10px; width: 50px; min-width: 50px; font-family: SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace; font-size: 12px; line-height: 20px; color: rgba(27, 31, 35, 0.298039); text-align: right; white-space: nowrap; vertical-align: top; cursor: pointer; -webkit-user-select: none;"></td><td id="LC38" class="js-file-line blob-code-inner blob-code" style="box-sizing: border-box; padding: 0px 10px; position: relative; line-height: 20px; vertical-align: top; overflow: visible; font-family: SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace; font-size: 12px; word-wrap: normal; white-space: pre;"><span class="pl-smi" style="box-sizing: border-box;">MAKEDEPENDFLAGS</span> += -Iinclude -Ithird_party/md5 -Ithird_party/json</td></tr><tr class="" style="box-sizing: border-box;"><td id="L39" class="blob-num js-line-number" data-line-number="39" style="box-sizing: border-box; padding: 0px 10px; width: 50px; min-width: 50px; font-family: SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace; font-size: 12px; line-height: 20px; color: rgba(27, 31, 35, 0.298039); text-align: right; white-space: nowrap; vertical-align: top; cursor: pointer; -webkit-user-select: none;"></td><td id="LC39" class="js-file-line blob-code-inner blob-code" style="box-sizing: border-box; padding: 0px 10px; position: relative; line-height: 20px; vertical-align: top; overflow: visible; font-family: SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace; font-size: 12px; word-wrap: normal; white-space: pre;"><span class="pl-smi" style="box-sizing: border-box;">EMCXXFLAGS</span> = <span class="pl-s" style="box-sizing: border-box; color: rgb(3, 47, 98);">$(<span class="pl-smi" style="box-sizing: border-box; color: rgb(36, 41, 46);">CXXFLAGS</span>)</span> -g0 -Os --memory-init-file 0 -s DISABLE_EXCEPTION_CATCHING=0 -s OUTLINING_LIMIT=10000 -s RESERVED_FUNCTION_POINTERS=20 -s ASSERTIONS=1 -s ALLOW_MEMORY_GROWTH=1</td></tr><tr class="" style="box-sizing: border-box;"><td id="L40" class="blob-num js-line-number" data-line-number="40" style="box-sizing: border-box; padding: 0px 10px; width: 50px; min-width: 50px; font-family: SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace; font-size: 12px; line-height: 20px; color: rgba(27, 31, 35, 0.298039); text-align: right; white-space: nowrap; vertical-align: top; cursor: pointer; -webkit-user-select: none;"></td><td id="LC40" class="js-file-line blob-code-inner blob-code" style="box-sizing: border-box; padding: 0px 10px; position: relative; line-height: 20px; vertical-align: top; overflow: visible; font-family: SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace; font-size: 12px; word-wrap: normal; white-space: pre;"><span class="pl-smi" style="box-sizing: border-box;">EMCFLAGS</span> = <span class="pl-s" style="box-sizing: border-box; color: rgb(3, 47, 98);">$(<span class="pl-smi" style="box-sizing: border-box; color: rgb(36, 41, 46);">CFLAGS</span>)</span> --memory-init-file 0 -s DISABLE_EXCEPTION_CATCHING=0 -s ASSERTIONS=1 -s ALLOW_MEMORY_GROWTH=1</td></tr><tr class="" style="box-sizing: border-box;"><td id="L41" class="blob-num js-line-number" data-line-number="41" style="box-sizing: border-box; padding: 0px 10px; width: 50px; min-width: 50px; font-family: SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace; font-size: 12px; line-height: 20px; color: rgba(27, 31, 35, 0.298039); text-align: right; white-space: nowrap; vertical-align: top; cursor: pointer; -webkit-user-select: none;"></td><td id="LC41" class="js-file-line blob-code-inner blob-code" style="box-sizing: border-box; padding: 0px 10px; position: relative; line-height: 20px; vertical-align: top; overflow: visible; font-family: SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace; font-size: 12px; word-wrap: normal; white-space: pre;"><span class="pl-smi" style="box-sizing: border-box;">LDFLAGS</span> ?=</td></tr></tbody></table></div></blockquote></div><span class=""></span><div dir="ltr" class=""><br class=""></div><div dir="ltr" class="">How are these variables and flags unset/reset within a Portfile?</div></div></div></blockquote><div class=""><br class=""></div>See <div class=""><br class=""></div><div class=""><a href="https://guide.macports.org/" class="">https://guide.macports.org/</a></div><div class=""><br class=""></div><div class="">There is a section in there explaining how CFLAGS etc. are set.<br class=""><blockquote type="cite" class=""><div dir="ltr" class=""><div dir="ltr" class=""><br class=""></div></div></blockquote></div></div></div></blockquote></div><br class=""></div></div></div></blockquote></div><br class=""></body></html>