当前时区为 UTC + 8 小时



发表新帖 回复这个主题  [ 2 篇帖子 ] 
作者 内容
1 楼 
 文章标题 : 求救! amsn启动不了 终端显示....
帖子发表于 : 2009-06-13 16:34 
头像

注册: 2008-07-08 10:39
帖子: 413
送出感谢: 1
接收感谢: 3
pisit@pisit-desktop:/media/data$ amsn
Application initialization failed: Can't find a usable tk.tcl in the following directories:
/usr/local/lib/tcl8.5/tk8.5 /usr/local/lib/tk8.5 /usr/lib/tk8.5 /usr/local/library

/usr/local/lib/tk8.5/tk.tcl: no event type or button # or keysym
no event type or button # or keysym
while executing
"bind Listbox <MouseWheel> {
%W yview scroll [expr {- (%D / 120) * 4}] units
}"
invoked from within
"if {[tk windowingsystem] eq "aqua"} {
bind Listbox <MouseWheel> {
%W yview scroll [expr {- (%D)}] units
}
bind Listbox <Option-Mou..."
(file "/usr/local/lib/tk8.5/listbox.tcl" line 182)
invoked from within
"source /usr/local/lib/tk8.5/listbox.tcl"
(in namespace eval "::" script line 1)
invoked from within
"namespace eval :: [list source [file join $::tk_library $file.tcl]]"
(procedure "SourceLibFile" line 2)
invoked from within
"SourceLibFile listbox"
(in namespace eval "::tk" script line 4)
invoked from within
"namespace eval ::tk {
SourceLibFile button
SourceLibFile entry
SourceLibFile listbox
SourceLibFile menu
SourceLibFile panedwindow
SourceLibFile ..."
invoked from within
"if {$::tk_library ne ""} {
proc ::tk::SourceLibFile {file} {
namespace eval :: [list source [file join $::tk_library $file.tcl]]
}
..."
(file "/usr/local/lib/tk8.5/tk.tcl" line 401)
invoked from within
"source /usr/local/lib/tk8.5/tk.tcl"
("uplevel" body line 1)
invoked from within
"uplevel #0 [list source $file]"


This probably means that tk wasn't installed properly.

Error in startup script: invalid command name "tk::AmpWidget"
while executing
"tk::AmpWidget button .__tk__messagebox.ok -padx 3m -text &OK -command {set tk::Priv(button) ok}"
("eval" body line 1)
invoked from within
"eval [list tk::AmpWidget button $w.$name -padx 3m] $opts [list -command [list set tk::Priv(button) $name]]"
(procedure "tk::MessageBox" line 215)
invoked from within
"tk::MessageBox {expand}$args"
(procedure "tk_messageBox" line 2)
invoked from within
"tk_messageBox -default ok -message "Loading TkCximage failed. This module is needed to run aMSN. Please compile aMSN first, instructions on how to co..."
invoked from within
"if { $initialize_amsn == 1 } {

if {![::picture::Loaded]} {
if { [OnDarwin] } {
tk_messageBox -default ok -message "There's a problem loading a..."
(file "gui.tcl" line 4)
invoked from within
"source gui.tcl "
("uplevel" body line 23)
invoked from within
"uplevel \#0 {

# amsncore.tcl is already loaded but we'll re-source it here in case we manually do reload_files
source amsncore.tcl
source audio.tc..."
(procedure "reload_files" line 2)
invoked from within
"reload_files"
(file "/usr/bin/amsn" line 272)
pisit@pisit-desktop:/media/data$


页首
 用户资料  
 
2 楼 
 文章标题 : Re: 求救! amsn启动不了 终端显示....
帖子发表于 : 2009-06-13 18:14 
头像

注册: 2008-07-08 10:39
帖子: 413
送出感谢: 1
接收感谢: 3
对了我运行了这个脚本才引起的
#!/bin/bash
#Last edited: March 8, 2007

#This is an automated script to add anti-aliasing support to aMSN. This
# will compile the latest beta of Tcl and Tk, and recompile aMSN for it.
#
#This script supports [,K,X]Ubuntu Edgy and Feisty on both 32-bit and
# 64-bit processors.
#
#A few notes:
#
# - The beta Tcl and Tk will be compiled and installed into /usr/local;
# it will not replace your existing Tcl and Tk installation, so it
# should be much safer to use and easier to revert than other methods.
# If the script fails for whatever reason, your existing aMSN
# installation will not be harmed.
#
# - A hold will be placed on the amsn package in apt-get so that it
# doesn't upgrade automatically. If you want to upgrade when a new
# version comes out, you will need to apt-get install the new package,
# then download the source code and compile it as in this script.
#
# - This script accepts the command line option "cvs" (without quotes).
# This will download the latest trunk of Tcl/Tk and aMSN through
# revision control systems instead of using source tarballs.
# Use it if you want to be on the bleeding edge or if the tarballs
# fail for some reason.
#
# - This script accepts the command line option "clean" (without quotes).
# This will remove Tcl/Tk 8.5 and purge aMSN and all configuration files and
# customizations (profiles, skins, extensions, logs, etc). If you want to
# revert to the normal aMSN, execute the clean, then apt-get install amsn.
#
# - The Ubuntu and Kubuntu skins by GuS-Arg will be installed. If you do
# not have a skin already selected, the proper skin will be selected
# automatically. You can activate them manually via Account -> Select Skin.
#
#This script was written for [,K,X]Ubuntu Edgy/Feisty. Use at your own risk.
# - Vuen


SOURCEFORGE=http://easynews.dl.sourceforge.net/sourceforge
TEMPDIR=/tmp/fixamsn.$RANDOM
APTOPTIONS="--assume-yes --option Dir::Etc::SourceList=$TEMPDIR/sources.list"


function clean_up {
EXITVAL=$?
rm -rf $TEMPDIR
exit $EXITVAL
}

function error_exit
{
echo "ERROR: $1" 1>&2
clean_up
}

trap clean_up SIGHUP SIGINT SIGTERM

#check for clean option
if [ "$1" = "clean" ]; then
echo -e "\nCleaning Tcl/Tk 8.5 and aMSN."
echo -e "\nWARNING: This option will clear all your configuration options,\n including profiles, skins, plugins, and conversation logs.\n Press CTRL+C to cancel.\n"
sudo -k
sudo echo -n "" || error_exit "Could not gain root."
sudo killall amsn
sudo killall wish8.5
sudo apt-get update
sudo apt-get remove --purge --assume-yes amsn
sudo rm -rf \
/usr/local/bin/tclsh8.5 \
/usr/local/bin/wish8.5 \
/usr/local/include/tcl8.5/ \
/usr/local/lib/libtcl8.5.so \
/usr/local/lib/tcl8.5/ \
/usr/local/lib/libtk8.5.so \
/usr/local/lib/tk8.5/ \
/usr/share/amsn \
~/.amsn
exit 0
fi

#give some information:
echo -e "\nInstalling aMSN with Anti-Aliasing support."
if [ "$1" = "cvs" ]; then
echo -e " -- CVS mode: the latest trunk of Tcl/Tk and aMSN will be installed.\n"
else
echo -e " -- Source tarball mode: Tcl/Tk 8.5a6 and aMSN 0.97RC1 will be installed.\n"
fi

#get all user interaction done right away
#activate sudo
echo "Please enter your sudo password:"
sudo echo -n "" || error_exit "Could not gain root."

#get in temp folder
mkdir -p $TEMPDIR
cd $TEMPDIR

#write our own sources.list in temp folder
DISTNAME=`lsb_release -cs`
if [ "$DISTNAME" == "edgy" ] || [ "$DISTNAME" == "feisty" ] || [ "$DISTNAME" == "gutsy" ]; then
#supported distribution
echo "#Temporary sources.list by aMSN installation script" | sudo tee $TEMPDIR/sources.list > /dev/null
DEBTYPES="deb deb-src"
for DEBTYPE in $DEBTYPES; do
echo "$DEBTYPE http://archive.ubuntu.com/ubuntu/ ${DISTNAME} main restricted universe multiverse" | sudo tee -a $TEMPDIR/sources.list > /dev/null
echo "$DEBTYPE http://archive.ubuntu.com/ubuntu/ ${DISTNAME}-updates main restricted universe multiverse" | sudo tee -a $TEMPDIR/sources.list > /dev/null
echo "$DEBTYPE http://archive.ubuntu.com/ubuntu/ ${DISTNAME}-backports main restricted universe multiverse" | sudo tee -a $TEMPDIR/sources.list > /dev/null
echo "$DEBTYPE http://security.ubuntu.com/ubuntu ${DISTNAME}-security main restricted universe multiverse" | sudo tee -a $TEMPDIR/sources.list > /dev/null
done
else
if grep deb-src /etc/apt/sources.list > /dev/null; then
#existing sources.list has deb-src lines; copy to temp folder and uncomment
echo -e "\nYour distribution is not supported by this script."
echo "Press enter to proceed anyway, or CTRL+C to cancel."
read
sudo cp /etc/apt/sources.list $TEMPDIR/sources.list
sudo sed --in-place 's/#deb-src/deb-src/' $TEMPDIR/sources.list
else
#unsupported, no source repositories in sources.list
error_exit "Could not add deb-src repositories. Your distribution is not supported by this script."
fi
fi

#load our temporary sources.list
sudo apt-get $APTOPTIONS update

#install amsn and hold it so it doesn't update
sudo apt-get $APTOPTIONS install amsn || error_exit "Could not install build dependencies."
sudo aptitude --assume-yes hold amsn

#install build dependencies for beta tcl and tk
sudo apt-get $APTOPTIONS build-dep tcl8.4 tk8.4 amsn || error_exit "Could not install build dependencies."
sudo apt-get $APTOPTIONS install libpng12-dev libjpeg-dev libxft-dev || error_exit "Could not install build dependencies."
if [ "$1" = "cvs" ]; then
sudo apt-get $APTOPTIONS install cvs subversion || error_exit "Could not install revision control systems."
fi

#load original sources.list
sudo apt-get update

#get the various source codes we need
if [ "$1" = "cvs" ]; then
#tcl trunk
cvs -d:pserver:anonymous:@tcl.cvs.sourceforge.net:/cvsroot/tcl login || error_exit "Could not download Tcl source code."
cvs -z3 -d:pserver:anonymous@tcl.cvs.sourceforge.net:/cvsroot/tcl co -P tcl || error_exit "Could not download Tcl source code."
#tk trunk
cvs -d:pserver:anonymous:@tktoolkit.cvs.sourceforge.net:/cvsroot/tktoolkit login || error_exit "Could not download Tk source code."
cvs -z3 -d:pserver:anonymous@tktoolkit.cvs.sourceforge.net:/cvsroot/tktoolkit co -P tk || error_exit "Could not download Tk source code."
#amsn trunk
svn co https://svn.sourceforge.net/svnroot/amsn/trunk/amsn/ amsn || error_exit "Could not download aMSN source code."
else
#tcl 8.5a6
wget -c $SOURCEFORGE/tcl/tcl8.5a6-src.tar.gz || error_exit "Could not download Tcl source code."
tar -xsf tcl8.5a6-src.tar.gz
mv tcl8.5a6 tcl
#tk 8.5a6
wget -c $SOURCEFORGE/tcl/tk8.5a6-src.tar.gz || error_exit "Could not download Tk source code."
tar -xsf tk8.5a6-src.tar.gz
mv tk8.5a6 tk
#amsn 0.96
wget -c $SOURCEFORGE/amsn/amsn-0.97RC1.tar.bz2 || error_exit "Could not download aMSN source code."
tar -xsf amsn-0.97RC1.tar.bz2
mv amsn-0.97RC1 amsn
fi

#compile tcl (into /usr/local, to leave tcl 8.4 untouched)
cd tcl/unix
(./configure --prefix=/usr/local --includedir=/usr/local/include/tcl8.5 --enable-shared --enable-threads --enable-64bit --mandir=/usr/local/share/man --enable-man-symlinks --enable-man-compression=gzip && make CFLAGS="-g -O2 -D_REENTRANT" && sudo make install) || error_exit "Could not compile Tcl."
cd ../..

#compile tk (into /usr/local, to leave tcl 8.4 untouched)
cd tk/unix
(./configure --prefix=/usr/local --includedir=/usr/local/include/tcl8.5 --with-tcl=/usr/local/lib --enable-shared --enable-threads --enable-64bit --enable-man-symlinks --enable-man-compression=gzip --enable-xft && make CFLAGS="-g -O2 -D_REENTRANT" && sudo make install) || error_exit "Could not compile Tk."
cd ../..

#compile amsn
cd amsn
(./configure --with-tcl=/usr/local/lib --with-tk=/usr/local/lib && make && sudo make install) || error_exit "Could not compile aMSN."
cd ..

#fix tcltls bug (this finally works!)
sudo cp /usr/lib/tls1.50/pkgIndex.tcl /usr/lib/tls1.50/pkgIndex.tcl.amsnbak
sudo sed --in-place 's/ifneeded tls 1.5 /ifneeded tls 1.50 /' /usr/lib/tls1.50/pkgIndex.tcl
mkdir -p ~/.amsn
echo "set libtls /usr/lib/tls1.50" > ~/.amsn/tlsconfig.tcl

#modify amsn launcher to call wish8.5
sudo sed --in-place 's/wish /wish8.5 /' /usr/share/amsn/amsn

#add Ubuntu and Kubuntu skins
mkdir skins
cd skins
if wget -c $SOURCEFORGE/amsn/Ubuntu-1.0b.tar.gz && sudo tar -xsf Ubuntu-1.0b.tar.gz --directory /usr/share/amsn/skins && wget -c $SOURCEFORGE/amsn/Kubuntu-1.6.tar.gz && sudo tar -xsf Kubuntu-1.6.tar.gz --directory /usr/share/amsn/skins; then
#activate skins
if [ -e ~/.amsn/gconfig.xml ]; then
#file exists; if skin entry is blank, modify it
if [ "$DESKTOP_SESSION" = "kde" ]; then
sed --in-place '/<attribute>skin<\/attribute>/,/<\/entry>/ s/<value><\/value>/<value>Kubuntu-1.6<\/value>/' ~/.amsn/gconfig.xml
else
sed --in-place '/<attribute>skin<\/attribute>/,/<\/entry>/ s/<value><\/value>/<value>Ubuntu-1.0b<\/value>/' ~/.amsn/gconfig.xml
fi
else
#write config file from scratch
echo -e '<?xml version="1.0"?>\n<config>\n <entry>\n <attribute>skin</attribute>' > ~/.amsn/gconfig.xml
if [ "$DESKTOP_SESSION" = "kde" ]; then
echo ' <value>Kubuntu-1.6</value>' >> ~/.amsn/gconfig.xml
else
echo ' <value>Ubuntu-1.0b</value>' >> ~/.amsn/gconfig.xml
fi
echo -e ' </entry>\n</config>' >> ~/.amsn/gconfig.xml
fi
else
echo "Unable to install Ubuntu and Kubuntu skins."
fi

cd ..

#we're done!
echo ""
echo "Done!"
clean_up


页首
 用户资料  
 
显示帖子 :  排序  
发表新帖 回复这个主题  [ 2 篇帖子 ] 

当前时区为 UTC + 8 小时


在线用户

正在浏览此版面的用户:没有注册用户 和 3 位游客


不能 在这个版面发表主题
不能 在这个版面回复主题
不能 在这个版面编辑帖子
不能 在这个版面删除帖子
不能 在这个版面提交附件

前往 :  
本站点为公益性站点,用于推广开源自由软件,由 DiaHosting VPSBudgetVM VPS 提供服务。
我们认为:软件应可免费取得,软件工具在各种语言环境下皆可使用,且不会有任何功能上的差异;
人们应有定制和修改软件的自由,且方式不受限制,只要他们自认为合适。

Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
简体中文语系由 王笑宇 翻译