View this PageEdit this PageUploads to this PageHistory of this PageTop of the SwikiRecent ChangesSearch the SwikiHelp Guide

PySCLang on OSX

Home   How To   Code Pool   Public Library   Theory   Events

To compile PySCLang on OSX

Start with a fresh default build of superCollider (not the modified
build above)

Open SuperCollider3/Psycollider/PySCLang/PySCLang.xcodeproj

In the Groups & Files pane in Xcode:
-Navigate to Frameworks
-if libsndfile.a is red in color
- Click on libsndfile.a
- Click the info button
- Click choose
- Navigate to and select your copy of libsndfile.a
(usually in /usr/local/lib/)

Set Active Build Configuration to "Deployment"

Choose Edit Active Project "PySCLang"
Choose the Build Tab
Choose "Deployment" from the Configuration Dropdown
Choose "Customized Settings" from the Collection Dropdown
Change "Library Search Paths" to ../../build
Change Instruction Scheduling to match your processor
Make sure Prebinding and ZeroLink are NOT checked
Close the window

Click on the "Build" button
(then type apple-shift-B, if you want to watch it go)

(similar to what we did with the PATH variable above)

- Type: python (This will start the python interpreter)
- Type: import PySCLang
- If there are no errors, things are looking good!
- Type: langPath = os.path.expanduser('~/sclang/')
- Type: PySCLang.setCmdLine("s = Server.local; s.boot; ")
- Type: PySCLang.sendMain('interpretPrintCmdLine')
- Wait for the server to boot
- Type: PySCLang.setCmdLine("s.initTree;
- Type: PySCLang.sendMain('interpretPrintCmdLine')
- Wait for a few seconds
- Type: PySCLang.setCmdLine(" {, 0, 0.4)
}.play(s) ")
- Type: PySCLang.sendMain('interpretPrintCmdLine')
- A sine wave should play
- Type: PySCLang.setCmdLine("s.quit; s.serverRunning=false")
- Type: PySCLang.sendMain('interpretPrintCmdLine')
- This should quit the server

Links to this Page