Re: Removing source code paths from executable
Re: Removing source code paths from executable
- Subject: Re: Removing source code paths from executable
- From: Massimiliano Origgi <email@hidden>
- Date: Fri, 3 Feb 2006 11:40:03 +0100
Il giorno 03/feb/06, alle ore 10:08, Dave Rehring ha scritto:
Mmmh, I didn't receive the previous message, strange...
On 1/31/06 6:02 AM, Damien Bobillot at
email@hidden wrote:
Massimiliano Origgi wrote :
Hello,
I have recently switched to GCC 4 (under XCode 2.2) and checking
the optimized executable file I have found that the full source
path of all objective-c source files is included in the executable
(there are a few c files and they do not appear).
You may use the strip command (there's a setting in xcode for this),
which suppress all symbols but Objective-C class descriptions (name,
members, methods, inheritance…). These class descriptions must be
there, because they are used by the Objective-C runtime : there's no
way to prevent a potential hacker from seeing them (see the class-
dump tool). Knowing that, I don't think is really useful to hide
Objective-C file names.
Generally it's true, but the file path may reveal some unwanted
details (that's the reason I noticed this).
Certainly I could modify the path and file names, but I still don't
see why the full paths should be in the optimized, stripped
executable (and with long paths and lots of files, they even use a
sizeable amount of space).
This did not happen with GCC 3.3.
Are you sure ? try to run "otool -ov your_executable", I'm almost
sure you will see some .m filenames.
I believe this is true. GCC 3.3 didn't include the complete source
path,
and I think it doesn't include even the file name. GCC 4.0 started
putting
the complete file path into the executable. We did file a bug
about it, but
got back 'works as designed' [or something similar].
With 3.3 I have seen paths included in presence of inline functions
(and obviously when there is some assert statement).
Offhand, I can't imagine why the final, built and linked executable
needs to
know what source file an Objective-C class came from [class name
yes, file
name, no]...
Me too, maybe new exception handling code wants file paths too (see
above), but it looks weird anyway.
Massimiliano Origgi
http://www.intuiware.com
_______________________________________________
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