Gentoo更新到3.12.6内核后,重编译所有包,打开rox-2.10错误: ERROR from /usr/lib64/rox/ROX-Filer/AppRun: I cannot find an executable binary. Trying to compile... 解决办法: 下载patch:https://464246.bugs.gentoo.org/attachment.cgi?id=367872 #patch patch --backup-if-mismatch /usr/portage/rox-base/rox/rox-2.10.ebuild *.patch #ebuild /usr/portage/rox-base/rox/rox-2.10.ebuild digest 重编译rox emerge -avt rox 附patch代码: --- rox-2.10.ebuild 2014-01-14 22:27:47.000000000 -0500 +++ rox-2.10-r1.ebuild 2014-01-14 21:14:02.000000000 -0500 @@ -1,9 +1,9 @@ -# Copyright 1999-2012 Gentoo Foundation +# Copyright 1999-2013 Gentoo Foundation […]
虽说windows能做的事,Linux都能做且能做得更好,但是在文档处理方面,即使有open-office、group-office、libreOffice等类MS-Office软件,在界面与功能方面,却是差强人意。楼主闲来无事,百度之下,偶得一篇WPS安装文档,后发现基于QT与WEBQQ3.0协议开发的qtqq,前者在amd64、gentoo-sources-3.8.13、openbox中测试成功,虽手感不及windows版本,却也应有尽有,由于楼主水平有限,尚在积极研究中,知情者不妨留言讨论。 a. 安装layman # emerge -avt layman b. 修改环境变量 # vi /var/lib/layman/make.conf 添加以下两行: PORTDIR_OVERLAY=" $PORTDIR_OVERLAY" # vi /etc/portage/make.conf 添加以下两行: source /var/lib/layman/make.conf PORTDIR_OVERLAY="${PORTDIR} ${PORTDIR_OVERLAY}" c. 添加 gentoo-zh overlay # layman -f -a gentoo-zh d. 修改包关键字 # echo "app-office/wps-office ~amd64" >> /etc/portage/package.keywords e. 安装WPS及QQ # emerge -avt wps-office qtqq
前言:且抄且改进。 #!/bin/bash # # unset ANSWER NAME DIR echo -n "Record or not? [y/n]:" read ANSWER while [[ $ANSWER != 'y' && $ANSWER != 'n' ]] do echo "What you have entered is neither 'y' or 'n', Please enter again:" read ANSWER done if [ $ANSWER = 'y' ]; then echo -n "Please enter the name:" read NAME [ -z $NAME ] && NAME=`date +%Y%m%d%H%M` && echo "Got Nothing! Use the default ($NAME)." echo -n "Please enter the directory to store these files:" read DIR [ -z $DIR ] && DIR="/var/log/script" && echo "Got Nothing! Use the default ($DIR)." [ -z ${DIR##*/} ] && DIR="${DIR%/*}" [ -d $DIR ] || mkdir $DIR exec /usr/bin/script -t 2>$DIR/$NAME.time -a -f $DIR/$NAME.log echo "$?" [ $? -eq 0 ] || echo "error!!!" && exit 127 else echo "Thank you!" fi unset ANSWER NAME DIR 退出shell记录: $exit 回放记录(替换时间和日志文件): $ scriptreplay TIME.time LOG.log 查看记录: $more LOG.log
自娱自乐,旨在记录,以便日后查阅,高手请路过。 #!/bin/bash FULL=`cat /proc/acpi/battery/BAT0/info | grep full | cut -c 26-30` PRESENT=`cat /proc/acpi/battery/BAT0/state | grep remaining | cut -c 26-30` # STATE=`expr $PRESENT / $FULL` STATE=`echo "scale=2;$PRESENT / $FULL * 100" | bc | cut -d . -f 1` AC=`cat /proc/acpi/ac_adapter/ADP1/state | cut -c 26-28` if [ $STATE -le 7 -a $AC = off ]; […]
1、分区准备 # mkdir /boot/efi 用parted或者gdisk工具,分出标识为EFI且大小为200-500MB,格式为fat32的分区 # parted /dev/sda # mkpart EFI fat32 0mb 500mb # set 1 boot on 格式化/dev/sda1 mkfs.vfat -F 32 /dev/sda1 将挂载信息写入fstab echo "/dev/sda1 /boot/efi vfat noauto,noatime 1 2" >> /etc/fstab 2、安装grub2 添加grub2关键字 # echo "sys-boot/grub ~amd64" >> /etc/portage/package.keywords 编译grub2 # emerge -avt grub 3、制作EFI引导U盘 用gdisk或者parted工具分出大于200MB小于500M且标识为EFI的分区,假设为/dev/sdb1 # parted /dev/sdb >> mkpart EFI fat32 0mb 500mb […]