星期二, 十二月 19, 2006

可爱的yn妹妹

原来yn妹妹还是很pl的
呵呵
自己一直都没特别注意,就是觉得她是还过得去的那种,和她在一起也完全是因为她的善良,温柔,体贴
呵呵,昨天有人说mm长得pl,好开心啊,我也喜欢我的丫头ppll的
原来自己身边一直都藏着这么个美女都没法现啊

呵呵,还好被我给骗到了(用骗这个词ynmm可不要打我啊)
这几天越来越觉得mm温柔,pl,可爱依人
真是个合格的好lp
衷心祝福ynmm越来越pl
以后一定赚多多的money好给mm
梳妆,打扮
呵呵,其实自己还是很虚荣的啊,我也喜欢自己的mm漂漂亮,
自己也有光啊
就写这么多吧,在写mm揍我了
亲亲mm一个
好梦啊mm

Read More...

毕设

题目下来了,呵呵终于如愿以偿选到了自己喜欢的老师
很开心,昨天就想写了
可是每次来写的时候都有事
所以就只能这时候来写了




Read More...

星期五, 十二月 15, 2006

yn妹妹,辛苦了

这几天事比较多
我的脾气也不是很好
以后要更好的对你
宝贝辛苦了


Read More...

星期六, 十二月 09, 2006

我的桌面

desktop1


desktop2

Read More...

星期四, 十二月 07, 2006

An easier way to update your world

Without doubt, one of Gentoo's best features is its package management system, Portage. Portage makes it very easy to update your entire system with one simple command. Sadly, things don't always go as smooth as they should. Almost every Gentoo user has typed emerge -uD world and gone to bed with the hope of waking up in the morning to a completely up to date system. Unfortunately, it's more likely that you.ll wake up to a failed emerge on package 3 of 220. And so the troubleshoot and emerge --resume process begins.

Enter update-world to save the day. Update-world is a bash script that was recently created by count_zero and posted in the forums. The script controls the update process and forces portage to skip past failed builds and continue compiling packages until the update list is finished. Failed builds are added to a list for review once the update is finished.

Note: The script does depend on the 'equery' command, part of app-portage/gentoolkit.



Obviously before you can start using the script, you'll need to download it, put it somewhere in your path, and make it executable.

Code Listing 3.1: getting the script

# wget -O /usr/bin/update-world http://countzero.amidal.com/files/update-world
# chmod +x /usr/bin/update-world

Now we're ready to start using the script.

Code Listing 3.2: running update-world

# update-world --prepare 

This begins the update process by creating a list of packages to be emerged, as produced by emerge -uD --newuse world. (Alternatively, you can use update-world --empty to create a list of all packages on the system, akin to emerge -e world). This command creates a list called 'emergelist' in ~/.update-world/. Now, you can use your favorite editor to modify this list how you like--remove packages, change versions, etc. When you have the emergelist how you like it, you're ready to move onto the next step:

Code Listing 3.3: running update-world (cont)

# update-world --install 

This command actually starts the build process, just as if you had typed emerge -uD world. The difference is, if a package fails for some reason or another, that package is added to a list 'failedlist' in ~/.update-world/. Also, a link to the portage log file for that package (usually located in /var/log/portage) is created in ~/.update-world/[date]/log/. Once the process is done, you'll be presented with a list of failed packages to take care of all at once, saving much time. If you ever need to stop the process, just hit 'Control-C' to abort the process. The update can then be restarted at any time, just where it left off, by retyping update-world --install.


[code]
#!/bin/bash
# update-world 1.5
# count_zero 2006
# Licensed under the GPLv2
#
# update-world is a bash script that forces an emerge -uD world to continue, even
# in the face of (inevitable) compile failures. Failed builds are added to a list,
# and the script jumps to the next package in the queue.
#
# just run update-world --prepare (or --empty) followed by update-world --install.
#
# Release Notes:
# v1.5: now handles 'fetch restriction' properly
# v1.4: uses '--newuse' for emerges to respect new use flags
# v1.3: uses '--oneshot' for emerges so they don't get added to the world file.
# v1.2: Script now detects log directly instead of accepting only /var/log/portage
# v1.1: minor bugfix to allow package without version to be added to 'emergelist'
# v1.0: Release
#
#
# Set the program directory and important variables
homedir=~/.update-world
workdir="$homedir/`date +%F`"
logdir="$workdir/log"
mkdir -p $logdir
touch $homedir/failedlist
emergelist=$homedir/emergelist
emergetemp=$workdir/emergetemp
failedlist=$homedir/failedlist
portlogdir=`cat /etc/make.conf | grep PORT_LOGDIR | sed 's/PORT_LOGDIR=//' | sed 's/\"//g' | sed 's/\/$//'`
masked=$homedir/masked
# parameter for '--empty' to emerge -e world
if [[ $1 == '--empty' || $1 == '-e' ]]
then parameter='-pev'
else parameter='-puvD --newuse'
fi
#### update-world --prepare ####
# Prepare the list of packages to emerge into emerglist
if [[ $1 == "--prepare" || $1 == "-p" || $1 == '--empty' || $1 == '-e' ]]
then
if [[ -e $emergelist ]]
then echo -n "The file 'emergelist' already exists and will be overwritten.
Continue anyway? (y/n) "
read continue
if [[ $continue == 'y' || $continue == 'yes' || $continue == 'Y' || $continue == 'Yes' || $continue == 'YES' || $continue == '' ]]
then :
else echo exiting.
exit 0
fi
else :
fi
emerge $parameter world | tee $emergelist
# Make sure there are no errors in the emerge process
echo
if grep -q "blocks B " $emergelist
then echo "WARNING: You have a blocking package. Fix this before continuing."
rm -f $emergelist
exit 1
elif grep -q "masked" $emergelist
then echo "WARNING: You need to unmask some packages before continuing."
rm -f $emergelist
exit 1
elif grep -q "emerge: there are no ebuilds to satisfy" $emergelist
then echo "WARNING: One of the specified packages doesn't exist"
rm -f $emergelist
exit 1
elif grep -q 'Fetch Restriction' $emergelist
then fetchrestricted=`cat $emergelist | grep ^[[]ebuild[A-Za-z\ ]*F[A-Za-z\ ]*[]] | grep -o []][a-zA-Z0-9\/.\ -]*[[] | sed 's/\]\ //' | sed 's/\ \[//'`
echo "WARNING: The following packages have Fetch Restriction turned on:
$fetchrestricted

Please download the sources from the location specified in the ebuild to /usr/portage/distfiles/ and rerun this script."
exit 1
else :
fi
echo "
These are the packages that will be installed. If you want to alter this list,
just edit the file 'emergelist' in $homedir. When finished, run
'update-world --install'"
cat $emergelist | sed '/^[TC]/d' | sed 's/\[ebuild.*[ A-Z]\]\ //' | sed '/^[ ]/d' | sed '/^[ ]*$/d' | sed '/Portage\ overlays/d' | sed 's/\ .*$//' | sort -d | sed 's/.*/\=&/' > $emergetemp
mv $emergetemp $emergelist
rm -f $failedlist
exit 0
#### update-world --install ####
# Install the packages listed in emergelist
elif [[ $1 == "--install" || $1 == "-i" ]]
then
# Verify that the emergelist doesn't produce errors
cat $emergelist | xargs emerge -p > $emergetemp
if grep -q "blocks B " $emergetemp
then echo "WARNING: You have a blocking package. Fix this before continuing."
rm -f $emergetemp
exit 1
elif grep -q "masked" $emergelist
then echo "WARNING: You need to unmask some packages before continuing."
rm -f $emergetemp
exit 1
elif grep -q "emerge: there are no ebuilds to satisfy" $emergelist
then echo "WARNING: One of the specified packages doesn't exist"
rm -f $emergetemp
exit 1
elif [[ -z `cat $emergelist` ]]
then echo "WARNING: no 'emergelist' exists. Did you run 'update-world --prepare' first?"
rm -f $emergetemp
exit 1
else :
fi
# Until loop to make portage continue until finished
increment=0
until [[ $increment == 1 ]]
do
cat $emergelist | xargs emerge -1
# Detect which packages have been successfully emerged and remove from the queue
installed=`tac /var/log/emerge.log | sed '/Started\ emerge/,$d' | grep "completed emerge" | sed 's/^.*)\ //' | sed 's/\ to.*//'`
for each in $installed
do
eachsed=`echo $each | sed 's|\/|\\\/|'`
if [[ -z `cat $emergelist | grep $each` ]]
then eachsed=`echo $eachsed | sed 's/\-[0-9].*//'`
else :
fi
cat $emergelist | sed "/$eachsed/d" > $emergetemp
mv $emergetemp $emergelist
done
# See if all packages have been emerged
if [[ -z `cat $emergelist` ]]
then increment=1
else :
fi
if [[ $increment == 0 ]]
then
errorlog=`ls -t $portlogdir | sed '2,$d'`
if [[ -n `cat $portlogdir/$errorlog | grep 'signal 2'` ]]
then echo "
*** User hit 'Control-C' ... exiting.
"
exit 1
else :
fi
sleep 5
echo
echo "*** Hit Control-C to exit, or just wait to continue with emerge."
echo
sleep 10
echo "*** Continuing with emerge."
# Detect failed emerge and add to failedlist, remove failed package from emergelist
failedpkg=`tac /var/log/emerge.log | sed '1d' | sed '/terminating/,$d' | sed '/completed\ emerge/,$d' | grep ">>>" | sed 's/.*)\ //' | sed 's/\ to.*//'`
if [[ -n `tail -n 1 $failedlist | grep $failedpkg` ]]
then echo "The failed package $failedpkg could not be merged and must be successfully installed before continuing."
exit 1
else :
fi
echo $failedpkg >> $failedlist
failedpkgsed=`echo $failedpkg | sed 's|\/|\\\/|'`
cat $emergelist | sed "/$failedpkgsed/d" > $emergetemp
mv $emergetemp $emergelist
ln -s $portlogdir/$errorlog $logdir/${errorlog}_error-log
echo
echo
echo "*** $failedpkg compile failed, skipping."
# Is there a package in 'emergelist' that requires the failed pkg as a dep? If so, remove it too.
failedpkgdeps=`echo $failedpkg | sed 's/-[0-9].*//'`
deps=`equery depends $failedpkgdeps | sed '/^\[/d' | sed 's/-[0-9].*//'`
for each in `echo $deps`
do
if [[ -n `cat $emergelist | grep "$each"` ]]
then
if [[ -n `emerge -p $each | grep "$failedpkg"` ]]
then
each2=`cat $emergelist | grep $each | sed 's/\=//'`
echo "$each2 (depends on $failedpkg)" >> $failedlist
eachsed=`echo $each | sed 's|\/|\\\/|'`
cat $emergelist | sed "/$eachsed/d" > $emergetemp
mv $emergetemp $emergelist
echo "*** $each depends on $failedpkg, skipping."
else :
fi
else :
fi
done
echo "*** Continuing with emerge world"
else :
fi
done
# if improper argument is given to 'update-world' display the help text
else echo "update-world 1.0
count_zero 2006
licensed under the GPLv2

Description:
This is a bash script to automate the 'emerge -uD world' process.
Its purpose is to make updating the system as hands-free as possible.
It does this by automatically recovering from a failed emerge and moving
on to the next one, presenting the user with a list of failed packages
once the update has finished. No more 'babysitting' the update process!
Just start it, and deal with any failed packages at the end. Log files
from the failed emerges are saved in the log directory.

The default program directory is ~/.update-world

Usage:
update-world [--prepare | -p ]
Prepares a list of packages produced by 'emerge -puvD world'
and outputs them to the file 'emergelist' in the current directory.
Add, remove, or change the version of any of the packages listed
in this file with your favorite editor before continuing.
update-world [--empty | -e ]
Same as --prepare except it performs 'emerge -ev world' to recompile
all packages on a system.
update-world [--install | -i ]
Begins the emerge process based upon the 'emergelist' file created
from running 'update-world --prepare'. Once finished, failed builds
will be saved in the file 'failedlist' in the current directory."
exit 1
fi


echo "Congratulations! 'emerge world' complete."
echo
# All done! display the failed packages, if any
if [[ -z `cat $failedlist` ]]
then echo "All packages emerged successfully"
else echo "These packages couldn't be merged due to compile errors:"
echo
cat $failedlist
echo
echo "Look in $logdir/ for the portage log files of the failed builds.
Check bugs.gentoo.org or the Gentoo Forums for help."
fi
exit 0
[/code]

Read More...

星期二, 十二月 05, 2006

HOWTO Compile Kernel

安装内核源代码

代码: 安装内核源代码
$ USE=symlink emerge gentoo-sources

使用symlink的目的是建立符号连接/usr/src/linux,以指向安装好的内核源代码目录。

警告: 目前使用上面的命令装的是2.6内核,下面的命令也适用于2.6内核,但不一定适用于2.4内核。不过现在没有必要再用2.4内核。特别是在目前glibc 2.4已经稳定了的情况下,已经根本无法再用2.4内核。

配置

配置内核对于新手来说是一个噩梦。不过事实上,配置过程要远比一般人想象的容易。只是有些技巧了解的人不多。

配置命令介绍

make defconfig

非交互式命令,作用是生成一个缺省的配置文件。这个配置文件里各内核组件基本完整,只需修改硬件和文件系统即可。仅在第一次配置时使用。

make menuconfig

最通用的配置方式。它的运行几乎不限环境,远程登录也可以用它配置,所以我们重点介绍。

交互式命令。用法如下:

  • 方向键选择菜单项/按钮
  • 回车进入子菜单
  • 按高亮字母直接选择相应菜单项
  • Y键包含,N键排除,M键配置成模块
  • 退出,?键查看当前菜单项帮助信息,/键搜索
  • 图例:[*] 包含 [ ] 排除 模块 < > 可配置成模块

make oldconfig

交互式命令。利用已有的.config来生成新的.config。如果遇到新内核新增的选项,会挨个提示你是否启用。建议选择默认,即直接按回车。同时记录下有疑问的选项,以便下面再make menuconfig手工配置。仅在升级配置时使用。


第一次配置

代码: 第一次配置
$ cd /usr/src/linux
$ make defconfig
$ make menuconfig

make menuconfig这一步就是要修改硬件和文件配置。可能需要改动的主要有这么几个部分,分别是

  • CPU类型(默认是CONFIG_MK7)
  • IDE驱动(CONFIG_BLK_DEV_VIA82CXXX)
  • 网卡(CONFIG_E100)
  • AGP(CONFIG_AGP_VIA)
  • DRM(CONFIG_DRM_RADEON,建议不要启用,使用portage里的x11-drm)
  • Framebuffer(CONFIG_FB_RADEON)
  • 声卡(CONFIG_SND_VIA82XX)
  • 文件系统(只有CONFIG_EXT2_FS/CONFIG_[V]FAT_FS,ext3/reiserfs/xfs/jfs均未设置)
  • NLS CODEPAGE(需手工增加CONFIG_NLS_CODEPAGE_936)

以上括号里是默认配置情况。虽然不知道这是谁的配置,不过可以看出这个人的CPU是AMD的,主板是VIA的,显卡是ATI Radeon,只用ext2/fat32文件系统,且不是中文用户。

注意: 善用make menuconfig的搜索功能来搜索某选项(CONFIG_...)相关的菜单项的位置。如果你需要使用内核的其他功能,请参阅相关的官方文档或wiki,一般这样的文章里都有内核配置相关章节。如果实在不知道应该配置哪个选项,可以利用Linux内核配置档案

升级时配置

代码: 升级时配置
$ cd /usr/src/linux
$ cp /boot/config .config
$ make oldconfig
$ make menuconfig[可选]

编译和安装

代码: 编译和安装
$ make
$ make modules_install
$ make install
注意: make install时如已有同名文件,原文件会被改名,文件名后会添加一个.old。如果确认不需要保留这些旧文件,可以自行删除。

Read More...

星期一, 十二月 04, 2006

宝贝计划6号完美实施

宝贝计划归来
心里很高兴,非常感谢yn带给我的快乐
可是yn今晚牙不知道怎么回事
又开始疼了
真让人心里疼啊
yn快点好起来吧
我还等着你好起来一起自习呢



Read More...

星期五, 十二月 01, 2006

Internet Explorer 7 RC1 绕WGA的正确安装方法

Internet Explorer新闻主题Update:更新安装方法,成功安装.
利 用破解文件安装IE7 RC1的部分用户报告其系统出现故障,其故障出现在系统启动时提示normaliz.dll无法找到,初步估计是WGA破解有问题,cnBeta提供了一 份normaliz.dll供用户紧急处理,只要将该dll用各种方法复制到Windows XP的system32目录就可以解决.安装完毕后会没有Tab,但执行Update目录下的xmllitesetup.exe更新一下就可以了.




下载:normaliz.dll
下载:Internet Explorer 7 RC1 的WGA破解

1.先把IE 7 RC1的安装文件用WinRAR解开.
2.将破解iecustom.dll放进Update目录,覆盖原有文件.
3.执行update.exe安装
4.复制下载来的normaliz.dll到Windows的System32目录(必须执行,否则系统将故障)
5.重新启动.
6.执行Update目录下的xmllitesetup.exe更新一下就可以了

Read More...