osx

How to create the empty 'Icon\r' file for a .dmg from shell script?

Hi, From shell script, I would like to create the empty 'Icon\r' file for a Mac OS X disk image (dmg), so as the .VolumeIcon.icns icon file is taken into account by the finder; the damn '\r' character is not accepted from the console: touch Icon\r ls Icon* > Iconr and other things happen when trying to type 'Icon\r', "Icon\r" etc., ...

Set Subversion root directory for access via svn+ssh

I'm having trouble setting Subversion's root folder for repositories. The path has gotten pretty long and I'd like to shorten it to "/". We currently access Subversion from clients via: svn+ssh://server.domain.com/Library/Subversion/Repositories/project/trunk and would like to shorten URL to: svn+ssh://server.domain.com/project/trun...

How to disable "USB Over Current Notification" popups in the Finder in Mac OS X 10.6?

On an Intel iMac (Model MB324LL/A) (currently running 10.6.4), every few minutes (or seconds) I get a Finder popup window reading: Because a USB device was drawing too much power from your computer, one or more of your USB devices have been disabled. In Console, the associated message: USB Notificaton: The device "EHCI Root Hu...

Why is the packagemaker command chown'ing all my installed files to root?

For some reason, when I run the my installer it sets each file's owner to root group to wheel, and permissions mask to 700. I have checked that the permissions and owner of the files in files (which I build the installer from via the --root parameter) are set to the current user and 755. I also tried adding the --no-recommend flag, but ...

Why Do All My Open MPI Processes Have Rank 0?

I'm writing a parallel program using Open MPI. I'm running Snow Leopard 10.6.4, and I installed Open MPI through the homebrew package manager. When I run my program using mpirun -np 8 ./test, every process reports that it has rank 0, and believes the total number of processes to be 1, and 8 lines of process rank: 0, total processes: 1 g...

Mac OS X 10.6 ODBC Drivers

Hi all, I'm going crazy trying to find a FOSS free (doesn't have to be open source) ODBC driver to connect to an MS SQL Server. While it doesn't strictly have to be free (which is a huge plus, for obvious reasons), the drivers I have found haven't had an easy to find price tag. Does anyone know of any preferably free, and if not free, t...

Programmatically interact with attached iOS/iPods in OSX 10.6

I am trying to develop a simple menu bar application that would let me visualize the charging status of my attached iPhone/iPad without having to launch iTunes. After a long search, I am unable to conclude if this is a possibility with the Snow Leopard APIs. My search has led me to a service running at boot time called com.apple.ipodse...

Why [Debug] button is replace by a [Morph] button in Xcode?

In Xcode (3.2.4), View > Layout > Show Page Control. In my old MacBook's Xcode, the Page Control shows [Project] and [Debug] buttons. In my new MacBook, the Page Control shows [Project] and [Morph] buttons. How can I get the old [Debug] button back and get rid of the [Morph] button? Thanks! ...

No padlock on secure site ONLY MAC Safari

Hi, for some reason I'm not getting the padlock/green bar/whatever on my site, but ONLY using Safari for Mac. Firefox (win/mac), Chrome (win/mac), Safari (win), Opera (win/mac), IE (6/7/8) all work as they should. Is this a bug? Something I should worry about (credit cards, etc will be sent over this server)? ...

Cocoa Speech Synthesis, save Audio to a buffer for use in OpenAL

Hi, I want to translate text to audio on osx similar as done here: http://developer.apple.com/library/mac/#samplecode/CocoaSpeechSynthesisExample/Introduction/Intro.html . After the sound is finished playing I would like to save it to a buffer for further use in openAL, is that possible? The only way I see right now is to save the spe...

Lost OS X Java source code

I upgraded to JDK 6 build 22 on Snow Leopard and now I cannot find the src.zip file. I downloaded javadeveloper_10.6_10m3261 from the Apple Developer's website and installed it, but a find . -name src.zip -ls in both /System and /Developer yields nothing. Any ideas? ...

32-bit Flash player in 64-bit Safari: how?

Yes, I know, WebKit uses a separate 32-bit process to play Flash and communicate with it. But how does Flash draw in a browser? In Mac OS X you cannot draw on a foreign window or reparent your one. So if the Flash player hosts in another process, how can it obtain the browser window's context (CGContextRef) and be drawn in it? ...

ld can't find X11 library on OSX Leopard

I have a pretty basic X11 app that I run on Linux that I'm trying to get compiled under OSX 10.5.8. I have X11 and the X11 SDK installed, and modified the makefile as follows: CFLAGS = -L/usr/X11/lib -I/usr/X11/include Everything compiles fine, but the linker can't find the X11 lib. ld: library not found for -lX11 I've looked on goog...

OS X + Crontab: How do you run SCP via cron?

This works fine when I run it by hand: #!/bin/bash eval `ssh-agent` ssh-add /usr/bin/scp me@server:~/file ./ exit 0 However, when the cron runs the file is never touched. I know the ssh keys are right - replace that scp with an ssh and it runs fine. ...

Get inexistent system user info without the output

This is my code for getting all system users: def get_all_system_users user_paths = Dir["#{ENV['HOME']}/../*"] users = user_paths.map { |path| path.split("..")[-1].gsub(/\W/, '') } users.select { |user| %x{id #{user}}.include?("uid") } end The problem is the id #{user} command which returns an output for inexistent users that b...

Set up a Zend project in OS X

I'm trying to set up a new Zend project using Zend Server CE under OS X 10.6 First, I have downloaded and successfully installed Zend Server CE: opening http://localhost:10081 in my browser shows the dashboard, and everything seems to be working fine. Than I created a new project, following the tutorial: $ cd /usr/local/zend/apache...

Apple Events to Control Mouse Remotely

Hey, I'm not even sure where to begin with this question... I want to be able to send mouse-click events to another machine, as if the user had clicked on that machine. I can do it on the same machine via: CGEventSourceRef source = CGEventSourceCreate(NULL); CGEventType eventType = kCGEventLeftMouseDragged; CGPoint mouseCursorPosi...

Mac OSX PackageMaker: how to install multiple packages and post-processing

I find myself in a unique scenario -- it has to be, because no searching I do seems to turn up any answers. But maybe there's a MacOS X guru out there that can answer this for me? I'm using PackageMaker to create an install process for my company's application. It's a cross-platform app and my home base is Linux and Windows, so please...

Prevent OpenGL.framework from Loading in Cocoa App

My application links against these Frameworks: Cocoa.Framework AppKit.Framework CoreData.Framework Foundation.Framework Note that OpenGL.Framework is NOT linked. However, after setting DYLD_PRINT_LIBRARIES=1, I note that: ... dyld: loaded: /System/Library/Frameworks/OpenGL.framework/Versions/A/OpenGL dyld: loaded: /Syste...

Web Dev on MacOSX, how to check IE compatIbility?

How can I check IE compatibility when I'm developing a website on MacOSX, primarily using Chrome. ...