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
BINDIR=/usr/pkg/bin/ | |
TARGET=/usr/pkg/bin/python /usr/pkg/bin/ruby /usr/pkg/bin/erl \ | |
/usr/pkg/bin/emacs /usr/pkg/bin/vim /usr/pkg/bin/valgrind \ | |
/usr/pkg/bin/svn /usr/pkg/bin/hg /usr/pkg/bin/automake \ | |
/usr/pkg/bin/autoconf /usr/pkg/bin/pcc | |
all: $(TARGET) | |
/usr/pkg/bin/python: py-readline | |
cd /usr/pkgsrc/lang/python25 && make && make install |
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 <pthread.h> | |
#include <iostream> | |
#include <string> | |
// > $ g++ -g template_thread_test.cpp -lpthread | |
// > $ ./a.out | |
using namespace std; | |
template <typename Type1, typename Type2> | |
class Hoge{ |
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 python | |
# Copyright (c) 2009, Shinichiro Hamaji | |
# All rights reserved. | |
# | |
# Redistribution and use in source and binary forms, with or without | |
# modification, are permitted provided that the following conditions are met: | |
# | |
# * Redistributions of source code must retain the above copyright notice, this | |
# list of conditions and the following disclaimer. |
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 <stdlib.h> | |
#include <stdio.h> | |
#include <sys/types.h> | |
#include <unistd.h> | |
int main(){ | |
char cmd[1024]; | |
sprintf(cmd, "gcore -o hoge %d", getpid() ); | |
system(cmd); | |
} |
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
/* test_hook.c : dynamic library with a callback function for julius; | |
who inputs result of speech recognition. the result will be redirected | |
to twitter CLI client and posted to twitter.com. */ | |
#include <stdio.h> | |
#include <string.h> | |
#include <stdlib.h> | |
int | |
get_plugin_info(int opcode, char *buf, int buflen) | |
{ | |
switch(opcode) { |
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
% Copyright (c) 2009 UENISHI Kota | |
% | |
% Permission is hereby granted, free of charge, to any person obtaining a copy | |
% of this software and associated documentation files (the "Software"), to deal | |
% in the Software without restriction, including without limitation the rights | |
% to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
% copies of the Software, and to permit persons to whom the Software is | |
% furnished to do so, subject to the following conditions: | |
% | |
% The above copyright notice and this permission notice shall be included in |
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
# Copyright (c) 2009 UENISHI Kota | |
# | |
# Permission is hereby granted, free of charge, to any person obtaining a copy | |
# of this software and associated documentation files (the "Software"), to deal | |
# in the Software without restriction, including without limitation the rights | |
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
# copies of the Software, and to permit persons to whom the Software is | |
# furnished to do so, subject to the following conditions: | |
# | |
# The above copyright notice and this permission notice shall be included in |
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
# Copyright (c) 2009 UENISHI Kota | |
# | |
# Permission is hereby granted, free of charge, to any person obtaining a copy | |
# of this software and associated documentation files (the "Software"), to deal | |
# in the Software without restriction, including without limitation the rights | |
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
# copies of the Software, and to permit persons to whom the Software is | |
# furnished to do so, subject to the following conditions: | |
# | |
# The above copyright notice and this permission notice shall be included in |
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
%% MessagePack for Erlang | |
%% | |
%% Copyright (C) 2009 UENISHI Kota | |
%% | |
%% Licensed under the Apache License, Version 2.0 (the "License"); | |
%% you may not use this file except in compliance with the License. | |
%% You may obtain a copy of the License at | |
%% | |
%% http://www.apache.org/licenses/LICENSE-2.0 | |
%% |
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
% for(i=0; i < number ; i++){ | |
% sum +=i; | |
% } | |
% for(i=0; i < number ; i++){ | |
% sum = sum+i; | |
% } | |
range(To,To) when is_integer(From), is_integer(To)-> | |
[To]; | |
range(From,To) when is_integer(From), is_integer(To), From < To-> |
OlderNewer