build_mac
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| build_mac [2011/08/01 23:36] – [4. Deploy] mh | build_mac [2012/01/03 03:29] (current) – Added info box for macports darthrake | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| + | <note important> | ||
| + | ...otherwise Mac OS will break your r0ket file system. | ||
| + | **NEVER EVER access the r0ket with the finder.** | ||
| + | Always use only the terminal. | ||
| + | </ | ||
| + | |||
| ====== Build environment on Mac OS X ====== | ====== Build environment on Mac OS X ====== | ||
| - | ===== 0. Work in Progress / First Trial ===== | ||
| - | This page will hopefully soon explain how to setup the build environment on a Mac. | ||
| - | As of now, the setup has not yet been completely tried out / documented. | ||
| ===== 1. Compiler ===== | ===== 1. Compiler ===== | ||
| + | |||
| + | == Using Mac OS X: == | ||
| + | |||
| <note tip> | <note tip> | ||
| - | The CodeSourcery G++ package provides a GNU cross-compiler toolchain for ARM, but needs to be built first from source code. | + | The CodeSourcery G++ package provides a GNU cross-compiler toolchain for ARM. The Mac OS X version is not distributed by CodeSourcery in binary form, but can be built from source code, or mainline gcc for arm-none-eabi can be installed via MacPorts. |
| </ | </ | ||
| - | * This explains how to build the tool chain on a Mac: [[https:// | + | === Solution 1 === |
| - | * Note: This builds release: __...__ | + | * This explains how to build the tool chain on a Mac: [[https:// |
| + | * You will probably want to add this line to / | ||
| - | ===== Other options: Ubuntu Linux in a VirtualBox | + | === Solution 2 === |
| - | http:// | + | |
| + | <note tip> | ||
| + | This " | ||
| + | < | ||
| + | arm-none-eabi-ld: | ||
| + | arm-none-eabi-ld: | ||
| + | </ | ||
| + | |||
| + | * Install [[http:// | ||
| + | * Don't forget < | ||
| + | * Install the port '' | ||
| + | |||
| + | === Solution 3 === | ||
| + | * Currently not working (at least on Lion). Less pain: MacPorts | ||
| + | * Install [[http:// | ||
| + | * Import (as in copy to / | ||
| + | * Install the formula '' | ||
| + | |||
| + | |||
| + | == Another option: Installing | ||
| + | * [[http:// | ||
| + | * Then refer to the [[build?&# | ||
| + | |||
| + | ===== 2. Source ===== | ||
| + | see [[build?&# | ||
| + | |||
| + | ===== 3. Build ===== | ||
| + | see [[build?&# | ||
| ===== 4. Deploy ===== | ===== 4. Deploy ===== | ||
| Line 20: | Line 54: | ||
| e.g. by using Method 1 (up to 30 seconds, but works always) | e.g. by using Method 1 (up to 30 seconds, but works always) | ||
| * Power off r0ket | * Power off r0ket | ||
| - | * Press and hold button “Left” | + | * Press and hold button “Left”, power r0ket on |
| * Connect r0ket via USB | * Connect r0ket via USB | ||
| Mac OS X will show a "CRP DISABLD" | Mac OS X will show a "CRP DISABLD" | ||
| + | |||
| + | == Using the Mac OS X Terminal: == | ||
| + | |||
| + | < | ||
| + | |||
| + | Note: Copying the firmware.bin over to the device in the Mac OS X Finder does __not__ work. | ||
| == Using the Ubunto Terminal in a VirtualBox: == | == Using the Ubunto Terminal in a VirtualBox: == | ||
| Line 32: | Line 72: | ||
| < | < | ||
| - | == Using the Mac OS X Terminal: == | ||
| - | < | + | ===== 9. Prepare a brand new r0ket ===== |
| + | See [[build|main Build article (scoll to the bottom)]], | ||
| + | or: | ||
| - | Note: Copying | + | Bring the r0ket into ISP-Mode: |
| + | e.g. by using Method 1 (up to 30 seconds, but works always) | ||
| + | * Power off r0ket | ||
| + | * Press and hold button “Left”, power r0ket on | ||
| + | * Connect r0ket via USB | ||
| + | |||
| + | If you want to start from scratch: | ||
| + | < | ||
| + | rm / | ||
| + | </ | ||
| + | |||
| + | Install | ||
| + | < | ||
| + | cd firmware | ||
| + | make APP=initial | ||
| + | cp firmware.bin | ||
| + | </ | ||
| + | The Data Flash will be formatted. | ||
| + | Now the r0ket will present a flash file system called "NO NAME" | ||
| + | Install | ||
| + | < | ||
| + | cd l0dable | ||
| + | make | ||
| + | cp *.c0d / | ||
| + | cp *.int / | ||
| + | cp *.nik / | ||
| + | cd .. | ||
| + | </ | ||
| + | Now install | ||
| + | < | ||
| + | make APP=final | ||
| + | cp firmware.bin / | ||
| + | </ | ||
| + | === Example commands that worked for me === | ||
| + | MacOSX, Lion, Up-to-date MacPorts - DanBUK | ||
| + | < | ||
| + | sudo port sync | ||
| + | sudo port install arm-none-eabi-gcc | ||
| + | git clone git:// | ||
| + | cd r0ket | ||
| + | git checkout c583ddc7e3b6ecc2cdb94fe0a0474d52bcbb220b | ||
| + | cd firmware | ||
| + | cp SECRETS SECRETS.release | ||
| + | # Edit SECRETS.release | ||
| + | ./ | ||
| + | make APP=initial | ||
| + | cp firmware.bin ../ | ||
| + | cd ../release/ | ||
| + | # ISP Mode - Power on whilst holding left on Joypad | ||
| + | # NB. This isn't always CRP DISABLED, could be CRP2 ENABLED | ||
| + | mount | grep "CRP DISABLD" | ||
| + | # / | ||
| + | cp initial.bin / | ||
| + | diskutil unmount "CRP DISABLD" | ||
| + | # power off | ||
| + | # power on | ||
| + | mount | grep "NO NAME" | ||
| + | # /dev/disk3 on /Volumes/NO NAME (msdos, local, nodev, nosuid, noowners) | ||
| + | # If you want to start completely empty: | ||
| + | # rm -Rf / | ||
| + | cp files/* / | ||
| + | diskutil unmount "NO NAME" | ||
| + | # press button (joypad middle) | ||
| + | mount | grep "CRP2 ENABLD" | ||
| + | # /dev/disk3 on / | ||
| + | cp final.bin / | ||
| + | diskutil eject "CRP2 ENABLD" | ||
| + | # power off | ||
| + | # power on | ||
| + | # Enjoy! | ||
| + | </ | ||
build_mac.1312234587.txt.gz · Last modified: by mh
