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
#include "log.h" | |
unsigned char log_run_level = LOG_LVL_DEBUG; | |
const char * log_level_strings [] = { | |
"NONE", // 0 | |
"CRIT", // 1 | |
"WARN", // 2 | |
"NOTI", // 3 | |
" LOG", // 4 |
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
def rgb16(r, g, b): | |
r = (r & 255) >> 3 # RED (5 bits) | |
g = (g & 255) >> 2 # GREEN (6 bits) | |
b = (b & 255) >> 3 # BLUE (5 bits) | |
c = (r << (6+5)) | (g << 5) | b | |
return "0x{0:04x}".format(c) |
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
#!/bin/sh -x | |
# === ARGUMENTS PARSING === | |
# We don't want to define a default period | |
PERIOD= | |
while echo $1 | grep ^- > /dev/null; do | |
if [ "$1" = "--daily" ]; then |
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
#ifdef SHELL | |
SCENARIO=$1 | |
if [ "${SCENARIO}" = "" ]; then | |
SCENARIO=1 | |
fi | |
gcc -pthread -O3 -DSCENARIO=${SCENARIO} -Wall -Werror $0 && ./a.out | |
exit 0 | |
#endif | |
#include <pthread.h> | |
#include <stdio.h> |
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
OBJS=build/cvgui.o build/finder.o build/imgdb.o build/pyramid-template-matcher.o build/sikuli-debug.o build/tessocr.o build/vision.o build/visionJAVA_wrap.o | |
INCS=-I/usr/local/include -I/usr/include -I/usr/lib/jvm/default-java/include -I/usr/lib/jvm/default-java/include/linux | |
OPTS= -O3 -fPIC -MMD -MP $(INCS) | |
LIB=dist/libVisionProxy.so | |
all: $(LIB) |
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
#ifdef SHELL | |
gcc -Wall -Werror $0 && ./a.out 10 | |
exit 0 | |
#endif | |
#include <stdio.h> | |
#include <stdlib.h> | |
int main( int argc, char * argv [] ) { | |
int size = atoi(argv[1]); |
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
#ifdef SHELL | |
gcc $0 && ./a.out | |
gcc -m32 $0 && ./a.out | |
exit 0 | |
#endif | |
#include <stdio.h> | |
void nb1() { | |
char * str = "999999999999"; |
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
#ifdef SHELL | |
gcc $0 -g -Wall -Werror && valgrind -q ./a.out | |
exit 0 | |
#endif | |
#include <stdio.h> | |
int main( int argc, char * argv [] ) { | |
int i; | |
for(; i < 10; i++ ) { |
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
#ifdef SHELL | |
gcc $0 && ./a.out | |
gcc -DNDEBUG $0 && ./a.out | |
exit 0 | |
#endif | |
#include <stdio.h> | |
#ifndef NDEBUG | |
#define DEBUG(fmt, arg...) \ |
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
#!/bin/sh | |
JETTY_VERSION=9.0.5.v20130815 | |
# We reset everything | |
rm -Rf jetty-distribution-${JETTY_VERSION} jetty | |
# We prepare the dirs | |
mkdir -p jetty/opt jetty/etc/init.d jetty/etc/default jetty/DEBIAN |