From: Mike Frysinger Date: Sun, 2 Nov 2008 11:52:06 +0000 (-0500) Subject: import vapier X-Git-Url: https://git.wh0rd.org/?p=home.git;a=commitdiff_plain;h=1afdf944dcef65ad2bab01e5a07756da28024503 import vapier --- diff --git a/.Eterm/Eterm/user.cfg b/.Eterm/Eterm/user.cfg new file mode 100644 index 0000000..abd4c29 --- /dev/null +++ b/.Eterm/Eterm/user.cfg @@ -0,0 +1,31 @@ + +%include /usr/share/Eterm/themes/Eterm/user.cfg +%include /usr/share/enlightenment/themes/aqua/Eterm/Eterm.cfg + +begin color + cursor green +end color + +begin attributes + scrollbar_type motif + scrollbar_width 13 +end attributes + +begin imageclasses + begin image + type background + mode trans + cmod image 50 + end image +end imageclasses + +begin toggles + home_on_output 0 + itrans 0 + login_shell 0 +end toggles + +begin misc + save_lines 10000 + cut_chars "\t\\\`\\\"\'&() *,;:<=>?@[]{|}ยท" +end misc diff --git a/.Xmodmap b/.Xmodmap index 3504ff4..e500693 100644 --- a/.Xmodmap +++ b/.Xmodmap @@ -29,3 +29,6 @@ keycode 24 = q Q egrave Egrave keycode 174 = XF86AudioLowerVolume keycode 176 = XF86AudioRaiseVolume keycode 160 = XF86AudioMute + +!Rebind Pause to Break +!keycode 110 = Break diff --git a/.aspell.en.pws b/.aspell.en.pws index 80a0f3c..e57cb94 100644 --- a/.aspell.en.pws +++ b/.aspell.en.pws @@ -1,15 +1,27 @@ -personal_ws-1.1 en 14 -KSpell -KHTML -KOrganizer +personal_ws-1.1 en 26 Blackfin -KIO +CVS +ebuild +ebuilds +Eclass +eclasses +Frysinger +gentoo +Gentoo glep -KMail +HOWTO +imho +IUSE +KAddressBook +KHTML +KIO KJS +KMail +Konqueror Kontact +KOrganizer +KSpell Qt -Konqueror -gentoo -KAddressBook -imho +smriti +toolchain +UART diff --git a/.bash_profile b/.bash_profile index 3f56aa0..123d6e6 100644 --- a/.bash_profile +++ b/.bash_profile @@ -1 +1,4 @@ +if type -P keychain >/dev/null ; then + keychain -q $(find ~/.ssh/ -type f '(' -name 'id_*' -a '!' -name '*.pub' ')') +fi [[ -f ~/.bashrc ]] && . ~/.bashrc diff --git a/.bashrc b/.bashrc index 858c3d6..bb72b0b 100644 --- a/.bashrc +++ b/.bashrc @@ -2,10 +2,15 @@ for sh in ~/.profile.d/*.sh ; do . "$sh" done -export JTAG_PROMPT='jtag> ' +export PATH=/usr/lib/ccache/bin:/sbin:/usr/sbin:${PATH}:/usr/games/bin -export PATH=/sbin:/usr/sbin:${PATH} -export EDITOR=/bin/nano +export ECHANGELOG_USER="Mike Frysinger " +export GCC_BOUNDS_OPTS=-no-message +export JTAG_PROMPT='jtag> ' +export HISTFILESIZE=10000 +export HISTSIZE=${HISTFILESIZE} +export LESS="-R --tabs=4 -M -#10" +export LESSCOLOR=0 eval `dircolors` diff --git a/.bin/bugz b/.bin/bugz new file mode 100755 index 0000000..b1ca07a --- /dev/null +++ b/.bin/bugz @@ -0,0 +1,5 @@ +#!/bin/sh -e +cd /usr/local/src/pybugz +export PYTHONPATH=$PWD +cd bugz +exec ../bin/bugz "$@" diff --git a/.bin/ebuild-bump b/.bin/ebuild-bump new file mode 100755 index 0000000..8288e0e --- /dev/null +++ b/.bin/ebuild-bump @@ -0,0 +1,38 @@ +#!/bin/bash + +source ~/.bash_common + +cmd="" +case $1 in + -u|--unpack) cmd="unpack";; + -*) echo "error: uknown option $1"; exit 1;; +esac + +src=${1%.ebuild}.ebuild ; shift +dst=${1%.ebuild}.ebuild ; shift + +set -e + +if [[ ! -e $src ]] ; then + echo "source ebuild not found '$src'" 1>&2 + exit 1 +fi + +cp $src $dst + +case $cmd in + u|unpack) commands="clean setup unpack" ;; + *) commands="manifest clean setup unpack compile install" ;; +esac + +ekeyword ~all $dst + +ebuild $dst $commands + +cvs add $dst + +if [[ -z $* ]] ; then + er 'Version bump.' +else + er "Version bump $*." +fi diff --git a/.bin/git-format-request-pull b/.bin/git-format-request-pull new file mode 100755 index 0000000..7c4f3a6 --- /dev/null +++ b/.bin/git-format-request-pull @@ -0,0 +1,38 @@ +#!/bin/bash + +usage() { + echo "Usage: git-request-pull-send-email [branch]" + exit ${1:-0} +} + +while [[ -n $1 ]] ; do + case $1 in + -h|--help) usage;; + --) shift; break;; + -*) usage 1;; + *) break; + esac + shift +done + +commit=$1 +url=$(git config --get remote.origin.url) +branch=${2:-master} + +if [[ -z ${commit} ]] || [[ -n $3 ]] ; then + usage 1 +fi + +name=$(git config --get user.name) +email=$(git config --get user.email) +cat << EOF +From: ${name} <${email}> +Date: $(date -R) +Subject: Pull request ${url##*/} + +$(git request-pull ${commit} ${url} ${branch}) +EOF + +echo git send-email \ + --to \"$(git config --get sendemail.pullrequest)\" \ + --cc \"$(git config --get sendemail.to)\" ... 1>&2 diff --git a/.cvsrc b/.cvsrc index 6006502..917acb9 100644 --- a/.cvsrc +++ b/.cvsrc @@ -1,4 +1,5 @@ cvs -q -z2 diff -uNp -#checkout -P +checkout -P update -Pd +#log -N diff --git a/.gitconfig b/.gitconfig index 6cdd6a2..820f8f1 100644 --- a/.gitconfig +++ b/.gitconfig @@ -2,6 +2,7 @@ name = Mike Frysinger email = vapier@gentoo.org [color] + ui = auto diff = auto status = auto [color "diff"] diff --git a/.gitignore b/.gitignore index 0edcab9..f884869 100644 --- a/.gitignore +++ b/.gitignore @@ -6,9 +6,11 @@ a.out # Session files +/.bugz_cookie /.dbus/session-bus/ /.DCOPserver_* /.ICEauthority +/.pulse-cookie /.Xauthority /.xsession-errors* @@ -28,20 +30,15 @@ a.out /.nano_history /.php_history /.recently-used* +/.sh_history /.tgdb/a2_tgdb_debug.txt /.tgdb/tgdb_log.txt /.viminfo /.wireshark/recent /minicom.log -/test.awk -/test.c -/test.cpp -/test.i -/test.php -/test.s -/test.S -/test.sh +/test +/test.* # xilinx junk /.Xilinx/ @@ -52,11 +49,13 @@ a.out /.adobe/Flash_Player/AssetCache/ /.cache/ /.ccache/ +/.cddb/ /.clive/cache /.cvsps/ /.dvdcss/ -/.fontconfig/*.cache-2 +/.fontconfig/*.cache-* /.mcop* +/.revdep-rebuild.* /.thumbnails/ /.xchat2/scrollback/ @@ -77,6 +76,7 @@ a.out /.mozilla/ /.mplayer/ /.profile.d/custom.sh +/.subversion/auth/ /.subversion/README.txt /.Skype/ /.ooo3/ @@ -85,6 +85,7 @@ a.out /.xine/ /.xscreensaver +/.gnupg/.#lk* /.gnupg/*.gpg /.gnupg/*.kbx diff --git a/.gnupg/gpg-agent.conf b/.gnupg/gpg-agent.conf new file mode 100644 index 0000000..b9b1afb --- /dev/null +++ b/.gnupg/gpg-agent.conf @@ -0,0 +1,14 @@ +pinentry-program /usr/bin/pinentry-dynamic +no-grab +# GPGConf disabled this option here at Wed Sep 1 00:04:01 2004 EDT +default-cache-ttl 604800 +max-cache-ttl 1209600 + +###+++--- GPGConf ---+++### +debug-level basic +log-file socket:///root/.gnupg/log-socket +default-cache-ttl 999999 +###+++--- GPGConf ---+++### Thu Sep 2 09:27:52 2004 EDT +# GPGConf edited this configuration file. +# It will disable options before this marked block, but it will +# never change anything below these lines. diff --git a/.gnupg/gpg.conf b/.gnupg/gpg.conf index 16fc52f..2a9cf10 100644 --- a/.gnupg/gpg.conf +++ b/.gnupg/gpg.conf @@ -21,12 +21,12 @@ # Uncomment the following option to get rid of the copyright notice -#no-greeting +no-greeting # If you have more than 1 secret key in your keyring, you may want to # uncomment the following option and set your preferred keyid. -#default-key 621CC013 +#default-key E837F581 # If you do not pass a recipient to gpg, it will ask for one. Using # this option you can encrypt to a default key. Key validation will @@ -117,7 +117,9 @@ # servers. keyserver hkp://subkeys.pgp.net +#keyserver hkp://wwwkeys.eu.pgp.net #keyserver mailto:pgp-public-keys@keys.nl.pgp.net +#keyserver ldap://pgp.surfnet.nl:11370 #keyserver ldap://keyserver.pgp.com # Common options for keyserver functions: @@ -152,7 +154,11 @@ keyserver hkp://subkeys.pgp.net # no-include-attributes = do not include attribute IDs (aka "photo IDs") # when sending keys to the keyserver. -#keyserver-options auto-key-retrieve +keyserver-options timeout=3 +keyserver-options auto-key-retrieve +keyserver-options verbose +keyserver-options verbose +keyserver-options verbose # Display photo user IDs in key listings @@ -200,7 +206,7 @@ keyserver hkp://subkeys.pgp.net # at ftp.gnupg.org/gcrypt/alpha/aegypten/). To make use of the agent, # you have to run an agent as daemon and use the option # -# use-agent +use-agent # # which tries to use the agent but will fallback to the regular mode # if there is a problem connecting to the agent. The normal way to @@ -236,3 +242,5 @@ keyserver hkp://subkeys.pgp.net # # Try CERT, then PKA, then LDAP, then hkp://subkeys.net: #auto-key-locate cert pka ldap hkp://subkeys.pgp.net + +utf8-strings diff --git a/.nanorc b/.nanorc index fb8a658..9846a3c 100644 --- a/.nanorc +++ b/.nanorc @@ -1,4 +1,3 @@ -set nowrap set const set fill -2 set historylog @@ -6,6 +5,7 @@ set morespace set multibuffer set noconvert set nohelp +set nowrap # set regexp set smarthome set smooth diff --git a/.profile.d/LANG.sh b/.profile.d/LANG.sh deleted file mode 100644 index 2480a1c..0000000 --- a/.profile.d/LANG.sh +++ /dev/null @@ -1,4 +0,0 @@ -case ${TERM} in - Eterm) export LANG=en_US;; - *) export LANG=en_US.UTF8;; -esac diff --git a/.profile.d/aliases.gentoo.sh b/.profile.d/aliases.gentoo.sh new file mode 100644 index 0000000..179976b --- /dev/null +++ b/.profile.d/aliases.gentoo.sh @@ -0,0 +1,159 @@ +cvs_gentoo_url() { +_cvs_gentoo_url() { + if [[ -n $2 ]] ; then + echo "Usage: cvs_gentoo_url [:rev1[:rev2]]" + return 1 + fi + + # spec has the form file:rev1[:rev2] + # rev2 defaults to rev1-1 + export IFS=: + set -- $1 + unset IFS + + local file=$1 + if [[ ! -e ${file} ]] ; then + echo "file '${file}' does not exist" + return 1 + fi + local dir="." + [[ ${file} == */* ]] && dir=${file%/*} + file=${file##*/} + + local rev2=$2 + if [[ -z ${rev2} ]] ; then + rev2=$( + cd ${dir} + export IFS=/ + set -- $(grep /${file}/ CVS/Entries) + unset IFS + echo $3 + ) + if [[ ${rev2} == "0" ]] ; then + # new file + rev2="1.1" + else + # existing file, bump rev automatically + rev2="1.$((${rev2#1.}+1))" + fi + fi + local rev2r=${rev2#1.} + local rev1=${3:-1.$((rev2r - 1))} + + local cvsroot=$(<${dir}/CVS/Repository) + if [[ ${cvsroot} == gentoo-x86* ]] ; then + cvsroot=${cvsroot#gentoo-x86} + cvsroot=${cvsroot#/} + fi + + local urirev + [[ ${rev2} == "1.1" || ${rev1} == "${rev2}" ]] \ + && urirev="?rev=${rev2}" \ + || urirev="?r1=${rev1}&r2=${rev2}" + echo "http://sources.gentoo.org/${cvsroot}/${file}${urirev}" +} + local f + for f in "$@" ; do + _cvs_gentoo_url "${f}" + done + unset _cvs_gentoo_url +} + + +er() { + [[ ! -e ChangeLog ]] \ + && echo "No ChangeLog" \ + && return 1 + echangelog "$@" || return 1 + repoman commit -m "$@" || return 1 +} +att() { + declare url=$1 tmp=$(mktemp) filename || return 1 + [[ $url == */* ]] || url="http://bugs.gentoo.org/attachment.cgi?id=$url" + eval $(wget -S -O"$tmp" "$url" 2>&1 | tee /dev/tty | \ + grep 'Content-disposition:' | sed 's/.* //') && \ + mv "$tmp" "$filename" && \ + chmod $(printf "%03o" "$((0666 & ~$(umask)))") "$filename" && \ + ls -l "$filename" && \ + return 0 + rm -f "$tmp" + return 1 +} +arch_emails() { + local a ret="" + if [[ $@ == *.ebuild* ]] ; then + local e keys + for e in "$@" ; do + keys=$(sed -n '/^KEYWORD/{s:.*=::;s:"::g;p}' ${e}) + for a in ${keys} ; do + [[ ${a} != ~* ]] && continue + ret="${ret} ${a/\~}@gentoo.org" + done + done + else + for a in "$@" ; do + ret="${ret} ${a/\~}@gentoo.org" + done + fi + echo ${ret} +} +submit_bug_stable() { + local msg="doit" + if [[ $1 == "-m" ]] ; then + msg=$2 + shift 2 + fi + if [[ -z $1 ]] || [[ -n $2 ]] ; then + echo "Usage: submit_bug_stable " + return 1 + fi + local maintainer=$(xml sel -t -v pkgmetadata/herd metadata.xml) + if [[ ${maintainer} == "no-herd" ]] ; then + maintainer=$(xml sel -t -v pkgmetadata/maintainer/email metadata.xml) + elif [[ -n ${maintainer} ]] ; then + maintainer="${maintainer}@gentoo.org" + fi + if [[ -z ${maintainer} ]] ; then + echo "No maintainer found in metadata.xml" + return 1 + fi + local cat=$(basename $(dirname $(pwd))) + local pkg=${1%.ebuild} + local ebuild=${pkg}.ebuild + local cc=$(arch_emails ${ebuild} | sed -r -e 's:([^ ]*-fbsd|mips)@[^ ]*::g') + if [[ -z ${cc} ]] ; then + echo "Unable to read ebuild '${ebuild}'" + return 1 + fi + bugz post \ + -u vapier@gentoo.org \ + -t "Stabilize ${cat}/${pkg}" \ + -d "${msg}" \ + -a "${maintainer}" \ + --cc="${cc}" \ + -U "" \ + -k STABLEREQ +} + +eskeys() { + local k cat + if [[ ! -e ChangeLog ]] ; then + # running in a category rather than package + cat="/" + fi + [[ -z $* ]] && set -- arm m68k s390 sh + for k in "$@" ; do + local list="$(grep "^KEYWORDS=.*~${k}\>.*[^~]x86" *${cat}*d -l)" + [[ -z ${list} ]] && continue + sed -i "1s:.*:# Copyright 1999-$(date +%Y) Gentoo Foundation:" ${list} + ekeyword ${k} ${list} + done +} +_erit() { + local msg=$1 ; shift + [[ $1 == [[:digit:]]* ]] && msg="$msg #$1" && shift + echo repoman commit -m "$(echo $@ | sed 's: :/:g') $msg" + repoman commit -m "$(echo $@ | sed 's: :/:g') $msg" +} +erstable() { _erit stable "$@" ; } +erlove() { _erit love "$@" ; } diff --git a/.profile.d/aliases.sh b/.profile.d/aliases.sh index 479b8f7..a72c256 100644 --- a/.profile.d/aliases.sh +++ b/.profile.d/aliases.sh @@ -1,16 +1,23 @@ [[ $- != *i* ]] && return +alias axine='xine -A null' alias bc='bc -q' +#alias bittorrent-curses='bittorrent-curses --max_upload_rate 10' +#alias bt='bittorrent-curses --max_upload_rate 10 --save_in . --save_incomplete_in .' alias duh='du . --max-depth=1 -h' alias eclipse='eclipse-3.1 -vmargs -Xmx512m' alias gdb='gdb --quiet' +alias gdbtui='gdbtui --quiet' alias grep='grep --colour=auto' alias ls='ls --color=auto' alias lynx='lynx -nopause -accept_all_cookies -use_mouse' alias minicom='minicom -w -c on' alias nslookup='nslookup -sil' +alias quake4='quake4 +set s_driver oss' +alias repoman='repoman -q -q' alias s='aspell -a' ss() { aspell -a <<<"$*"; } +alias xine='xine -l' grep-svn() { find '(' -wholename '*/.svn' -prune -o -type f -print0 ')' | xargs -0 grep "$@" ; } @@ -31,63 +38,10 @@ scrub_patch() { "$@" } -cvs_gentoo_url() { -_cvs_gentoo_url() { - if [[ -n $2 ]] ; then - echo "Usage: cvs_gentoo_url [:rev1[:rev2]]" - return 1 - fi - - # spec has the form file:rev1[:rev2] - # rev2 defaults to rev1-1 - export IFS=: - set -- $1 - unset IFS - - local file=$1 - if [[ ! -e ${file} ]] ; then - echo "file '${file}' does not exist" - return 1 - fi - local dir="." - [[ ${file} == */* ]] && dir=${file%/*} - file=${file##*/} - - local rev2=$2 - if [[ -z ${rev2} ]] ; then - rev2=$( - cd ${dir} - export IFS=/ - set -- $(grep /${file}/ CVS/Entries) - unset IFS - echo $3 - ) - if [[ ${rev2} == "0" ]] ; then - # new file - rev2="1.1" - else - # existing file, bump rev automatically - rev2="1.$((${rev2#1.}+1))" - fi - fi - local rev2r=${rev2#1.} - local rev1=${3:-1.$((rev2r - 1))} - - local cvsroot=$(<${dir}/CVS/Repository) - if [[ ${cvsroot} == gentoo-x86* ]] ; then - cvsroot=${cvsroot#gentoo-x86} - cvsroot=${cvsroot#/} - fi - - local urirev - [[ ${rev2} == "1.1" || ${rev1} == "${rev2}" ]] \ - && urirev="?rev=${rev2}" \ - || urirev="?r1=${rev1}&r2=${rev2}" - echo "http://sources.gentoo.org/${cvsroot}/${file}${urirev}" -} - local f - for f in "$@" ; do - _cvs_gentoo_url "${f}" - done - unset _cvs_gentoo_url +scrub_html() { + sed -i \ + -e 's:<:<:g' -e 's:>:>:g' \ + -e 's: ::g' -e 's:&:\&:g' \ + -e 's:":":g' \ + "$@" } diff --git a/.profile.d/base.sh b/.profile.d/base.sh new file mode 100644 index 0000000..d487f69 --- /dev/null +++ b/.profile.d/base.sh @@ -0,0 +1,2 @@ +export EDITOR=/bin/nano +export PAGER=/usr/bin/less diff --git a/.profile.d/keychain.sh b/.profile.d/keychain.sh new file mode 100644 index 0000000..a7bf3ba --- /dev/null +++ b/.profile.d/keychain.sh @@ -0,0 +1,4 @@ +if type -P keychain >/dev/null ; then + source ~/.keychain/vapier-sh >& /dev/null + source ~/.keychain/vapier-sh-gpg >& /dev/null +fi diff --git a/.profile.d/locale.sh b/.profile.d/locale.sh new file mode 100644 index 0000000..6536b5a --- /dev/null +++ b/.profile.d/locale.sh @@ -0,0 +1,5 @@ +case ${TERM} in + Eterm) LANG="en_US";; + *) LANG="en_US.UTF8";; +esac +export LANG diff --git a/.profile.d/screen.sh b/.profile.d/screen.sh index 7e21ec6..a8f6fa0 100644 --- a/.profile.d/screen.sh +++ b/.profile.d/screen.sh @@ -1 +1 @@ -[[ ${TERM} != "dumb" ]] && screen -li +[ "${TERM}" != "dumb" ] && screen -li diff --git a/.vimrc b/.vimrc new file mode 100644 index 0000000..4dc711a --- /dev/null +++ b/.vimrc @@ -0,0 +1 @@ +set tabstop=4 diff --git a/TODO b/TODO index 3f38b9a..88e9b82 100644 --- a/TODO +++ b/TODO @@ -1 +1,43 @@ gforge frs sort is fucked + +toolchain + - make patchset 1.1 w/all new fixes + hardened and roll gcc-4.1.2-r1 + +update gameslibdir http://www.gentoo.org/proj/en/desktop/games/games-ebuild-howto.xml + +review ubuntu initramfs fsck for root + +http://sam.zoy.org/blog/2007-04-13-shlib-with-non-pic-code-have-inline-assembly-and-pic-mix-well +add info on jumping to hidden symbols as a PIC fix + +openvpn: http://openvpn.net/howto.html#examples + +2066412 mdm5252 + + hi, solar wants you to commit to the embedded overlay, your password for the overlays.gentoo.org is: DX7wnSe40Y + +http://bugs.gentoo.org/133489 +http://bugs.gentoo.org/120616#c8 + +add a -no-trigraphs gcc option + +buildroot: add support for uclibc release patches / configs + +c-client adds -fPIC to cflags + +uclibc stages todo: + - arm arm-softfloat armeb armeb-softfloat + - i386 i386-hard + - ppc ppc-softfloat + - sh4 [sh4eb maybe] + - mips mipsel + +gdb: parse pax elf notes + +quake1 movie: add the ILL Clan.s seminal Apartment Huntin.. + +qrescue + notice the -r of option that exist in q + can you do the same for metadata + +ia64 libunwind support diff --git a/dump.c b/dump.c new file mode 100644 index 0000000..0c213a5 --- /dev/null +++ b/dump.c @@ -0,0 +1,52 @@ +#include +#include +#include +#include +#include +#include + +int main(int argc, char *argv[]) +{ + void *l1_addr = (void *)0xf0000000; + void *src_addr, *dst_addr; + size_t count; + enum { AUTO, DMA, CORE } use_dma = AUTO; + + if (argc > 1) { + if (!strcmp(argv[1], "-d")) + use_dma = DMA; + else if (!strcmp(argv[1], "-c")) + use_dma = CORE; + if (use_dma != AUTO) + --argc, ++argv; + } + + if (argc != 3) { + fprintf(stderr, + "Usage: dump [-d|-c]
\n" + " -d - use DMA for copy (default if address >= %p)\n" + " -c - use core loads (default if address < %p)\n" + "Values are in hex.\n", l1_addr, l1_addr); + return EXIT_FAILURE; + } + + src_addr = (void *)strtoul(argv[1], NULL, 16); + count = strtoul(argv[2], NULL, 16); + if (use_dma == AUTO) + use_dma = (src_addr >= l1_addr ? DMA : CORE); + + fprintf(stderr, "Copying %zi bytes from %p\n", count, src_addr); + + dst_addr = malloc(count); + fprintf(stderr, "%smemcpy(%p, %p, %zi);\n", + (use_dma == DMA ? "dma_" : ""), + dst_addr, src_addr, count); + if (use_dma == DMA) + dma_memcpy(dst_addr, src_addr, count); + else + memcpy(dst_addr, src_addr, count); + fprintf(stderr, "write(%i, %p, %zi);\n", 1, dst_addr, count); + write(1, dst_addr, count); + + return 0; +}