how can I access /usr/local from a Mac file dialog

Joined
Apr 9, 2008
Messages
1
Reaction score
0
Points
1
Hi everyone,

I have been trying to do this for the last hour and am completely frustrated.

I have to add some header files and libraries in my XCode project and these files are in the /usr/local directory. I can see them from my console... I can do cd /usr/local and it works fine.

Now, how can I access this path from a file dialog box???! XCode shows me the file dialog where I have to select the path and I cannot navigate to this directory.

Please help! I am going crazy!

Cheers,
Luca
 
Joined
Apr 29, 2006
Messages
4,576
Reaction score
378
Points
83
Location
St. Somewhere
Your Mac's Specs
Mac Studio, M1 Max, 32 GB RAM, 2 TB SSD
In Finder, use the Go, Go To Folder dialog. It opens a window that lets you type in the path you want. I just tried this under Tiger and it works like charm.
 
Joined
Mar 30, 2004
Messages
4,744
Reaction score
381
Points
83
Location
USA
Your Mac's Specs
12" Apple PowerBook G4 (1.5GHz)
To get to it in a file chooser dialog, you'll need to either

1. Make it visible, using something like TinkerTool
2. Leave it invisible, but make a visible alias* to it. There are several ways to do this, the easiest of which is to use the "Go To" command as mac57 suggested, and then holding down the Command and Option keys and dragging the folder icon from the title bar (the very top of the window) to the Desktop, or some other folder. Then you can navigate to this alias in the file chooser.

*By alias, I mean a Macintosh alias, a pointer file, not the Unix alias command.
 
Joined
Feb 13, 2005
Messages
1,186
Reaction score
73
Points
48
Location
New Orleans, LA, USA
Your Mac's Specs
13" Macbook Pro 2.26Ghz Unibody 4G RAM 160G HDD Superdrive
*By alias, I mean a Macintosh alias, a pointer file, not the Unix alias command.

Ah, not to be pedantic (but of course I am) in the Unix world we would consider that to be a symlink.

And yeah, that would probably work pretty well.
 
Joined
Apr 29, 2006
Messages
4,576
Reaction score
378
Points
83
Location
St. Somewhere
Your Mac's Specs
Mac Studio, M1 Max, 32 GB RAM, 2 TB SSD
By the way, is there any reason why you could not just use good 'ol bash from Terminal.app to put the files where you need them to be? The cp command should do the trick, no?
 
Joined
Mar 17, 2008
Messages
6,879
Reaction score
191
Points
63
Location
Tucson, AZ
Your Mac's Specs
Way... way too many specs to list.
Ack, I should read. Never mind :)
 
Joined
Apr 29, 2006
Messages
4,576
Reaction score
378
Points
83
Location
St. Somewhere
Your Mac's Specs
Mac Studio, M1 Max, 32 GB RAM, 2 TB SSD
Ack, I should read. Never mind :)

Phew, because I read this post just before you edited it and couldn't figure out what your suggested incantation would do!
 
Joined
Mar 30, 2004
Messages
4,744
Reaction score
381
Points
83
Location
USA
Your Mac's Specs
12" Apple PowerBook G4 (1.5GHz)
Ah, not to be pedantic (but of course I am) in the Unix world we would consider that to be a symlink.

And yeah, that would probably work pretty well.
The point being, there are two different, but equally correct uses of the word "alias" in OS X, which can be especially confusing in situations like this where the Unix side meets the Mac side.

Symlinks are more like Windows Shortcuts than aliases: they both lose their targets far too easily.
 
Joined
Mar 17, 2008
Messages
6,879
Reaction score
191
Points
63
Location
Tucson, AZ
Your Mac's Specs
Way... way too many specs to list.
The point being, there are two different, but equally correct uses of the word "alias" in OS X, which can be especially confusing in situations like this where the Unix side meets the Mac side.

Symlinks are more like Windows Shortcuts than aliases: they both lose their targets far too easily.
you can easily do a hard link in Unix too, although you can't span volumes with them as they point to a specific inode.

FWIW the term 'alias' in the unix environment would apply to a command anyway.
 
Joined
Jul 1, 2016
Messages
1
Reaction score
0
Points
1
To get to it in a file chooser dialog, you'll need to either

1. Make it visible, using something like TinkerTool
2. Leave it invisible, but make a visible alias* to it. There are several ways to do this, the easiest of which is to use the "Go To" command as mac57 suggested, and then holding down the Command and Option keys and dragging the folder icon from the title bar (the very top of the window) to the Desktop, or some other folder. Then you can navigate to this alias in the file chooser.

*By alias, I mean a Macintosh alias, a pointer file, not the Unix alias command.

A coworker suggested what I think is a friendlier way, although I still don't understand why there just isn't a Mac preference to undo this feature.

So the suggestion is to go into Finder first.

1) Go > Go to folder and enter /usr/local. Should now show you the folders in this location.
2) At the bottom of the finder window are some icons showing the path. Drag the usr icon up into the Favorites section and it will now be available with the file chooser dialog box in the future.
 

Raz0rEdge

Well-known member
Staff member
Moderator
Joined
Jul 17, 2009
Messages
15,771
Reaction score
2,111
Points
113
Location
MA
Your Mac's Specs
2022 Mac Studio M1 Max, 2023 M2 MBA
This is a 8+ year post..:)
 
Joined
Feb 14, 2004
Messages
4,781
Reaction score
166
Points
63
Location
Groves, Texas
Seems there's a bit of this going around Ashwin. New users answering zombie posts.
 

chscag

Well-known member
Staff member
Admin
Joined
Jan 23, 2008
Messages
65,248
Reaction score
1,833
Points
113
Location
Keller, Texas
Your Mac's Specs
2017 27" iMac, 10.5" iPad Pro, iPhone 8, iPhone 11, iPhone 12 Mini, Numerous iPods, Monterey

Shop Amazon


Shop for your Apple, Mac, iPhone and other computer products on Amazon.
We are a participant in the Amazon Services LLC Associates Program, an affiliate program designed to provide a means for us to earn fees by linking to Amazon and affiliated sites.
Top