osx-snow-leopard

How to change the mirror of macports

你说的曾经没有我的故事 提交于 2019-12-10 13:21:53
问题 I'm a newbie to OS X, and totally confused about the way macports works. My question is, how to change the mirror or the sites where macports download the portfiles and distfiles. The mirror I'm trying to use: http://mirrors.ustc.edu.cn/macports/ Should I change the sources.conf? But this mirror has no rsync protocol(I'm not really clear about what rsync protocol is >_<). Or should I configure the macports.conf? I know about the macports offical guide, but I'm not smart enough to figure this

Raw access to HID devices in OS X

浪尽此生 提交于 2019-12-10 12:41:37
问题 What is the simplest way to get raw access to HID devices on OS X? I've been looking through the IOKit examples, but even opening a device seems needlessly complex, involving multiple callbacks and include things from half a dozen libraries. libusb is available for OS X, but the kernel grabs all HID devices for exclusive access, and I have been getting strange behavior while trying to use a codeless .kext to block it from associating with my device (it prevents the kernel from grabbing the

How to get list of installed applications on mac

*爱你&永不变心* 提交于 2019-12-10 12:13:50
问题 I need to get list of installed applications on leopard / snow leopard. Can any one suggest me how I can get list of installed apps using my cocoa application. I have tried using "system_profiler SPApplicationsDataType". Problem with this is it just lists out *.app files, which includes the drivers as well. Is there a way to get only list of "installed apps". 回答1: You might be able use to use system_profiler -xml SPApplicationsDataType and then parse the resulting XML data to get just the

Deploy Lion app to 10.6 exception

感情迁移 提交于 2019-12-10 11:22:54
问题 I have an OS X App That builds on Lion (with latest sdk) but deploy set to 10.6 (to be able run on Snow Leo). ARC enabled. I want's to run app on Show Leopard. Application works well on Lion. But when I start application in 10.6 I get this exception in console: NSRLEArray objectAtIndex:effectiveRange: Out of bounds And nothing more. No stack or whatever. Just this one line. What I may do to clarify situation ? Problem seems more strange, since in Lion all works good. 来源: https://stackoverflow

Controlling OS X volume in Snow Leopard

随声附和 提交于 2019-12-10 10:24:46
问题 This is a follow up to Controlling volume of running applications in Mac OS X via Objective-C, which explains how to set the volume for 10.5 or earlier. The AudioXXXXXGetProperty , and AudioXXXXXSetProperty (and related) functions are deprecated in 10.6, per Technical Note TN2223. I'm not an expert in OS X or CoreAudio programming, so I'm hoping someone has muddled through what's required in Snow Leopard and can help me (and others) out here. 回答1: Here's an example to set volume to 50%:

Proper way to make a fat binary prefer to be 32bit on 64bit OS X 10.6?

Deadly 提交于 2019-12-10 10:24:38
问题 Suppose I ask the user "do you want to run in 32bit mode or 64bit mode" and they pick 32bit. How do I register this fact with the operating system? I've looked at the arch command, but I don't want to have to write a script that wraps the binary. I suspect there is a plist-y way to do this, but I can't find documentation (other than arch). 回答1: Try using this Info.plist key, LSArchitecturePriority: <key>LSArchitecturePriority</key> <array> <string>i386</string> <string>x86_64</string> <string

CakePHP: Can't access MySQL database

馋奶兔 提交于 2019-12-10 03:21:21
问题 I'm new to CakePHP and am just running through the configuration process, but am stumped why Cake can't access my MySQL database. The Cake info page says my tmp directory is writable, the FileEngine is being used for caching (don't know what this means), and my database configuration file is present, but that CakePHP cannot connect to the database. Here are my setup details: PHP 5.3 (pre-installed on Snow Leopard) MySQL 5.1.40 64-bit CakePHP 1.2.4.8284 Here are the steps I went through:

Strip metadata from files in Snow Leopard

人走茶凉 提交于 2019-12-10 00:58:29
问题 I found the command "mdls" which will show the metadata but I can't see how to delete it. I want to get rid of the comments "kMDItemFinderComment", "kMDItemWhereFroms" from my files. Is there a way to do this? 回答1: I think you're looking for the xattr command, available in Terminal: xattr -pr com.apple.metadata:kMDItemFinderComment / that will print all the finder comments for all files on your boot volume. To delete, use the -d switch: xattr -dr com.apple.metadata:kMDItemFinderComment / You

Xcode linker error on iPhone app (Only on simulator)

隐身守侯 提交于 2019-12-10 00:28:31
问题 Im getting this linker error that won't let me compile. It only happens on the simulator. KEY POINTS: - Happens only in simulator - Similar to THIS question, but found no FRAMEWORK_SEARCH_PATHS in my .pbxproj file - Though my OS is 10.6.2, I had to build target 1.5 to avoid other linker errors - libxml2.dylib IS required and is in my Frameworks group - The other cited libraries I have never heard of. - Tried bringing in those other Libs under frameworks, didn't solve. Build SpaceTweet of

How to Install rpy2 on Mac OS X

一世执手 提交于 2019-12-09 18:13:30
问题 I am trying, so far unsuccessfully, at installing the rpy2 for python on my Mac OSX. I have tried Macports and DarwinPorts but have had no luck with import rpy2 within the python shell environment. I don't know much about programming in Mac and I am a wiz at installing modules on a Windoze based system, but for the life of me cannot do a simple port on my Mac at home. What I am after, if someone would be so kind, are "dumbed down" instructions for a successful install of rpy2 for Mac OSX Snow