Showing posts with label mac osx. Show all posts
Showing posts with label mac osx. Show all posts

Saturday, November 13, 2010

sygnery - ubunutu mouse/keyboard sharing with a Mac-- bootup

Find, download and install the sygnery client(mAC) and server for the respective machine

Note that the machine names will need to be replace with whatever yours are mine are:
mac-mini.local
ubuntu-desktop

################### CLIENT (MAC OSX) #####################
For the mac client. (IE not using the mac mouse or keyboard)
mkdir ~/LoginItems
cat > ~/LoginItems/start_synergy.command 
/Applications/synergy/synergyc -f 

Then in Settings -> Accounts -> select the user -> login items
Add the .command file as a terminal shell script.


################### SERVER (UBUNTU) #####################

For the ubutu server. (IE not using the ubuntus mouse or keyboard, on a remote)

vi .synergy.conf

Add the lines
section: screens
ubuntu-desktop:
mac-mini.local:
super = alt
alt = super
end
section: links
ubuntu-desktop:
right = mac-mini.local
mac-mini.local:
left = ubuntu-desktop
end

Assuming your a bash user
vi .bashrc

Add the lines
sysergys_exec=`ps -A | grep synergys`
if [ "$sysergys_exec" = "" ]
then
synergys 
fi

Then restart(only really need to logout/login) and see what happens.

You could run the server globally from your xwindows config or even from start up but i prefer to have it in my bash where i can get at it and modify it easier.

Tuesday, April 27, 2010

Mac OSX lib tools

I keep forgetting there names

nm --help
otool --help

For example to determine the arch of a lib hit it with these commands(not the best way but it works)

nm -arch i386 libname
nm -arch x86_64 libname

installing id3lib-ruby on mac

UPDATE 2) Fink is busted on 10.6 the lib has not built correctly and is crashing... switch to macports and install id3lib from there then (re)install the gem with this

sudo env ARCHFLAGS="-arch x86_64" gem install id3lib-ruby -- --with-opt-dir=/opt/local

UPDATE 1) Hold up... there is an easier way..

sudo env ARCHFLAGS="-arch i386" gem install id3lib-ruby -- --with-opt-dir=/sw

Confirm the result with this
arch -i386 irb
>> require 'id3lib'
=> true
>> tag = ID3Lib::Tag.new('talk.mp3')
=> []
>> 

ORIGINAL POST:
The default id3lib gem is way to stale for it to build on OSX 10.6...
so you need to start hacking stuff, in truth the maintainer is already
handled the problems u just need the newest version..

download the source code and untar it;
http://github.com/robinst/id3lib-ruby (the upper right has the
download source link or just git it)

then do this;

export PATH=/sw
export DYLD_LIBRARY_PATH=/sw/lib
cd to/the/source
sudo CONFIGURE_ARGS="--with-opt-dir=/usr/local" ruby setup.rb

confirm success with $ irb >> require 'rubygems' => false >> require 'id3lib' => true >>