export OPT=/opt
export BUILDS=/some/where/mini_linux
mkdir -p $BUILDS
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env sh | |
cd /tmp | |
apt-get update | |
apt-get -y install git build-essential | |
apt-get -y install linux-source linux-headers-generic | |
tar xvf /usr/src/linux-source-`uname -r | awk 'BEGIN { FS="-" } { print $1 }'`.tar.bz2 -C /usr/src | |
git clone https://github.com/luigirizzo/netmap.git | |
cd netmap/LINUX | |
SRC_VAR=/usr/src/linux-source-`uname -r | awk 'BEGIN { FS="-" } { print $1 }'` | |
./configure --kernel-sources=${SRC_VAR} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
# -*- coding: utf-8 -*- | |
# | |
#author: rex | |
#blog: http://iregex.org | |
#filename tr.py | |
#created: 2010-08-01 20:24 | |
#source uri: http://iregex.org/blog/trie-in-python.html | |
# escape bug fix by fcicq @ 2012.8.19 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#ifndef MAP_HPP | |
#define MAP_HPP | |
//#include <cstdint> | |
#include <stdint.h> | |
#include <cstddef> | |
#include <map> | |
#include <functional> | |
#include <boost/functional/hash.hpp> | |
#include <memory> | |
#include <utility> |