• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: NDEBUG suddenly defined???
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NDEBUG suddenly defined???


  • Subject: Re: NDEBUG suddenly defined???
  • From: Fritz Anderson <email@hidden>
  • Date: Tue, 02 Jul 2013 16:47:53 -0500

On 2 Jul 2013, at 4:26 PM, Scott Ribe <email@hidden> wrote:

> That's right. I made no changes to build settings. Just added a couple of resource files that get copied at build time, and edited a couple of source files, and now my C-style asserts are not being executed because NDEBUG is defined.
>
> I've verified that it is actually defined. I've looked in my build settings and found nothing. I've verified that I'm building & executing for debug. I've restarted Xcode, rebooted...
>
> What next? (This is Xcode 4.6.3)

Three things, to be tried in any order you please:

Add a Run Script phase to your project. Put something benign like "echo Hello World!" into the script body, and check "Show environment variables in build log." Build. Switch to the log navigator. Select the latest build. Select the run-script step, and click the lines-of-code button that will appear on the right. The expanded view will contain a dump of your environment, which you can search (CFLAGS?) for -dNDEBUG.

Expand one of the compiler invocations in the log and see if the -d is there.

Do a global find for NDEBUG, setting the search to include frameworks. It's possible that you're including a header that defines it.

	— F


--
Fritz Anderson
Xcode 4 Unleashed: 4.5 supplement for free!
http://www.informit.com/store/xcode-4-unleashed-9780672333279


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden


  • Follow-Ups:
    • Re: NDEBUG suddenly defined???
      • From: Scott Ribe <email@hidden>
References: 
 >NDEBUG suddenly defined??? (From: Scott Ribe <email@hidden>)

  • Prev by Date: Re: App's r/w access to /Library/Preferences/OurAppPrefsFolder, using Xcode 3.2.6
  • Next by Date: Link fails for test but not app build
  • Previous by thread: NDEBUG suddenly defined???
  • Next by thread: Re: NDEBUG suddenly defined???
  • Index(es):
    • Date
    • Thread