FrontPage > memo_temp

KURO-BOX:~$ sudo hdparm -u1 -c3 -d1 /dev/hda

http://psas.pdx.edu/DebianCrossCompilerHowto/

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\TurnOffComputer] "Type"="group" "Text"="終了オプション" "Bitmap"=hex(2):25,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,00,6f,00,6f,00,74,\

 00,25,00,5c,00,73,00,79,00,73,00,74,00,65,00,6d,00,33,00,32,00,5c,00,73,00,\
 68,00,65,00,6c,00,6c,00,33,00,32,00,2e,00,64,00,6c,00,6c,00,2c,00,32,00,38,\
 00,00,00

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\TurnOffComputer\HibernateButton] "Type"="checkbox" "Text"="終了オプションに休止状態ボタンを表示する" "HKeyRoot"=dword:80000001 "RegPath"="Software\\Policies\\Microsoft\\Windows\\System\\Shutdown" "ValueName"="ShowHibernateButton" "CheckedValue"=dword:00000001 "UncheckedValue"=dword:00000000 "DefaultValue"=dword:00000000

extern inline __attribute__*1 a(int arg); static inline __attribute__*2 b(int arg) {

       return 0;

} int main(int argc, char *argv[]) {

       a(0);
       b(0);
       return 0;

}

http://search.luky.org/obu/msg01457.html

colinux 起動用バッチファイル例

echo off

cd E:\app\colinux
E:

colinux-daemon kernel=vmlinux mem=512 root=/dev/cobd0 eth0=tuntap cobd0=debian_cobd0.3gb cobd1=debian_cobd1.3gb

http://web.kyoto-inet.or.jp/people/m-ito/linux/glibcvup.html

.hg/hgrc push_ssl = false allow_push = *

PYTHONPATH じゃなくてハードコードで追加

import sys

sys.path.append('/path/to/python/site-packages')

デフォルトリポジトリの変更方法は???

確認方法 hg showconfig または show でもいいけど

$ pwd /path/to/this_repo $ hg show bundle.mainreporoot=/path/to/this_repo paths.default=/path/to/parent_repo

デフォルトリポジトリ以外から pull するほうほう hg pull [--rev revision_number] file://path/to/repository オプションは引数の最初に書かないとおかしな動作をする。いまいち!

hg init touch a.file hg add a.file hg commit -m 'add file a at default branch.'

hg branch branch_a touch b.file hg add b.file hg commit -m 'add file b at branch_a.'

hg update -C default touch c.file hg add c.file hg commit -m 'add file c at default branch.'

touch d.file hg add d.file hg commit -m 'add file d at default branch.'

$ hg hist changeset: 3:f83fdcd4f75c tag: tip user: user@host date: Fri Jun 13 11:25:52 2008 +0900 summary: add file d at default branch.

changeset: 2:2fde0f18ac36 parent: 0:77ba36783ac3 user: user@host date: Fri Jun 13 11:25:51 2008 +0900 summary: add file c at default branch.

changeset: 1:49b79737e50c branch: branch_a user: user@host date: Fri Jun 13 11:25:51 2008 +0900 summary: add file b at branch_a.

changeset: 0:77ba36783ac3 user: user@host date: Fri Jun 13 11:25:51 2008 +0900 summary: add file a at default branch.

hg update -r 2 touch e.file hg add e.file hg commit -m 'add file e at unnamed branch(parent is default).'

$ hg branches default 4:1bf31e38d364 branch_a 1:49b79737e50c

$ hg heads changeset: 4:1bf31e38d364 tag: tip parent: 2:2fde0f18ac36 user: user@host date: Fri Jun 13 11:25:52 2008 +0900 summary: add file e at unnamed branch(parent is default).

changeset: 3:f83fdcd4f75c user: user@host date: Fri Jun 13 11:25:52 2008 +0900 summary: add file d at default branch.

changeset: 1:49b79737e50c branch: branch_a user: user@host date: Fri Jun 13 11:25:51 2008 +0900 summary: add file b at branch_a.

extensions, hgrc, hgwebdir についても。エクスポートの方法。公開、HTTPデーモン以外でのアクセス制限、標準的なツリーの構成は?

hgweb.config に [collections] a = repos2/ b = repos/ [web] style = gitweb

.hg/hgrc に [web] style = gitweb allow_archive = gz zip bz2

$ hg showconfig
bundle.mainreporoot=/home/username/reponow
paths.default=/home/username/repoparent

Techonのレイヤ

@-moz-document url-prefix(http://techon.nikkeibp.co.jp/) {
  DIV#nocookie { display:none; ! important; }
}

Primary, Secondary の次は?

1 primary 2 secondary 3 tertiary 4 quaternary 5 quinary 6 senary 7 septenary 8 octonary 9 nonary 10 denary 11 12 duodenary ... 20 vigenary

screen で現在実行中のコマンド表示

subversion で俺リポジトリ

.subversion/config に適当に書く

[tunnels]
myssh = $SVN_SSH ssh -p 20022

こまんど

svn+myssh://localhost/home/katsuhiro/share/svn/

俺フォワーディングとあわせてどうぞ

ssh atlas -R20022:localhost:22 -f "bash -c 'while :;do sleep 60;done'"

http://standards.ieee.org/regauth/oui/index.shtml

http://www.fumiswebpage.com/furuya03.htm

JAVAで学ぶ3D

make の自動変数

$@ : ターゲットファイル名
$% : ターゲットがアーカイブメンバだったときのターゲットメンバ名
$< : 最初の依存するファイルの名前
$? : ターゲットより新しいすべての依存するファイル名
$^ : すべての依存するファイルの名前
$+ : Makefileと同じ順番の依存するファイルの名前
$* : サフィックスを除いたターゲットの名前
`$(@D)'
      ターゲットファイル名のディレクトリ部分の末尾のスラッシュを除去したもの。
      `$@'の値が`dir/foo.o'なら`$(@D)'は`dir'になります。`$@'にスラッシュが
      含まれないとこの変数の値は`.'になってしまいます。
`$(@F)'
      ターゲットファイル名のディレクトリ内ファイル部分。`$@'の値が`dir/foo.o'
      なら`$(@F)'は`foo.o'になります。`$(@F)'は`$(notdir $@)'と同等です。
`$(*D)'
`$(*F)'
     語幹のディレクトリ部分とディレクトリ内ファイル部分で、先の例では
     `dir'と`foo'になる。
`$(%D)'
`$(%F)'
     ターゲットアーカイブメンバ名のディレクトリ部分とディレクトリ内ファイル
     部分。`archive (member)'という形式のアーカイブメンバがターゲットの時
     のみ用を成し、member にディレクトリ名が含まれる場合のみ有用です。
     (ターゲットとしてのアーカイブメンバーの項を見て下さい。)
`$(<D)'
`$(<F)'
     最初の依存関係のディレクトリ部分とディレクトリ内ファイル部分。
`$(^D)'
`$(^F)'
     全依存関係のディレクトリ部分とディレクトリ内ファイル部分の各リスト。 
`$(?D)'
`$(?F)'
     依存関係のうちターゲットより新しいもの全てのディレクトリ部分とディレク
     トリ内ファイル部分の各リスト。

info nm

  For each symbol, `nm' shows:

  * The symbol value, in the radix selected by options (see below), or
    hexadecimal by default.

  * The symbol type.  At least the following types are used; others
    are, as well, depending on the object file format.  If lowercase,
    the symbol is local; if uppercase, the symbol is global (external).

   `A'
         The symbol's value is absolute, and will not be changed by
         further linking.

   `B'
         The symbol is in the uninitialized data section (known as
         BSS).

   `C'
         The symbol is common.  Common symbols are uninitialized data.
         When linking, multiple common symbols may appear with the
         same name.  If the symbol is defined anywhere, the common
         symbols are treated as undefined references.  For more
         details on common symbols, see the discussion of -warn-common
         in *Note Linker options: (ld.info)Options.

   `D'
         The symbol is in the initialized data section.

   `G'
         The symbol is in an initialized data section for small
         objects.  Some object file formats permit more efficient
         access to small data objects, such as a global int variable
         as opposed to a large global array.

   `I'
         The symbol is an indirect reference to another symbol.  This
         is a GNU extension to the a.out object file format which is
         rarely used.

   `N'
         The symbol is a debugging symbol.

   `R'
         The symbol is in a read only data section.

   `S'
         The symbol is in an uninitialized data section for small
         objects.

   `T'
         The symbol is in the text (code) section.

   `U'
         The symbol is undefined.

   `V'
         The symbol is a weak object.  When a weak defined symbol is
         linked with a normal defined symbol, the normal defined
         symbol is used with no error.  When a weak undefined symbol
         is linked and the symbol is not defined, the value of the
         weak symbol becomes zero with no error.

   `W'
         The symbol is a weak symbol that has not been specifically
         tagged as a weak object symbol.  When a weak defined symbol
         is linked with a normal defined symbol, the normal defined
         symbol is used with no error.  When a weak undefined symbol
         is linked and the symbol is not defined, the value of the
         symbol is determined in a system-specific manner without
         error.  Uppercase indicates that a default value has been
         specified.

   `-'
         The symbol is a stabs symbol in an a.out object file.  In
         this case, the next values printed are the stabs other field,
         the stabs desc field, and the stab type.  Stabs symbols are
         used to hold debugging information.  For more information,
         see *Note Stabs: (stabs.info)Top.

   `?'
         The symbol type is unknown, or object file format specific.

自分の .screenrc

escape ^t^t

# disable vbell toggle
bind ^G
bind g

# disable screen lock
bind ^X
bind x

# disable xon(send Control-q)
bind q
# disable xoff(send Control-s)
bind s

# bind 'window remove' to x and ^X
bind ^X remove
bind x remove

# bind 'window only' to q
bind q only
# bind 'window split' to s
bind s split

vbell off
defscrollback 1024
defencoding UTF-8
defhstatus "[screen ^En: ^Et]"

autodetach on
startup_message off

caption always "%{=d wk} %-w%{=s wk}%n %t%{-}%+w %= %{=d kg}%y/%m/%d %c"
#hardstatus string "[screen %n: %t] %h"

sorendition 10 99
termcapinfo xterm-color 'hs:ts=\E]0;:fs=\007:ds=\E]0;screen\007'

めも

diff -r 94ee30a65bd1 src/descriptor.h

  1. b/src/descriptor.h Fri Oct 02 12:22:20 2009 +0000 @@ -0,0 +1,17 @@
  1. #ifndef DESCRIPTOR_H__
  2. #define DESCRIPTOR_H__
  3. #include "desc_iso13818.h"
  4. #include "desc_arib_std_b10.h"
  5. union desc {
  6. //iso 13818-1
  7. struct ca_desc ca;
  8. //arib std b10
  9. struct netname_desc netname;
  10. struct vdecctl_desc vdecctl;
  11. struct sysmng_desc sysmng;
  12. };
  13. #endif //#ifndef DESCRIPTOR_H__ diff -r 94ee30a65bd1 src/payload.c
    • a/src/payload.c Sun Sep 06 20:38:53 2009 +0900
    1. b/src/payload.c Fri Oct 02 12:22:20 2009 +0000 @@ -231,8 +231,8 @@
      	//ディスクリプタ配列が変わっていたら更新する
      	changed = 0;
  1. if (cmp_array(str->h.pmth.descs_raw,
  2. pmth.descs_raw,
    			pmth.size_descs) != 0) {
    		changed = 1;
    	}
    @@ -244,8 +244,8 @@
    		    (str->h.pmth.prgs[i].es_info_length != 
    			pmth.prgs[i].es_info_length)) {
    			changed = 1;
  1. } else if (cmp_array(str->h.pmth.prgs[i].descs_raw,
  2. pmth.prgs[i].descs_raw,
    				pmth.prgs[i].size_descs)) {
    			changed = 1;
    		}
    @@ -286,8 +286,8 @@
    		//返り値を pos に足す必要はない
    		dprintf_indent(indent, "-- 1st array of descriptors\n");
    		dump_array(indent, "descriptors", 
  1. str->h.pmth.descs_raw, str->h.pmth.size_descs, 16);
  2. result = descriptors(str->h.pmth.descs_raw, str,
    			str->h.pmth.size_descs, indent + 1);
    		if (result == -1) {
    			dfprintf(stderr, 
    @@ -304,8 +304,9 @@
    		for (i = 0; i < str->h.pmth.num_prgs; i++) {
    			dprintf_indent(indent, "stream[%d]\n", i);
    			dump_pmt_prg(&str->h.pmth.prgs[i], indent + 1);
  1. result = descriptors(str->h.pmth.prgs[i].descs_raw,
  2. str, str->h.pmth.prgs[i].size_descs,
  3. indent + 2);
    			if (result == -1) {
    				dfprintf(stderr, 
    					"[PMT] 2nd descriptors() failed.\n");
    @@ -354,8 +355,8 @@
    	
    	//CAT 内のディスクリプタが変化していたら記録する
    	changed = 0;
  1. if (cmp_array(str->h.cath.descs_raw,
  2. cath.descs_raw,
    			cath.size_descs) != 0) {
    		changed = 1;
    	}
    @@ -371,7 +372,7 @@
    		//CAT を解析した時点でディスクリプタのサイズは 
    		//pos に足されているので
    		//返り値を pos に足す必要はない
  1. result = descriptors(str->h.cath.descs_raw, str,
    			str->h.cath.size_descs, indent + 1);
    		if (result == -1) {
    			dfprintf(stderr, 
    @@ -417,8 +418,8 @@
    	//ディスクリプタ配列が変わっていたら更新する
    	changed = 0;
  1. if (cmp_array(str->h.nith.descs_raw,
  2. nith.descs_raw,
    			nith.size_descs) != 0) {
    		changed = 1;
    	}
    @@ -430,8 +431,8 @@
    		    (str->h.nith.prgs[i].transport_descriptors_length != 
    			nith.prgs[i].transport_descriptors_length)) {
    			changed = 1;
  1. } else if (cmp_array(str->h.nith.prgs[i].descs_raw,
  2. nith.prgs[i].descs_raw,
    				nith.prgs[i].size_descs)) {
    			changed = 1;
    		}
    @@ -450,8 +451,8 @@
    		//返り値を pos に足す必要はない
    		dprintf_indent(indent, "-- 1st array of descriptors\n");
    		dump_array(indent, "descriptors", 
  1. str->h.nith.descs_raw, str->h.nith.size_descs, 16);
  2. result = descriptors(str->h.nith.descs_raw, str,
    			str->h.nith.size_descs, indent + 1);
    		if (result == -1) {
    			dfprintf(stderr, 
    @@ -468,8 +469,9 @@
    		for (i = 0; i < str->h.nith.num_prgs; i++) {
    			dprintf_indent(indent, "program[%d]\n", i);
    			dump_nit_prg(&str->h.nith.prgs[i], indent + 1);
  1. result = descriptors(str->h.nith.prgs[i].descs_raw,
  2. str, str->h.nith.prgs[i].size_descs,
  3. indent + 2);
    			if (result == -1) {
    				dfprintf(stderr, 
    					"[NIT] 2nd descriptors() failed.\n");
    diff -r 94ee30a65bd1 src/psi.h
    • /dev/null Thu Jan 01 00:00:00 1970 +0000
    1. b/src/psi.h Fri Oct 02 12:22:20 2009 +0000 @@ -0,0 +1,17 @@
  4. #ifndef PSI_H__
  5. #define PSI_H__
  6. #include "psi_iso13818.h"
  7. #include "psi_arib_std_b10.h"
  8. union psi_header {
  9. //iso 13818-1
  10. struct pat_header path;
  11. struct pmt_header pmth;
  12. struct cat_header cath;
  13. //arib std b10
  14. struct nit_header nith;
  15. };
  16. #endif //#ifndef PSI_H__ diff -r 94ee30a65bd1 src/psi_arib_std_b10.c
    • a/src/psi_arib_std_b10.c Sun Sep 06 20:38:53 2009 +0900
    1. b/src/psi_arib_std_b10.c Fri Oct 02 12:22:20 2009 +0000 @@ -32,14 +32,14 @@
      	//サイズを表している。
      	//一つめのディスクリプタ配列を読む
      	size = d->network_descriptors_length;
  1. if (size < 0 || (int)sizeof(d->descs_raw) < size) {
    		dfprintf(stderr, "[NIT] NIT 1st descriptors has "
    			"illegal size(size:%d, array:%d) seclen:%d\n", 
  1. size, (int)sizeof(d->descs_raw),
    			d->h.section_length);
    		return -1;
    	}
  1. memmove(d->descs_raw, &packet[pos], size);
    	d->size_descs = size;
    	
    	pos += size;
    @@ -115,13 +115,13 @@
    	//transport_descriptors_length はディスクリプタのサイズを表している
    	//ディスクリプタ配列を読む
    	size = d->transport_descriptors_length;
  1. if (size < 0 || (int)sizeof(d->descs_raw) < size) {
    		dfprintf(stderr, "[NIT] one of 2nd descriptors has "
    			"illegal size(size:%d, array:%d)\n", 
  1. size, (int)sizeof(d->descs_raw));
    		return -1;
    	}
  1. memmove(d->descs_raw, &packet[pos], size);
    	d->size_descs = size;
    	
    	pos += size;
    @@ -153,7 +153,7 @@
    	/*
    	result += dprintf_indent(indent, "1st array of descriptors\n");
    	result += dump_array(indent, "descriptors", 
  1. d->descs_raw, d->size_descs, 16);
    	
    	result += dprintf_indent(indent, DPRINT_FMT_MEMBER "%d\n", 
    		"transport_stream_loop_length", 
    @@ -187,7 +187,7 @@
    		"transport_descriptors_length", 
    		d->transport_descriptors_length);
    	result += dump_array(indent, "descriptors", 
  1. d->descs_raw, d->size_descs, 16);
    	
    	return result;
    }
    diff -r 94ee30a65bd1 src/psi_arib_std_b10.h
    • a/src/psi_arib_std_b10.h Sun Sep 06 20:38:53 2009 +0900
    1. b/src/psi_arib_std_b10.h Fri Oct 02 12:22:20 2009 +0000 @@ -8,6 +8,7 @@
      #include "common.h"
      #include "ts.h"
  2. #include "descriptor.h"
    //NIT
    struct nit_prg {
    @@ -18,8 +19,10 @@
    	
    	//section_length < 1021 より 1011 だが
    	//メモリを食い過ぎるので減らしている
  1. unsigned char descs_raw[128];
    	int size_descs;
  2. union desc descs[8];
  3. int num_descs;
    };
    
    struct nit_header {
    @@ -35,8 +38,10 @@
    	
    	//section_length < 1021 より 1011 だが
    	//メモリを食い過ぎるので減らしている
  1. unsigned char descs_raw[128];
    	int size_descs;
  2. union desc descs[16];
  3. int num_descs;
    	
    	unsigned char reserved4;
    	unsigned short transport_stream_loop_length;
    diff -r 94ee30a65bd1 src/psi_iso13818.c
    • a/src/psi_iso13818.c Sun Sep 06 20:38:53 2009 +0900
    1. b/src/psi_iso13818.c Fri Oct 02 12:22:20 2009 +0000 @@ -142,14 +142,14 @@
      	//サイズを表している。
      	//一つめのディスクリプタ配列を読む
      	size = d->program_info_length;
  1. if (size < 0 || (int)sizeof(d->descs_raw) < size) {
    		dfprintf(stderr, "[PMT] PMT 1st descriptors has "
    			"illegal size(size:%d, array:%d) seclen:%d\n", 
  1. size, (int)sizeof(d->descs_raw),
    			d->h.section_length);
    		return -1;
    	}
  1. memmove(d->descs_raw, &packet[pos], size);
    	d->size_descs = size;
    	
    	pos += size;
    @@ -224,13 +224,13 @@
    	//es_info_length はディスクリプタのサイズを表している
    	//一つめのディスクリプタ配列を読む
    	if (d->es_info_length < 0 || 
  1. sizeof(d->descs_raw) < d->es_info_length) {
    		dfprintf(stderr, "[PMT] one of 2nd descriptors has "
    			"illegal size(size:%d, array:%d)\n", 
  1. d->es_info_length, (int)sizeof(d->descs_raw));
    		return -1;
    	}
  1. memmove(d->descs_raw, &packet[pos], d->es_info_length);
    	d->size_descs = d->es_info_length;
    	
    	pos += d->es_info_length;
    @@ -263,7 +263,7 @@
    	/*
    	result += dprintf_indent(indent, "-- 1st array of descriptors\n");
    	result += dump_array(indent, "descriptors", 
  1. d->descs_raw, d->size_descs, 16);
    	
    	result += dprintf_indent(indent, "-- 2nd array of descriptors\n");
    	result += dprintf_indent(indent, DPRINT_FMT_MEMBER "%d\n", 
    @@ -293,7 +293,7 @@
    	result += dprintf_indent(indent, DPRINT_FMT_MEMBER "%d\n", 
    		"es_info_length", d->es_info_length);
    	result += dump_array(indent, "descriptors", 
  1. d->descs_raw, d->size_descs, 16);
    	
    	return result;
    }
    @@ -329,14 +329,14 @@
    	// -5: section_length 以降のメンバ(transport_stream_id など)の分
    	// -4: CRC32 の分
    	size = d->h.section_length - 5 - 4;
  1. if (size < 0 || (int)sizeof(d->descs_raw) < size) {
    		dfprintf(stderr, "[CAT] CAT has illegal descriptor size"
    			"(size:%d, array:%d) seclen:%d\n", 
  1. size, (int)sizeof(d->descs_raw),
    			d->h.section_length);
    		return -1;
    	}
  1. memmove(d->descs_raw, &packet[pos], size);
    	d->size_descs = size;
    	
    	pos += size;
    @@ -365,7 +365,7 @@
    	result += dprintf_indent(indent, DPRINT_FMT_MEMBER "%d\n", 
    		"last_section_number", d->last_section_number);
    	result += dump_array(indent, "descriptors", 
  1. d->descs_raw, d->size_descs, 16);
    	result += dprintf_indent(indent, DPRINT_FMT_MEMBER "0x%08x\n", 
    		"crc32", d->crc32);
    	
    diff -r 94ee30a65bd1 src/psi_iso13818.h
    • a/src/psi_iso13818.h Sun Sep 06 20:38:53 2009 +0900
    1. b/src/psi_iso13818.h Fri Oct 02 12:22:20 2009 +0000 @@ -8,6 +8,7 @@
      #include "common.h"
      #include "ts.h"
  2. #include "descriptor.h"
    //PAT
    struct pat_prg {
    @@ -46,8 +47,10 @@
    	
    	//section_length < 1024 だが、
    	//メモリを食い過ぎるので減らしている
  1. unsigned char descs_raw[128];
    	int size_descs;
  2. union desc descs[8];
  3. int num_descs;
    };
    
    struct pmt_header {
    @@ -65,8 +68,10 @@
    	
    	//section_length < 1021 だが、
    	//メモリを食い過ぎるので減らしている
  1. unsigned char descs_raw[128];
    	int size_descs;
  2. union desc descs[16];
  3. int num_descs;
    	
    	//section_length < 1021 より 256 だが、
    	//メモリを食い過ぎるので減らしている
    @@ -87,8 +92,10 @@
    	
    	//section_length < 1021 だが、
    	//メモリを食いすぎるので減らしている
  1. unsigned char descs_raw[128];
    	int size_descs;
  2. union desc descs[16];
  3. int num_descs;
    	
    	unsigned long crc32;
    };
    diff -r 94ee30a65bd1 src/reader.h
    • a/src/reader.h Sun Sep 06 20:38:53 2009 +0900
    1. b/src/reader.h Fri Oct 02 12:22:20 2009 +0000 @@ -11,10 +11,8 @@
      #include "vector.h"
      #include "ts.h"
      #include "pes.h"
  1. #include "psi.h"
  2. #include "descriptor.h"
    #define NUM_PROGRESS    5000
    
    @@ -38,12 +36,7 @@
    	
    	struct ts_header tsh;
    	
  1. union psi_header h;
    };
    
    //descriptor.c

*1 always_inline
*2 always_inline

トップ   新規 一覧 検索 最終更新   ヘルプ   最終更新のRSS