<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="">hi lads/ladettes,<div class=""><br class=""></div><div class="">as an update, i was independently provided a solution by by jonathan alland aka mr wowfunhappy and a man mononymously known as ‘krackers, and mr phil dennis jordan (whom i call God because of his macintosh knowledge).</div><div class=""><br class=""></div><div class="">both suggested the linker was the problem, and indeed it was. changing -fuse-ld=lld to -fuse-ld=ld64 fixed the issue.</div><div class=""><br class=""></div><div class="">thank you everyone!</div><div class=""><br class=""><div class=""><div class=""><div class="">
<div dir="auto" style="caret-color: rgb(0, 0, 0); color: rgb(0, 0, 0); letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div dir="auto" style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div style="caret-color: rgb(0, 0, 0); color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;">Thanks,</div><div style="caret-color: rgb(0, 0, 0); color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;">Gagan</div></div></div>
</div>
<div><br class=""><blockquote type="cite" class=""><div class="">On Jun 10, 2024, at 10:21 AM, Ken Cunningham <<a href="mailto:ken.cunningham.webuse@gmail.com" class="">ken.cunningham.webuse@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="overflow-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class="">Well -- I can take your word for it, and be of no help ...  or you can show us the exact link line, with -Wl,-lobjc added to it, and the failure.<div class=""><br class=""></div><div class=""><br class=""><div class=""><br class=""></div><div class="">Ken</div><div class=""><br class=""></div><div class=""><div class=""><br class=""><blockquote type="cite" class=""><div class="">On Jun 10, 2024, at 9:19 AM, Gagan Sidhu <<a href="mailto:broly@mac.com" class="">broly@mac.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="">the output is no different with the -lobjc, which is why i said with or without lobjc<div class=""><br class=""></div><div class="">it’s the exact same as below.</div><div class=""><br class=""><div class="">
<div dir="auto" style="caret-color: rgb(0, 0, 0); letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; overflow-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div dir="auto" style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class="">Thanks,</div><div style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class="">Gagan</div></div></div>
</div>
<div class=""><br class=""><blockquote type="cite" class=""><div class="">On Jun 10, 2024, at 10:17 AM, Ken Cunningham <<a href="mailto:ken.cunningham.webuse@gmail.com" class="">ken.cunningham.webuse@gmail.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div class="">Yes but I still don't see -lobjc on your link line...<br class=""><br class="">K<br class=""><br class=""><br class=""><br class=""><blockquote type="cite" class="">On Jun 10, 2024, at 9:15 AM, Gagan Sidhu via macports-dev <<a href="mailto:macports-dev@lists.macports.org" class="">macports-dev@lists.macports.org</a>> wrote:<br class=""><br class="">oh does the list parse out indented comments? if so my apologies!<br class=""><br class="">the original error is this:<br class=""><br class="">GagansMacPro:updater Gagan$ /opt/local/bin/ccache /opt/local/bin/clang++ -isysroot /Users/Gagan/.mozbuild/MacOSX14.4.sdk -objc -mmacosx-version-min=10.7 -stdlib=libc++ -o ../../../../dist/bin/org.mozilla.updater -fstack-protector-strong -fno-sized-deallocation -fno-aligned-new -fno-exceptions -fPIC -fno-rtti -ffunction-sections -fdata-sections -fno-exceptions -fno-math-errno -pthread -gdwarf-4 -fno-omit-frame-pointer -funwind-tables -Wl,@/Users/Gagan/Downloads/mozilla-unified/obj-x86_64-apple-darwin18.7.0/toolkit/mozapps/update/updater/org_mozilla_updater.list    -fuse-ld=lld -fstack-protector-strong -Wl,-rpath,@executable_path/../Frameworks/UpdateSettings.framework -sectcreate __TEXT __info_plist /Users/Gagan/Downloads/mozilla-unified/obj-x86_64-apple-darwin18.7.0/dist/bin/Info.plist -sectcreate __TEXT __launchd_plist /Users/Gagan/Downloads/mozilla-unified/toolkit/mozapps/update/updater/Launchd.plist  ../../../../build/pure_virtual/libpure_virtual.a -Wl,-rpath,@executable_path ../../../../dist/bin/UpdateSettings -framework Security -framework Cocoa -framework SystemConfiguration<br class="">ld64.lld: error: undefined symbol: OBJC_CLASS_$_NSObject<br class=""><blockquote type="cite" class=""><blockquote type="cite" class=""><blockquote type="cite" class="">referenced by /Users/Gagan/Downloads/mozilla-unified/toolkit/mozapps/update/updater/launchchild_osx.mm<br class="">             launchchild_osx.o:(symbol OBJC_CLASS_$_ElevatedUpdateServer+0x8)<br class="">referenced by /Users/Gagan/Downloads/mozilla-unified/toolkit/mozapps/update/updater/progressui_osx.mm<br class="">             progressui_osx.o:(symbol OBJC_CLASS_$_UpdaterUI+0x8)<br class=""></blockquote></blockquote></blockquote><br class="">ld64.lld: error: undefined symbol: OBJC_METACLASS_$_NSObject<br class=""><blockquote type="cite" class=""><blockquote type="cite" class=""><blockquote type="cite" class="">referenced by /Users/Gagan/Downloads/mozilla-unified/toolkit/mozapps/update/updater/launchchild_osx.mm<br class="">             launchchild_osx.o:(symbol OBJC_METACLASS_$_ElevatedUpdateServer+0x8)<br class="">referenced by /Users/Gagan/Downloads/mozilla-unified/toolkit/mozapps/update/updater/launchchild_osx.mm<br class="">             launchchild_osx.o:(symbol OBJC_METACLASS_$_ElevatedUpdateServer+0x0)<br class="">referenced by /Users/Gagan/Downloads/mozilla-unified/toolkit/mozapps/update/updater/progressui_osx.mm<br class="">             progressui_osx.o:(symbol OBJC_METACLASS_$_UpdaterUI+0x8)<br class="">referenced 1 more times<br class=""></blockquote></blockquote></blockquote><br class=""><br class="">with or without -lobjc<br class=""><br class="">Thanks,<br class="">Gagan<br class=""><br class=""><blockquote type="cite" class="">On Jun 10, 2024, at 10:14 AM, Ken Cunningham <<a href="mailto:ken.cunningham.webuse@gmail.com" class="">ken.cunningham.webuse@gmail.com</a>> wrote:<br class=""><br class="">I can't see lobjc on the link line.<br class=""><br class="">Could you show us a failed link with it there?<br class=""><br class="">Thx<br class=""><br class=""><br class=""><br class=""><blockquote type="cite" class="">On Jun 10, 2024, at 8:51 AM, Gagan Sidhu via macports-dev <<a href="mailto:macports-dev@lists.macports.org" class="">macports-dev@lists.macports.org</a>> wrote:<br class=""><br class=""><br class=""><blockquote type="cite" class="">GagansMacPro:updater Gagan$ /opt/local/bin/ccache /opt/local/bin/clang++ -isysroot /Users/Gagan/.mozbuild/MacOSX14.4.sdk -mmacosx-version-min=10.7 -stdlib=libc++ -o ../../../../dist/bin/org.mozilla.updater -fstack-protector-strong -fno-sized-deallocation -fno-aligned-new -fno-exceptions -fPIC -fno-rtti -ffunction-sections -fdata-sections -fno-exceptions -fno-math-errno -pthread -gdwarf-4 -fno-omit-frame-pointer -funwind-tables -Wl,@/Users/Gagan/Downloads/mozilla-unified/obj-x86_64-apple-darwin18.7.0/toolkit/mozapps/update/updater/org_mozilla_updater.list    -fuse-ld=lld -fstack-protector-strong -Wl,-rpath,@executable_path/../Frameworks/UpdateSettings.framework -sectcreate __TEXT __info_plist /Users/Gagan/Downloads/mozilla-unified/obj-x86_64-apple-darwin18.7.0/dist/bin/Info.plist -sectcreate __TEXT __launchd_plist /Users/Gagan/Downloads/mozilla-unified/toolkit/mozapps/update/updater/Launchd.plist  ../../../../build/pure_virtual/libpure_virtual.a -Wl,-rpath,@executable_path ../../../../dist/bin/UpdateSettings -framework Security -framework Cocoa -framework SystemConfiguration<br class=""></blockquote><br class="">with or without -lobjc still produces the same undefined symbol error.<br class=""><br class="">sorry for the duplicate message ken. forgot to send it ot the mailer.<br class=""><br class=""><blockquote type="cite" class=""><br class=""><blockquote type="cite" class="">On Jun 10, 2024, at 9:45 AM, Ken Cunningham <<a href="mailto:ken.cunningham.webuse@gmail.com" class="">ken.cunningham.webuse@gmail.com</a>> wrote:<br class=""><br class="">It's easier to help if we can see the link line you're using, but in short you need to make sure that lobjc is in the link libs, sometimes by explicitly adding it:<br class=""><br class="">LDFLAGS="$LDFLAGS -framework Cocoa -lobjc"<br class=""><br class="">K<br class=""><br class=""><blockquote type="cite" class="">On Jun 10, 2024, at 8:08 AM, Gagan Sidhu via macports-dev <<a href="mailto:macports-dev@lists.macports.org" class="">macports-dev@lists.macports.org</a>> wrote:<br class=""><br class="">hi team,<br class=""><br class="">first of all, i just built the clang-18 properly and wow am i amazed. here i was asking about wasm and stuff, i should have been a little more thorough, my bad.<br class=""><span class="Apple-tab-span" style="white-space:pre">     </span>-really this thing is a work of art. great yob<br class=""><br class="">now to my question, which i also posted to stackexchange(<a href="https://stackoverflow.com/questions/78602533/using-nsobject-with-modern-os-x-sdk-14-4-and-10-7-macosx-deployment-target" class="">https://stackoverflow.com/questions/78602533/using-nsobject-with-modern-os-x-sdk-14-4-and-10-7-macosx-deployment-target</a>)<br class=""><br class="">briefly: the NSObject class moved from the runtime to Foundation from Lion to Mountain Lion.<br class=""><br class="">so there is a little bit of a “hole” in trying to compile for a 10.7 target using an SDK that is >=10.8:<br class=""><br class=""><blockquote type="cite" class="">ld64.lld: error: undefined symbol: OBJC_CLASS_$_NSObject<br class=""><blockquote type="cite" class=""><blockquote type="cite" class=""><blockquote type="cite" class="">referenced by /Users/Gagan/Downloads/mozilla-unified/toolkit/mozapps/update/updater/launchchild_osx.mm<br class="">           launchchild_osx.o:(symbol OBJC_CLASS_$_ElevatedUpdateServer+0x8)<br class="">referenced by /Users/Gagan/Downloads/mozilla-unified/toolkit/mozapps/update/updater/progressui_osx.mm<br class="">           progressui_osx.o:(symbol OBJC_CLASS_$_UpdaterUI+0x8)<br class=""></blockquote></blockquote></blockquote><br class="">ld64.lld: error: undefined symbol: OBJC_METACLASS_$_NSObject<br class=""><blockquote type="cite" class=""><blockquote type="cite" class=""><blockquote type="cite" class="">referenced by /Users/Gagan/Downloads/mozilla-unified/toolkit/mozapps/update/updater/launchchild_osx.mm<br class="">           launchchild_osx.o:(symbol OBJC_METACLASS_$_ElevatedUpdateServer+0x8)<br class="">referenced by /Users/Gagan/Downloads/mozilla-unified/toolkit/mozapps/update/updater/launchchild_osx.mm<br class="">           launchchild_osx.o:(symbol OBJC_METACLASS_$_ElevatedUpdateServer+0x0)<br class="">referenced by /Users/Gagan/Downloads/mozilla-unified/toolkit/mozapps/update/updater/progressui_osx.mm<br class="">           progressui_osx.o:(symbol OBJC_METACLASS_$_UpdaterUI+0x8)<br class="">referenced 1 more times<br class=""></blockquote></blockquote></blockquote>clang++: error: linker command failed with exit code 1 (use -v to see invocation)<br class=""></blockquote><br class=""><br class="">usually it will say something like this because, as is obvious to this educated and sharp crowd, the >=10.8 objc runtime will not have NSObject like 10.7, and thus there is no framework we can link for a 10.7 target to get NSObject.<br class=""><br class="">have any of you vets dealt this issew? is there a simple way? i haven’t thought too hard about trying to use an OSObject but i’m open to alternatives.<br class=""><br class="">maybe duplicating the class and renaming any usage with a macro? i was hoping for sokmething cleaner tho.<br class=""><br class="">Thanks,<br class="">Gagan<br class=""><br class=""></blockquote><br class=""></blockquote><br class=""></blockquote><br class=""></blockquote><br class=""></blockquote><br class=""></blockquote><br class=""></div></div></blockquote></div><br class=""></div></div></div></blockquote></div><br class=""></div></div></div></div></blockquote></div><br class=""></div></div></div></body></html>