Richard, Amazing. Thank you very much this is exactly what I needed. I confirmed I can run openapp SystemPreferences with --GNU-Debug=dlft and see all the NSDebugLog statements I was making now, and other existing I was expecting to see. I know I did a grep of the source tree several times but I am sure I overlooked somehow. Thanks also for the tips so I can look at building the Documentation locally.
About the wiki, and websites as mentioned previously I hope to look at contributing to those as well in the future. I just wanted to get through libs-back, and libs-dbuskit work I am doing for pull requests while I have a lot of momentum going with those. This unblocks me. Thank you again. Joseph Maloney Sent with [Proton Mail](https://proton.me/mail/home) secure email. On Saturday, March 15th, 2025 at 4:33 AM, richard <[email protected]> wrote: > NSDebugLog has a lot of documentation ... If you can't find it elsewhere (I > see that the link on GNUstep.org currently returns 404 for the base > additions), you can generate it locally using make in the base library > Documentation subdirectory). The doc is generated from > Headers/GNUstepBase/NSDebug+GNUstepBase.h > > To turn on default debug logging you use --GNU-Debug=dflt on the command line. > > Logging is usually to stderr (which typically is the console), and is > performed by NSLog. The documentation for that leads to lower level > functionality to customise the format of logs, control where they are sent to > etc. > > You cun supplement the documentation by looking at the source, but probably > if stderr is not where you want it, you should replace the > NSLog_printf_handler function. > >> On 15 Mar 2025 at 01:41, Joseph Maloney via Discussion list for the GNUstep >> programming environment <[email protected]> wrote: >> Hi, >> I wrote a simple Makefile system for quickly rebuilding the latest GNUstep >> so I could hack on libs-back, rebuild over and over. I have some fixes >> coming for the wayland but for a big one I am blocked in the middle of one >> because I realize there must be a simple way to get NSDebugLog statements to >> show on the console when opening an app but I simply cannot find one. >> >> Below is the relevant section of my Makefile I tried to make more >> presentable for this post that captures what I have tried. Am I missing >> something simple? Does NSdebugLog not print to console, only in a debugger? >> I've searched the git repos, the wiki, etc. I couldn't find any >> documentation around NSDebugLog and what I did find third party did not work. >> >> # Set working directory and CPU count >> WORKDIR=$(pwd) >> CPUS=$(nproc) >> >> # Set compiler flags for debugging >> export CFLAGS="-g -O0 -ggdb" >> export CXXFLAGS="-g -O0 -ggdb" >> export LDFLAGS="-g" >> export GNUSTEP_INSTALLATION_DOMAIN="SYSTEM" >> >> # Print configuration settings >> echo "CPUS is set to: $CPUS" >> echo "GNUSTEP_INSTALLATION_DOMAIN is set to: $GNUSTEP_INSTALLATION_DOMAIN" >> echo "WORKDIR is set to: $WORKDIR" >> echo "CFLAGS is set to: $CFLAGS" >> >> # Build and install GNUstep Make >> echo "Building GNUstep Make..." >> cd "$WORKDIR/tools-make" && ./configure \ >> --with-layout=gnustep \ >> --with-library-combo=ng-gnu-gnu \ >> --enable-debug-by-default || exit 1 >> >> gmake -j"$CPUS" || exit 1 >> gmake install || exit 1 >> >> # Source GNUstep environment >> . /usr/GNUstep/System/Library/Makefiles/GNUstep.sh >> >> # Build and install libobjc2 >> echo "Building libobjc2..." >> mkdir -p "$WORKDIR/libobjc2/Build" >> cd "$WORKDIR/libobjc2/Build" || exit 1 >> cmake .. \ >> -DGNUSTEP_INSTALL_TYPE=SYSTEM \ >> -DCMAKE_BUILD_TYPE=Debug \ >> -DCMAKE_C_COMPILER=clang \ >> -DCMAKE_CXX_COMPILER=clang++ \ >> -DCMAKE_C_FLAGS="-g -O0 -ggdb" \ >> -DCMAKE_CXX_FLAGS="-g -O0 -ggdb" || exit 1 >> >> gmake -j"$CPUS" || exit 1 >> gmake install || exit 1 >> >> # Build and install GNUstep Base >> echo "Building GNUstep Base..." >> cd "$WORKDIR/libs-base" || exit 1 >> ./configure \ >> --with-installation-domain=SYSTEM \ >> CFLAGS="-g -O0 -ggdb" CXXFLAGS="-g -O0 -ggdb" LDFLAGS="-g" || exit 1 >> >> gmake -j"$CPUS" || exit 1 >> gmake install || exit 1 >> gmake clean >> >> # Build and install GNUstep GUI >> echo "Building GNUstep GUI..." >> cd "$WORKDIR/libs-gui" || exit 1 >> ./configure \ >> CFLAGS="-g -O0 -ggdb" CXXFLAGS="-g -O0 -ggdb" LDFLAGS="-g" || exit 1 >> >> gmake -j"$CPUS" || exit 1 >> gmake install || exit 1 >> gmake clean >> >> # Build and install GNUstep Back >> echo "Building GNUstep Back..." >> cd "$WORKDIR/libs-back" || exit 1 >> export fonts=no >> ./configure \ >> --enable-debug-by-default \ >> --enable-server=wayland \ >> CFLAGS="-g -O0 -ggdb" CXXFLAGS="-g -O0 -ggdb" LDFLAGS="-g" || exit 1 >> >> gmake -j"$CPUS" debug=yes || exit 1 >> gmake install debug=yes || exit 1gmake clean >> >> Joseph Maloney >> >> Sent with [Proton Mail](https://proton.me/mail/home) secure email.
