As configured in my dotfiles.
start new:
tmux
start new with session name:
#! /usr/bin/awk -f | |
# A script to extract the actual suppression info from the output of (for example) valgrind --leak-check=full --show-reachable=yes --error-limit=no --gen-suppressions=all ./minimal | |
# The desired bits are between ^{ and ^} (including the braces themselves). | |
# The combined output should either be appended to /usr/lib/valgrind/default.supp, or placed in a .supp of its own | |
# If the latter, either tell valgrind about it each time with --suppressions=<filename>, or add that line to ~/.valgrindrc | |
# NB This script uses the |& operator, which I believe is gawk-specific. In case of failure, check that you're using gawk rather than some other awk | |
# The script looks for suppressions. When it finds one it stores it temporarily in an array, | |
# and also feeds it line by line to the external app 'md5sum' which generates a unique checksum for it. |
// Allows: | |
// funkyParser() | |
module.exports = function createFunkyParser(opt) { | |
return new FunkyParser(opt) | |
} | |
function FunkyParser(opt) { | |
// make params optional | |
opt = opt || {} |
As configured in my dotfiles.
start new:
tmux
start new with session name:
#!/usr/bin/env bash | |
cd $HOME | |
git clone git://git.linaro.org/qemu/qemu-linaro.git qemu-linaro | |
cd qemu-linaro | |
sudo apt-get build-dep qemu # to install the build dependencies of qemu | |
./configure --target-list=arm-softmmu --prefix=$HOME/qemu | |
make | |
make install | |
# Now you have a QEMU in $HOME/qemu/bin/qemu-system-arm and can test a BeagleBoard-xM build on qemu by running: |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <sys/types.h> | |
#include <sys/stat.h> | |
#include <unistd.h> | |
#include <fcntl.h> | |
#include <sys/mman.h> | |
#define FILEPATH "/tmp/mmapped.bin" | |
#define NUMINTS (1000) |
You might want to read this to get an introduction to armel vs armhf.
If the below is too much, you can try Ubuntu-ARMv7-Qemu but note it contains non-free blobs.
First, cross-compile user programs with GCC-ARM toolchain. Then install qemu-arm-static
so that you can run ARM executables directly on linux
'use strict'; | |
module.exports = function CustomError(message, extra) { | |
Error.captureStackTrace(this, this.constructor); | |
this.name = this.constructor.name; | |
this.message = message; | |
this.extra = extra; | |
}; | |
require('util').inherits(module.exports, Error); |
// # Mocha Guide to Testing | |
// Objective is to explain describe(), it(), and before()/etc hooks | |
// 1. `describe()` is merely for grouping, which you can nest as deep | |
// 2. `it()` is a test case | |
// 3. `before()`, `beforeEach()`, `after()`, `afterEach()` are hooks to run | |
// before/after first/each it() or describe(). | |
// | |
// Which means, `before()` is run before first it()/describe() |