1. make pdflatex.fmt
pdftex -ini -fmt=pdflatex.fmt latex.ltx
2. install AucTeX for emacs
./configure --prefix=/home/cps536-n1.07/elisp # install package
--with-lispdir=/home/cps536-n1.07/elisp # install auctex.el
--with-texmf-dir=/home/cps536-n1.07/texmf-local/ # put config in texmf
make; make install
note: if pdflatex is not working, to compile auctex, just open $auctex-install-dir/preview/latex/Makefile.in, and delete lines that test pdflatex.
3. make TAGS of linux kernel with i386 platform, under emacs
cd $Linux-kernel-dir;Useful hot keys:
find include/linux/ fs/ init/ ipc/ kernel/ lib/ mm/ net/ arch/i386/ -type f -iregex .*\.[csh] -exec etags -a '{}' -o kernel-TAGS \;
- M-. tag
- Find first definition of tag (
find-tag
). - C-u M-.
- Find next alternate definition of last tag specified.
- C-u - M-.
- Go back to previous tag found.
- C-M-. pattern
- Find a tag whose name matches pattern (
find-tag-regexp
). - C-u C-M-.
- Find the next tag whose name matches the last pattern used.
- C-x 4 . tag
- Find first definition of tag, but display it in another window
- (
find-tag-other-window
). - C-x 5 . tag
- Find first definition of tag, and create a new frame to select the
- buffer (
find-tag-other-frame
). - M-*
- Pop back to where you previously invoked M-. and friends.
__init tells GCC to put the function in a special section. These functions are
only used during booting, and are removed from memory after boot (see the
"Freeing unused kernel memory: 200k freed" or similar boot message.
5. Funny. If adding "exec bash" in .cshrc, I cannot login to OpenWindows, while change it to "bash", everything is OK. Still wonder when it executes .cshrc.
6. read entire file using c:
fseek(input, 0L, SEEK_END); /* Position to end of file */
lFileLen = ftell(input); /* Get file length */
rewind(input); /* Back to start of file */
fread(str, lFileLen, 1, input);
No comments:
Post a Comment