PDA

View Full Version : Expert NEEDED on Xcode ......... ASAP.




NSG10
Aug 29, 2010, 05:52 PM
Hey guys, every time I try to create a new project in Xcode i get this error

File: /SourceCache/DevToolsBase/DevToolsBase-1608/pbxcore/SourceControlManagement/SCMG3/SCMModel.m
Line: 87
Object: <SCMModel>
Method: initialize

couldn't create ~/.Xcode

What does it exactly mean and how is the fix for it?



balamw
Aug 29, 2010, 05:56 PM
Does the file/folder ~/.Xcode already exist? If so, what are the file permissions on it? if not, what are the folder permissions on ~ (your home folder).

B

NSG10
Aug 29, 2010, 06:55 PM
Does the file/folder ~/.Xcode already exist? If so, what are the file permissions on it? if not, what are the folder permissions on ~ (your home folder).

B

I don't think it exists because I tried to find the directory and searched for it in spotlight and it's not there. I did repair permissions on Disk Utilities and still nothing. But my question is, how do I find permissions for that specific file or ( ~) as you mentioned, so that I find out.

Thanks:).

GorillaPaws
Aug 29, 2010, 07:15 PM
I don't think it exists because I tried to find the directory and searched for it in spotlight and it's not there. I did repair permissions on Disk Utilities and still nothing. But my question is, how do I find permissions for that specific file or ( ~) as you mentioned, so that I find out.

Thanks:).

The '~' is a Unix convention meaning your home directory. There are a few ways to check permissions on a file, using "get info" is probably the easiest. Google is your friend.

Also it's considered rude to put "urgent", "ASAP", etc. and to use all caps in the title of a thread. The thinking goes that if the problem is so urgent, you should be willing to hire a programmer instead of asking people to volunteer their time to help you for free. I'm not saying this to be a jerk, but to give you a heads up that some people may take offense.

You might want to take a look at this article called Getting Answers (http://mikeash.com/getting_answers.html) that covers the basics of etiquette on programming forums. From my experience, the members here on macrumors tend to really go out of their way to be helpful. You'll likely find people have less patients elsewhere.

balamw
Aug 30, 2010, 08:00 AM
The '~' is a Unix convention meaning your home directory. There are a few ways to check permissions on a file, using "get info" is probably the easiest. Google is your friend.

Easier is in the eye of the beholder. ;)

I would recommend that NSG10 learn to use the command line via Terminal.app. This might also help NSG10 with their Objective C issues. Don't try to learn the IDE and the language at the same time. Try to understand the language and programming first via command line tools and then try to use the IDE to make complicated things easier.

IMHO IDEs are overkill if you are still at the "Hello World" stage.

From the command line.

ls -al ~/.Xcode
ls -ald ~

works extremely well.

B

GorillaPaws
Aug 30, 2010, 09:12 AM
Easier is in the eye of the beholder. ;)

I would recommend that NSG10 learn to use the command line via Terminal.app. This might also help NSG10 with their Objective C issues. Don't try to learn the IDE and the language at the same time. Try to understand the language and programming first via command line tools and then try to use the IDE to make complicated things easier.

IMHO IDEs are overkill if you are still at the "Hello World" stage.

That's a fair point. One major advantage of using Xcode when you're learning is that it does code-completion for you so it cuts down on spelling errors which allows you to focus on all of the other gazillion errors you probably have.

I do get your point about using the command line though. Although learning that was harder for me than learning the very basics of Xcode (and I'm still pretty clumsy in terminal).

NSG10
Aug 30, 2010, 12:19 PM
I really tried everything and nothing will give, this is very annoying. I tried reinstalling different versions of Xcode and tried to create that file through terminal with different commands including the one that was referred to here and it's not working it just keeps telling me that the file doesn't exist. Sigh.

mrbash
Aug 30, 2010, 01:13 PM
Do you know what the dot (".") in front of the name implies?

Are you familiar with the command "ls", and it's optional parameters?

I'm asking because you should be familiar with the above two items.

chown33
Aug 30, 2010, 01:17 PM
Create a new admin account.
Log out of current account.
Log into new account.

Launch Xcode.
Create new project (or whatever steps caused the problem).

Does the problem still happen?

If so, then open the application: /Applications/Utilities/Console.app

Then copy and post any error messages from Xcode that appear in the console log window.

balamw
Aug 30, 2010, 02:06 PM
chown33's advice is sound, as it basically creates a new place called "~" for the new user account.

I really tried everything and nothing will give, this is very annoying. I tried reinstalling different versions of Xcode and tried to create that file through terminal with different commands including the one that was referred to here and it's not working it just keeps telling me that the file doesn't exist. Sigh.

as mrbash implies, it does not seem like you understand what was posted or how to troubleshoot.

I posted two commands. Nether of which were intended to create anything, they were intended to display the permissions on ~ and ~/.Xcode.

~/.Xcode can certainly not exist, but I would certainly hope that ~ does. You don't seem to be separating those things in your mind.

Troubleshooting is all about separating the problem into simpler parts. The error message implies it can't create a file. This could be because it exists and can't be overwritten or you don't have permissions to create a new file in that folder.
1) Does the file ~/.Xcode exist, and what are the permissions on it?
2) Do the permissions on ~ prohibit me from creating ~/.Xcode?

B

NSG10
Aug 30, 2010, 03:25 PM
~............... is a directory

~/.xcode..........No such file or directory.

What does that mean?

NSG10
Aug 30, 2010, 03:36 PM
Here's what the console says:

Aug 30 23:34:41 macintosh Xcode[3281]: [MT] File: /SourceCache/DevToolsBase/DevToolsBase-1691/pbxcore/SourceControlManagement/SCMG3/SCMModel.m\nLine: 87\nObject: <SCMModel>\nMethod: initialize\n\ncouldn't create ~/.Xcode\nBacktrace:\n 0 0x00000001009a0fd9 -[PBXAssertionHandler handleFailureInMethod:object:fileName:lineNumber:messageFormat:arguments:] (in DevToolsInterface)\n 1 0x00000001002dab3f _XCAssertionFailureHandler (in DevToolsCore)\n 2 0x0000000100147e5b +[SCMModel initialize] (in DevToolsCore)\n 3 0x00007fff81cfa535 _class_initialize (in libobjc.A.dylib)\n 4 0x00007fff81cfa3f2 _class_initialize (in libobjc.A.dylib)\n 5 0x00007fff81d0863e prepareForMethodLookup (in libobjc.A.dylib)\n 6 0x00007fff81d00eaa lookUpMethod (in libobjc.A.dylib)\n 7 0x00007fff81cf91ba objc_msgSend (in libobjc.A.dylib)\n 8 0x0000000100147aad -[XCSourceControlManager scmSandbox] (in DevToolsCore)\n 9 0x000000010015559d -[XCSourceControlManager sandboxEntryForFileReference:] (in DevToolsCore)\n 10 0x0000000100155576 -[PBXFileReference sandboxEntry] (in DevToolsCore)\n 11 0x0000000100155440 -[PBXFileReference scmInfo] (in DevToolsCore)\n 12 0x000000010084501c -[PBXFileTableDataSource tableView:willDisplayCell:forTableColumn:row:] (in DevToolsInterface)\n 13 0x00007fff85783167 -[NSTableView preparedCellAtColumn:row:] (in AppKit)\n 14 0x00007fff8579bd1f -[NSTableView _drawContentsAtRow:column:withCellFrame:] (in AppKit)\n 15 0x00007fff8579adb8 -[NSTableView drawRow:clipRect:] (in AppKit)\n 16 0x000000010084471d -[PBXExtendedTableView drawRow:clipRect:] (in DevToolsInterface)\n 17 0x00007fff8579a6ab -[NSTableView drawRowIndexes:clipRect:] (in AppKit)\n 18 0x00007fff85799058 -[NSTableView drawRect:] (in AppKit)\n 19 0x00007fff8578f081 -[NSView _drawRect:clip:] (in AppKit)\n 20 0x00007fff8578dcf4 -[NSView _recursiveDisplayAllDirtyWithLockFocus:visRect:] (in AppKit)\n 21 0x00007fff8578e05e -[NSView _recursiveDisplayAllDirtyWithLockFocus:visRect:] (in AppKit)\n 22 0x00007fff8578e05e -[NSView _recursiveDisplayAllDirtyWithLockFocus:visRect:] (in AppKit)\n 23 0x00007fff8578e05e -[NSView _recursiveDisplayAllDirtyWithLockFocus:visRect:] (in AppKit)\n 24 0x00007fff8578e05e -[NSView _recursiveDisplayAllDirtyWithLockFocus:visRect:] (in AppKit)\n 25 0x00007fff8578e05e -[NSView _recursiveDisplayAllDirtyWithLockFocus:visRect:] (in AppKit)\n 26 0x00007fff8578e05e -[NSView _recursiveDisplayAllDirtyWithLockFocus:visRect:] (in AppKit)\n 27 0x00007fff8578e05e -[NSView _recursiveDisplayAllDirtyWithLockFocus:visRect:] (in AppKit)\n 28 0x00007fff8578e05e -[NSView _recursiveDisplayAllDirtyWithLockFocus:visRect:] (in AppKit)\n 29 0x00007fff8578e05e -[NSView _recursiveDisplayAllDirtyWithLockFocus:visRect:] (in AppKit)\n 30 0x00007fff8578e05e -[NSView _recursiveDisplayAllDirtyWithLockFocus:visRect:] (in AppKit)\n 31 0x00007fff8578e05e -[NSView _recursiveDisplayAllDirtyWithLockFocus:visRect:] (in AppKit)\n 32 0x00007fff8578e05e -[NSView _recursiveDisplayAllDirtyWithLockFocus:visRect:] (in AppKit)\n 33 0x00007fff8578c3c6 -[NSView

NSG10
Aug 30, 2010, 03:52 PM
Create a new admin account.
Log out of current account.
Log into new account.

Launch Xcode.
Create new project (or whatever steps caused the problem).

Does the problem still happen?

If so, then open the application: /Applications/Utilities/Console.app

Then copy and post any error messages from Xcode that appear in the console log window.


I created a new administrator account and it actually worked with no errors, but the new account seems as if though I formatted the device and all of my documents and papers are gone in this new account and only present in the old account how do I make this account have everything so I can remove the old one?

mrbash
Aug 30, 2010, 04:44 PM
You can copy your user directory contents over. Your documents shouldn't be a problem but your settings and and other things (iTunes) will be a problem. I'm not sure if the User Migration Assistant will let you copy to/from the same drive.

If you have a lot of files/settings (Bookmarks, iTunes music, passwords) in your original account, you will be better of trying to repair the original user account.

balamw
Aug 30, 2010, 04:48 PM
~............... is a directory

~/.xcode..........No such file or directory.

What does that mean?

NOTE: Be careful with cases ~/.xcode is not necessarily the same things as ~/.Xcode. This is particularly true in code.

Output from ls -ald ~
should be something like drwxrwxrwx+ 55 username staff 1870 Aug 19 12:31 /Users/username
so you must be entering it wrong.

EDIT: You could try the old standby. Use Disk Utility to Repair Permissions. http://support.apple.com/kb/ht1452 This might fix any permissions issues with your original user.

B

chown33
Aug 30, 2010, 05:15 PM
I created a new administrator account and it actually worked with no errors, but the new account seems as if though I formatted the device and all of my documents and papers are gone in this new account and only present in the old account how do I make this account have everything so I can remove the old one?

Stop.

Transferring all your files to the new account is the LAST step, not the FIRST step. Transferring the files isn't even the PREFERRED step, it's the last resort if nothing else works.


First, identify exactly what version of Xcode and Mac OS X you're using.

Second, make a backup of everything in your current admin account to a safe place. An external disk or a shared file server is safe enough.

Third, copy and paste this command-line exactly as given into Terminal, then paste the output into a post.
ls -la /Users


If you're not logged into your original admin account, do that next. Then launch Terminal.app using that account, and again copy and paste this exact command-line into a Terminal window, then paste the output into a post:
id -p; ls -la ~

balamw
Aug 30, 2010, 07:45 PM
then paste the output into a post.
NSG10, when you do Please wrap it in CODE tags to avoid the output being formatted. See your post with the console output.

:o becomes :o when not wrapped in CODE tags. Embarrasing. ;)

B

NSG10
Aug 30, 2010, 08:16 PM
I tried the link you gave me, but still no results. The only thing that's working is when I change admin. I'll leave that as the final solution, but in case is there anyway that I can get my data to the admin I created easily, so that I can delete the old one?

balamw
Aug 30, 2010, 08:27 PM
I tried the link you gave me, but still no results.

You're still not getting it.

What do you mean "no results" we're looking to find out the file permissions in your broken account's home folder, not trying to fix your problem (yet) until we know what the problem is.

I repeat. None of the commands posted since your last post make any attempt to fix your problem.

chown33 asked you to post the output from the commands, did they not generate any output?

Put another way, we are still in the diagnosis stage. We'll cure or kill the patient once we know what's ailing him.

B

NSG10
Aug 31, 2010, 05:07 PM
Stop.

Transferring all your files to the new account is the LAST step, not the FIRST step. Transferring the files isn't even the PREFERRED step, it's the last resort if nothing else works.


First, identify exactly what version of Xcode and Mac OS X you're using.

Second, make a backup of everything in your current admin account to a safe place. An external disk or a shared file server is safe enough.

Third, copy and paste this command-line exactly as given into Terminal, then paste the output into a post.


If you're not logged into your original admin account, do that next. Then launch Terminal.app using that account, and again copy and paste this exact command-line into a Terminal window, then paste the output into a post:
id -p; ls -la ~


I'm using iPhone SDK 4.0.2 on OSX 10.6.4
Heres what I got in the output.................

macintosh:~ niafgana$ ls -la /Users
total 0
drwxr-xr-x 6 root admin 204 Aug 30 23:45 .
drwxrwxr-t 32 root admin 1156 Jul 16 18:01 ..
-rw-r--r-- 1 root wheel 0 Jul 1 2009 .localized
drwxrwxrwt 12 root wheel 408 Jul 31 19:40 Shared
drwxr-xr-x+ 23 niafgana staff 782 Dec 11 2009 niafgana
drwxr-xr-x+ 14 nsg staff 476 Aug 30 23:55 nsg
macintosh:~ niafgana$ id -p; ls -la ~
uid niafgana
groups staff _developer _lpoperator _lpadmin _appserveradm admin _appserverusr localaccounts everyone com.apple.sharepoint.group.1 com.apple.access_screensharing com.apple.sharepoint.group.2
total 72
drwxr-xr-x+ 23 niafgana staff 782 Dec 11 2009 .
drwxr-xr-x 6 root admin 204 Aug 30 23:45 ..
-rw------- 1 niafgana staff 3 Sep 18 2009 .CFUserTextEncoding
-rw-r--r--@ 1 niafgana staff 24580 Aug 29 00:06 .DS_Store
drwxr-xr-x@ 3 niafgana staff 102 Oct 2 2009 .DownloadManager
drwx------ 2 niafgana staff 68 Aug 31 02:52 .Trash
drwxr-x--x 3 niafgana staff 102 Sep 28 2009 .adobe
-rw------- 1 niafgana staff 471 Aug 31 02:01 .bash_history
drwx------ 3 niafgana staff 102 Oct 10 2009 .cups
drwxr-xr-x 3 niafgana staff 102 Oct 6 2009 .mplayer
drwxr-xr-x 3 niafgana staff 102 Oct 28 2009 .ssh
drwx------+ 5 niafgana staff 170 Aug 31 02:51 Desktop
drwx------+ 11 niafgana staff 374 Aug 28 00:07 Documents
drwx------@ 6 niafgana staff 204 Aug 30 02:59 Downloads
drwxr-xr-x 7 niafgana staff 238 May 10 19:36 FrostWire
drwx------+ 50 niafgana staff 1700 Jul 25 23:11 Library
drwx------+ 8 niafgana staff 272 Aug 19 21:53 Movies
drwx------+ 7 niafgana staff 238 Mar 19 23:23 Music
drwx------+ 8 niafgana staff 272 Aug 19 21:53 Pictures
drwxr-xr-x+ 6 niafgana staff 204 Dec 2 2009 Public
drwxr-xr-x+ 6 niafgana staff 204 Oct 16 2009 Sites
drwxr-xr-x 10 niafgana staff 340 Aug 19 21:54 iPhone Stuff
drwxr-xr-x 3 niafgana staff 102 Aug 19 21:54 pwnage

balamw
Aug 31, 2010, 05:39 PM
drwxr-xr-x+ 23 niafgana staff 782 Dec 11 2009 niafgana
drwxr-xr-x+ 14 nsg staff 476 Aug 30 23:55 nsg



The unix level permissions are the same for both of the accounts, and I don't see anything odd with the groups your broken account belongs to.

It may be something in the ACLs, so try:

ls -lde /Users/n*
and see if there is any difference in the ACLs

You could also try:

mkdir ~/.Xcode and see what that does before you try again.

B

chown33
Aug 31, 2010, 06:41 PM
When logged into the niafgana account, copy and paste this command-line into a Terminal window.
find ~/Library -iname '*xcode*' -ls

Post the output.

NSG10
Aug 31, 2010, 08:04 PM
The unix level permissions are the same for both of the accounts, and I don't see anything odd with the groups your broken account belongs to.

It may be something in the ACLs, so try:

ls -lde /Users/n*
and see if there is any difference in the ACLs

You could also try:

mkdir ~/.Xcode and see what that does before you try again.

B

This is what I got.

macintosh:~ niafgana$ ls -lde /Users/n*
drwxr-xr-x+ 23 niafgana staff 782 Dec 11 2009 /Users/niafgana
0: group:everyone deny delete
drwxr-xr-x+ 14 nsg staff 476 Aug 30 23:55 /Users/nsg
0: group:everyone deny delete
macintosh:~ niafgana$ mkdir ~/.Xcode
mkdir: /Users/niafgana/.Xcode: Operation not permitted
macintosh:~ niafgana$ find ~/Library -iname '*xcode*' -ls
8571583 0 drwxr-xr-x 4 niafgana staff 136 Aug 31 02:51 /Users/niafgana/Library/Application Support/Developer/Shared/Xcode
8571572 0 drwxr-xr-x 2 niafgana staff 68 Aug 30 00:12 /Users/niafgana/Library/Application Support/Xcode
2734779 0 drwxr-xr-x 3 niafgana staff 102 Aug 31 00:00 /Users/niafgana/Library/Caches/com.apple.Xcode
8383856 8 -rw-r--r-- 1 niafgana staff 164 Aug 29 02:18 /Users/niafgana/Library/Caches/Metadata/Safari/History/http:%2F%2Fosdir.com%2Fml%2Fxcode-users%2F2010-04%2Fmsg00300.html.webhistory
7801735 8 -rw-r--r-- 1 niafgana staff 197 Aug 25 22:24 /Users/niafgana/Library/Caches/Metadata/Safari/History/http:%2F%2Fphotoaperture.com%2Fblog%2F2009%2F05%2F20%2Fhow-to-uninstall-xcode-and-iphone-sdk%2F.webhistory
7801703 8 -rw-r--r-- 1 niafgana staff 203 Aug 25 22:23 /Users/niafgana/Library/Caches/Metadata/Safari/History/http:%2F%2Fpushkararora.com%2Fhow-to%2Fhow-to-uninstall-xcode-completely%2F.webhistory
8009710 40 -rw-r--r-- 1 niafgana staff 16879 Aug 26 08:12 /Users/niafgana/Library/Caches/Metadata/Safari/History/http:%2F%2Fstackoverflow.com%2Fquestions%2F400894%2Fxcode-iphone-app-codesign-error.webhistory
8383871 8 -rw-r--r-- 1 niafgana staff 174 Aug 29 02:19 /Users/niafgana/Library/Caches/Metadata/Safari/History/http:%2F%2Fwww.cocoabuilder.com%2Farchive%2Fxcode%2F258006-xcode-internal-error.html.webhistory
8009726 24 -rw-r--r-- 1 niafgana staff 8624 Aug 26 08:15 /Users/niafgana/Library/Caches/Metadata/Safari/History/http:%2F%2Fwww.google.com%2F%23hl=en&safe=active&q=How+can+i+fix+xcode+errors&aq=f&aqi=&aql=&oq=&gs_rfai=&fp=9d19a192c6871a85.webhistory
7801647 8 -rw-r--r-- 1 niafgana staff 194 Aug 25 22:29 /Users/niafgana/Library/Caches/Metadata/Safari/History/http:%2F%2Fwww.google.com%2Fsearch?q=how%2520to%2520uniinstall%2520xcode&ie=utf-8&oe=utf-8&safe=active.webhistory
7801645 16 -rw-r--r-- 1 niafgana staff 7544 Aug 25 22:22 /Users/niafgana/Library/Caches/Metadata/Safari/History/http:%2F%2Fwww.google.com%2Fsearch?q=how%2520to%2520uniinstall%2520xcode&ie=utf-8&oe=utf-8.webhistory
8383833 8 -rw-r--r-- 1 niafgana staff 200 Aug 29 02:19 /Users/niafgana/Library/Caches/Metadata/Safari/History/http:%2F%2Fwww.google.com%2Fsearch?q=xcode%2520internal%2520error%2520fixes&ie=utf-8&oe=utf-8&safe=active.webhistory
8383834 16 -rw-r--r-- 1 niafgana staff 7774 Aug 29 02:18 /Users/niafgana/Library/Caches/Metadata/Safari/History/http:%2F%2Fwww.google.com%2Fsearch?q=xcode%2520internal%2520error%2520fixes&ie=utf-8&oe=utf-8.webhistory
7801881 8 -rw-r--r-- 1 niafgana staff 225 Aug 25 22:30 /Users/niafgana/Library/Caches/Metadata/Safari/History/http:%2F%2Fx10hosting.com%2Fforums%2Ftutorials%2F118472-how-uninstall-xcode-developer-tools-only-mac-users.html.webhistory
8110124 0 drwxr-xr-x 3 niafgana staff 102 Aug 30 23:27 /Users/niafgana/Library/Caches/xcodebuild
8942023 24 -rw------- 1 niafgana staff 12189 Aug 31 02:51 /Users/niafgana/Library/Preferences/com.apple.Xcode.plist
1329090 0 drwxrwxrwx 6 niafgana staff 204 Oct 21 2007 /Users/niafgana/Library/Widgets/iStat nano.wdgt/iStatNano.bundle/Contents/s/iStatNano.xcodeproj
macintosh:~ niafgana$

balamw
Aug 31, 2010, 08:14 PM
macintosh:~ niafgana$ mkdir ~/.Xcode
mkdir: /Users/niafgana/.Xcode: Operation not permitted

Well at least that's consistent. You could try mkdir ~/foobar
sudo mkdir ~/.Xcode

The first to see if you can create any folders here, the second to see if root can do it.

macintosh:~ niafgana$ find ~/Library -iname '*xcode*' -ls
8571583 0 drwxr-xr-x 4 niafgana staff 136 Aug 31 02:51 /Users/niafgana/Library/Application Support/Developer/Shared/Xcode
8571572 0 drwxr-xr-x 2 niafgana staff 68 Aug 30 00:12 /Users/niafgana/Library/Application Support/Xcode
2734779 0 drwxr-xr-x 3 niafgana staff 102 Aug 31 00:00 /Users/niafgana/Library/Caches/com.apple.Xcode
8110124 0 drwxr-xr-x 3 niafgana staff 102 Aug 30 23:27 /Users/niafgana/Library/Caches/xcodebuild
8942023 24 -rw------- 1 niafgana staff 12189 Aug 31 02:51 /Users/niafgana/Library/Preferences/com.apple.Xcode.plist


I have these 5 and the ones I'm ignoring are the Safari ones + Widgets. Your sizes seem quite a bit bigger than mine though, but I'm still running 3.2.3.

B

NSG10
Aug 31, 2010, 09:27 PM
Well at least that's consistent. You could try mkdir ~/foobar
sudo mkdir ~/.Xcode

The first to see if you can create any folders here, the second to see if root can do it.


I have these 5 and the ones I'm ignoring are the Safari ones + Widgets. Your sizes seem quite a bit bigger than mine though, but I'm still running 3.2.3.

B

Here's what it gave me:

macintosh:~ niafgana$ mkdir ~/foobar
mkdir: /Users/niafgana/foobar: Operation not permitted
macintosh:~ niafgana$ sudo mkdir ~/.Xcode
mkdir: /Users/niafgana/.Xcode: Operation not permitted

Sydde
Aug 31, 2010, 10:45 PM
Here's what it gave me:

macintosh:~ niafgana$ mkdir ~/foobar
mkdir: /Users/niafgana/foobar: Operation not permitted
macintosh:~ niafgana$ sudo mkdir ~/.Xcode
mkdir: /Users/niafgana/.Xcode: Operation not permitted

try it this way:


cd ~
mkdir .Xcode


the terminal should like that a little better

NSG10
Sep 1, 2010, 12:09 AM
try it this way:


cd ~
mkdir .Xcode


the terminal should like that a little better


Nope, it still gives the same output

macintosh:~ niafgana$ cd ~
macintosh:~ niafgana$ mkdir .Xcode
mkdir: .Xcode: Operation not permitted
macintosh:~ niafgana$ cd ~
macintosh:~ niafgana$ mkdir .Xcode
mkdir: .Xcode: Operation not permitted

chown33
Sep 1, 2010, 01:34 AM
Try this:
cd ~; pwd; id -p; /sbin/mount; /usr/bin/which mkdir


Then try this:
touch ~/testFile; ls -lde ~/*

balamw
Sep 1, 2010, 06:52 AM
Try this:
cd ~; pwd; id -p; /sbin/mount; /usr/bin/which mkdir



I'd add a

ls -lde `/usr/bin/which mkdir`
echo $PATH to that.

However, it looks like no matter what I get "Permission denied" instead of "Operation not permitted" even if I chmod 400 /bin/mkdir.

B

NSG10
Sep 1, 2010, 04:03 PM
Try this:
cd ~; pwd; id -p; /sbin/mount; /usr/bin/which mkdir


Then try this:
touch ~/testFile; ls -lde ~/*


macintosh:~ niafgana$ cd ~; pwd; id -p; /sbin/mount; /usr/bin/which mkdir
/Users/niafgana
uid niafgana
groups staff _developer _lpoperator _lpadmin _appserveradm admin _appserverusr localaccounts everyone com.apple.sharepoint.group.1 com.apple.access_screensharing
/dev/disk0s2 on / (hfs, local, journaled)
devfs on /dev (devfs, local, nobrowse)
map -hosts on /net (autofs, nosuid, automounted, nobrowse)
map auto_home on /home (autofs, automounted, nobrowse)
/bin/mkdir
macintosh:~ niafgana$ touch ~/testFile; ls -lde ~/*
touch: /Users/niafgana/testFile: Operation not permitted
drwx------+ 5 niafgana staff 170 Sep 1 05:29 /Users/niafgana/Desktop
0: group:everyone deny delete
drwx------+ 11 niafgana staff 374 Aug 28 00:07 /Users/niafgana/Documents
0: group:everyone deny delete
drwx------@ 6 niafgana staff 204 Aug 30 02:59 /Users/niafgana/Downloads
0: group:everyone deny delete
drwxr-xr-x 7 niafgana staff 238 May 10 19:36 /Users/niafgana/FrostWire
drwx------+ 50 niafgana staff 1700 Jul 25 23:11 /Users/niafgana/Library
0: group:everyone deny delete
drwx------+ 8 niafgana staff 272 Aug 19 21:53 /Users/niafgana/Movies
0: group:everyone deny delete
drwx------+ 7 niafgana staff 238 Mar 19 23:23 /Users/niafgana/Music
0: group:everyone deny delete
drwx------+ 8 niafgana staff 272 Aug 19 21:53 /Users/niafgana/Pictures
0: group:everyone deny delete
drwxr-xr-x+ 6 niafgana staff 204 Dec 2 2009 /Users/niafgana/Public
0: group:everyone deny delete
drwxr-xr-x+ 6 niafgana staff 204 Oct 16 2009 /Users/niafgana/Sites
0: group:everyone deny delete
drwxr-xr-x 10 niafgana staff 340 Aug 19 21:54 /Users/niafgana/iPhone Stuff
drwxr-xr-x 3 niafgana staff 102 Aug 19 21:54 /Users/niafgana/pwnage

chown33
Sep 1, 2010, 04:38 PM
/dev/disk0s2 on / (hfs, local, journaled)
devfs on /dev (devfs, local, nobrowse)
map -hosts on /net (autofs, nosuid, automounted, nobrowse)
map auto_home on /home (autofs, automounted, nobrowse)
/bin/mkdir

I don't see anything odd in the output from 'mount', and the location of mkdir is fine.

The fact that 'touch' fails with the same error means that something is preventing the creation of any file or folder in your home folder. I'm not sure what that could be, because both the permissions and the access-control list on the home folder allow writing by the owner.

You could try creating a new folder in your home folder using Finder, and see if that works or fails. I suspect it will fail, but it's worth trying.

The only odd thing I see at all is the 'pwnage' folder in your home folder. However, there could be any number of valid reasons for that, so I don't think it matters here.

When was the last time you rebooted this computer? Or has that already been tried.

To summarize, the problem doesn't seem to be Xcode itself. The problem seems to be an unwritable home folder. Solve that and I suspect Xcode will work fine.


Hmm, just thought of one other thing to try:
ls -lod ~
Post the output.

Then use Finder to Get Info on your home folder and make sure the Locked checkbox is unchecked.

NSG10
Sep 1, 2010, 05:32 PM
I don't see anything odd in the output from 'mount', and the location of mkdir is fine.

The fact that 'touch' fails with the same error means that something is preventing the creation of any file or folder in your home folder. I'm not sure what that could be, because both the permissions and the access-control list on the home folder allow writing by the owner.

You could try creating a new folder in your home folder using Finder, and see if that works or fails. I suspect it will fail, but it's worth trying.

The only odd thing I see at all is the 'pwnage' folder in your home folder. However, there could be any number of valid reasons for that, so I don't think it matters here.

When was the last time you rebooted this computer? Or has that already been tried.

To summarize, the problem doesn't seem to be Xcode itself. The problem seems to be an unwritable home folder. Solve that and I suspect Xcode will work fine.


Hmm, just thought of one other thing to try:
ls -lod ~
Post the output.

Then use Finder to Get Info on your home folder and make sure the Locked checkbox is unchecked.

I don't know what to say to you chown33 or any of the other users on here. I really feel like an idiot. The problem was that lock function on my home folder was on and thats whats been causing all the problems, I really feel like an idiot for not looking there, it seems like I'm a caveman who got hold of an Apple computer. Thanks chown33 for pointing that out for me and I can't thank you or any of the other users enough for helping me out. Thanks a Million, guys.

balamw
Sep 1, 2010, 06:16 PM
Then use Finder to Get Info on your home folder and make sure the Locked checkbox is unchecked.

How the heck does that work without showing up as an ACL or unix permissions problem.

B

chown33
Sep 1, 2010, 06:17 PM
Don't worry about it. I feel like a bit of an idiot for not thinking of it sooner.

It's the most accessible write-prevention switch in Mac OS X. Far more so than permissions, or access-control lists, or read-only mounting of file-systems. Yet here we all were, having you run commands that look at the least accessible things.

It's definitely a Homer Simpson "D'oh!" moment.

chown33
Sep 1, 2010, 06:21 PM
How the heck does that work without showing up as an ACL or unix permissions problem.

The Locked bit is the "uchg" bit in a file's flags word. The system-call to write it is chflags(2). The stat(2) struct member is st_flags to read it.

If the Locked checkbox is checked but dimmed, then it's the "schg" bit.

http://developer.apple.com/mac/library/documentation/Darwin/Reference/ManPages/man2/stat.2.html

It's like a lot of things in Unix: it just grew that way, or "It seemed like a good idea at the time".

NSG10
Sep 1, 2010, 06:25 PM
Thanks again and it definitely is a Homer Simpson moment....lol.

balamw
Sep 1, 2010, 06:27 PM
The Locked bit is the "uchg" bit in a file's flags word. The system-call to write it is chflags(2). The stat(2) struct member is st_flags to read it.

If the Locked checkbox is checked but dimmed, then it's the "schg" bit.

http://developer.apple.com/mac/library/documentation/Darwin/Reference/ManPages/man2/stat.2.html

It's like a lot of things in Unix: it just grew that way, or "It seemed like a good idea at the time".

Thanks. You learn something new every day.

The error message leaves a lot to be desired, but at least it doesn't include some long hex string like many Windows errors.

B