• 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: Can't see source code for errors and warnings with external build target
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Can't see source code for errors and warnings with external build target


  • Subject: Re: Can't see source code for errors and warnings with external build target
  • From: Jonas Maebe <email@hidden>
  • Date: Wed, 26 Mar 2008 19:35:00 +0100


On 26 Mar 2008, at 19:23, Jerry wrote:
We're using SCons to build a project, and have an external build target to build from within Xcode. This works fine except that when g ++ gives an error, clicking on the red error message in the Build Results window doesn't show the source code. The folder structure is like this:

	A/
		foo.xcodeproj
		B/
			C/
				foo.cpp

The project root is "A". When an error occurs in foo.cpp, the error message starts: "B/C/foo.cpp:xx: blah blah", i.e. the path is relative to /A, which is th project location and root. I've used fs_usage to try and see what Xcode is looking for and the only thing it does an lstat on is /A/B/C/foo.cpp, which is the correct path, so why doesn't it display the source code?

Note that /A/B/C/foo.cpp is relative to the root dir of the hard disk. I have in the past added an option to our compiler to always output the full path when reporting an error in order to solve exactly this problem. When Xcode calls gcc, it also passes the full, absolute path to all source files so that gcc repeats it as well in its error messages.


You may have to modify SCons (or the way you invoke it) in a similar way.


Jonas _______________________________________________ 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: Can't see source code for errors and warnings with external build target
      • From: Jerry <email@hidden>
References: 
 >Can't see source code for errors and warnings with external build target (From: Jerry <email@hidden>)

  • Prev by Date: Re: is this a bug in my code or Xcode?
  • Next by Date: Re: Xcode 2.4.1 and Subversion
  • Previous by thread: Can't see source code for errors and warnings with external build target
  • Next by thread: Re: Can't see source code for errors and warnings with external build target
  • Index(es):
    • Date
    • Thread