libssh开发活跃起来了

自从KDE4.4开始开发以来,KDE中的kio使用libssh实现sftp相关功能,libssh开发工作在kde开发组的帮助下进入快车道。

nullfxp项目中的sftp使用的libssh2项目,有空研究一下libssh项目的特点,对比一下libssh和libssh2。

当前版本,0.3.4, 在kde 4.4发布的时候,项目组会发布libssh-0.4.0版本。
项目主页:

http://www.libssh.org/

开发提交图例:

sphinx功能计划路线

* 真正的实时更新/添加/删除
希望能在1.0.0中实现
现在仅支持实时的索引属性更新(属性类型为MVA或者Integer), 这一功能实现了更新,模拟删除

* 可更新包含float类型数据的属性

* LEAST()函数
这个函数接收2+个数字参数,返回其中最小的一个。

* GROUPBY_TIMESEGMENTS
时间段归类?

* MySQL连接的 SSL 支持
0.9.9-rc2

* Windows平台编译开启zlib

* Windows平台安装程序

KDE 4.3.3发布

in
  

KDE现在是UNIX上可用的易于使用的现代桌面环境。和一些如GNU/Linux这样的自由的类UNIX一起,UNIX/KDE组成了一个对于任何人都 可用的完全自由和开放的计算平台,而且完全免费,任何人都可以修改它的源代码。当 然它总是有可以改进的空间,我们相信我们已经发布了一些当今可用的能和商 业操作系统/桌面组合的合适的替代品。我们希望UNIX/KDE组合将会最终为普通计算机用户带来一个同样开放、可靠、稳定和专利自由的计算环境,世界范 围内的科学家和计算机专业人士已经喜爱它很多年了。

下载:KDE 4.3.3
查看:KDE 4.3.3 Release Announcement

gentoo 中 license mask的包解决办法

一些和license相关的协议问题,目前不需要怎么关心这个东西,所以可以根据portage机制,打开所有有限制协议的包

portage 输出为:
localhost virtualbox-bin # emerge -va virtualbox-bin
^@
These are the packages that would be merged, in order:

Calculating dependencies... done!

!!! All ebuilds that could satisfy "app-emulation/virtualbox-bin" have been masked.
!!! One of the following masked packages is required to complete your request:
- app-emulation/virtualbox-bin-3.0.10 (masked by: PUEL license(s))
A copy of the 'PUEL' license is located at '/usr/portage/licenses/PUEL'.

- app-emulation/virtualbox-bin-3.0.8 (masked by: PUEL license(s))
- app-emulation/virtualbox-bin-3.0.6-r1 (masked by: PUEL license(s))
- app-emulation/virtualbox-bin-3.0.6 (masked by: PUEL license(s))
- app-emulation/virtualbox-bin-1.6.6 (masked by: PUEL license(s))

For more information, see the MASKED PACKAGES section in the emerge
man page or refer to the Gentoo Handbook.

在make.conf中添加这么一行:
ACCEPT_LICENSE="*"

或者把*替换成要解禁的协议类型, 如PUEL(virtualbox-bin)等.
如果使用*,则不受任何协议限制的emerge所有软件包.

一个很有意思的玩意:FlightGear,开源飞机模拟器

你一定很想知道开F22战机是什么感觉,甚至梦想有一天自己也能驾驭着飞机在空中飞翔。现实生活中,做飞行员可不是一件简单的事,既然如此,我们就别想那么多,但有了FlightGear这个软件,你的梦想也许就会实现。它是一款飞机的模拟器,与真实的飞机操作环境以及飞行环境是一样的,唯一的区别就是你是通过电脑来控制这架飞机。最重要的是,FlightGear还是一个开源软件。先一看一下驾驭仓的操作环境:

支持操作系统平台:

  • Linux (任何发行版),
  • Windows NT/2000/XP (Intel/AMD平台),
  • Windows 95/98/ME,
  • BSD UNIX,
  • Sun-OS,
  • 苹果

在Ubuntu上安装:
sudo apt-get install flightgear
在其它平台上安装 :http://www.flightgear.org/Downloads/binary.shtml
这里有很多飞机:
http://www.flightgear.org/Downloads/aircraft/

在gentoo Linux上安装Trac 0.11.5

在gentoo Linux上安装Trac 0.11.5
1. 需要依赖的包:

dev-python/setuptools
dev-python/genshi

emerge -va setuptools genshi

安装数据库驱动包: 可以使用的有 PySQLite(for sqlite), psycopg2(for postgresql), MySQLdb(for mysql)
psycopg2在gentoo上的包名为dev-python/pycopg2-2.x
MySQLdb在gentoo上的包名为dev-python/mysql-python-1.2.x
我希望可以用postgresql和mysql两种库,所以安装后面两个包

emerge -va psycopg mysql-python
These are the packages that would be merged, in order:

Calculating dependencies ... done!
[ebuild N ] app-admin/eselect-postgresql-0.3 3 kB
[ebuild N ] dev-db/postgresql-base-8.4.1 USE="kerberos nls pam readline ssl threads zlib -doc -ldap -pg-intdatetime" LINGUAS="zh_CN zh_TW -af -cs -de -es -fa -fr -hr -hu -it -ko -nb -pl -pt_BR -ro -ru -sk -sl -sv -tr" 13,262 kB
[ebuild N ] dev-python/mysql-python-1.2.3_rc1 88 kB
[ebuild N ] virtual/postgresql-base-8.4 0 kB
[ebuild N ] dev-python/psycopg-2.0.12 USE="-debug -doc -examples -mxdatetime" 251 kB

Total: 5 packages (5 new), Size of downloads: 13,602 kB

Would you like to merge these packages? [Yes/No] Yes

基础依赖包装完了,如果你使用的Linux不是gentoo, 那么请参考Trac目录下的INSTALL文件安装这些包.

2. 接下来安装trac包

解压Trac-0.11.5.tar.gz
cd Trac-0.11.5
由于 我想把trac装在一个自定义路径下,所以要把PYTHONPATH的路径设置一下.
export PYTHONPATH=/serv/stow/trac-0.11.5/lib64/python2.6/site-packages/
python ./setup.py build
python ./setup.py -v install

3. 配置trac运行参数
/serv/stow/trac-0.11.5/bin/trac-admin /serv/stow/mytrac/ initenv
在这一步中,需要确定要使用的数据库,如果安装完成后需要换数据库,则要重新配置一遍,而不是修改下配置文件就可以的.所以在数据库选择步骤要提前准备好要使用的数据库,或者是postgresql,或者是mysql.默认的sqlite是sqlite:db/trac.db
对于postgresql,对应上述建立的数据库,应该是;
postgres://trac:12345@localhost/trac
MySQL与之类似.

配置/serv/stow/trac-0.11.5/mytrac/trac.ini,设置数据库信息及认证信息

以standalone模式启动trac
tracd --port 8000 /serv/stow/mytrac

4. 访问: http://localhost:8000/可以看到trac系统已经运行了.如果还有什么问题,可以再修改trac.ini

5. 用户认证登陆.
trac支持的认证方式比较多,下面测试一种比较简单的htpasswd方式,其他的参照http://localhost:8000/mytrac/wiki/TracGuide

使用htpasswd创建用户认证文件
htpasswd -c /serv/stow/trac-0.11.5/mytrac/.htpasswd admin
这样会加入一个admin用户,设置上你的密码.

添加第二个用户名的时候仍旧使用上面的命令,不过少了一个-c参数.
htpasswd /serv/stow/trac-0.11.5/mytrac/.htpasswd test1

启动与上一步中的命令一到,参数复杂了些:
./bin/tracd --port 8000 --basic-auth=mytrac,/serv/stow/trac-0.11.5/mytrac/.htpasswd,/serv/stow/trac-0.11.5/mytrac/ /serv/stow/trac-0.11.5/mytrac/

OK,从浏览器登陆测试一下如何.

6. 添加一个管理员账号
/serv/stow/trac-0.11.5/bin/trac-admin /serv/stow/trac-0.11.5/mytrac/ permission add admin TRAC_ADMIN
当这个管理员登陆后,会比用户多一个admin菜单,用于管理这个trac

切换kvm与virtualbox内核驱动模块的自动脚本

由于我目前在同时使用virtualbox和kvm,而这两个模块有冲突,所以把内核中的kvm编译成了模块,在需要的时候可以切换这两个模块,选择使用其中任何一种虚拟机驱动.
下面是我用的切换脚本,可以自动检测当前使用的虚拟机模块,把它rmmod掉之后,再加载另一种模块,用起来比较方面,在此帖出,仅做参考.

more swith_vbox_kvm.sh

#vboxnetflt             91444  0
#vboxnetadp             85412  0
#vboxdrv              1699090  1 vboxnetflt
 
NOW_VM=`lsmod | grep vbox`
if [ x"$NOW_VM" = x"" ] ; then
        echo "Now is kvm, swithing to vbox..."
        rmmod kvm-intel
        rmmod kvm
 
        modprobe vboxdrv
        modprobe vboxnetadp
        modprobe vboxnetflt
else
        echo "Now is vbox, swithing to kvm..."
        rmmod vboxnetflt
        rmmod vboxnetadp
        rmmod vboxdrv
 
        modprobe kvm
        modprobe kvm-intel
fi
 
echo "Switching from    to xxx done."
lsmod | grep kvm
lsmod | grep vbox
echo "enjoy it now!"

一个新的希望取代GNU ld的Linux C/C++链接器: Glod

Gold 是一个ELF文件链接器.它早在2008-3月就加入到了binutils包,第一个发布版本是在binutils-2.19中.
Gold 是由Ian Lance Taylor和Google的一个小组共同开发的.写Glod的目的是希望链接程序的时候能比GNU ld链接器快,特别是针对大型C++应用程序.

目前 binutils已经到了2.20版本,现在安装binutils的话可以选择安装这个新的链接器了.

http://en.wikipedia.org/wiki/Gold_(linker)

注:经过测试,目前还有很多问题,许多软件使用它都在最后一步链接失败.

在苹果系统 xcode 上打包 qt4 应用程序

苹果系统安装包上带一个工具 本,macdeployqt, 它能够将 qt 库与程序打包成一个 dmg 文件,在苹果系统可以直接双打击安装使用,像一个虚拟磁盘镜像一样,非常方便。

如果是自己编译安装的 qt 包,需要在配置参加数的时候指定安装这个工具才行,否则默认情况下不安装这个工具。

还有一点有问题,如何把图片资源打到这个包中。研究一下这个工具和 qt 开发文档。

liuguangzhaos-macbook-pro:nullfxp-2.0.1 gzleo$ /usr/local/Trolltech/Qt-4.5.1/bin/macdeployqt
Usage: macdeployqt app-bundle [options]

Options:
-no-plugins: Skip plugin deployment
-dmg : Create a .dmg disk image
-no-strip : Don't run 'strip' on the binaries

macdeployqt takes an application bundle as input and makes it
self-contained by copying in the Qt frameworks and plugins that
the application uses.

Plugins related to a framework are copied in with the
framework. The accessibilty, image formats, and text codec
plugins are always copied, unless "-no-plugins" is specified.

See the "Deploying an Application on Qt/Mac" topic in the
documentation for more information about deployment on Mac OS X.

打包实例:

localhost:nullfxp-svn gzleo$ macdeployqt bin/nullfxp.app/ -verbose=3 -dmg
Log: Argument found: "-dmg" 
Log: Using otool: 
Log:  inspecting "bin/nullfxp.app/Contents/MacOS/nullfxp" 
Log: Adding framework: 
Log: Framework name "QtSql.framework" 
 Framework directory "/Library/Frameworks/" 
 Framework path "/Library/Frameworks/QtSql.framework" 
 Binary directory "Versions/4" 
 Binary name "QtSql" 
 Binary path "/Versions/4/QtSql" 
 Version "4" 
 Install name "QtSql.framework/Versions/4/QtSql" 
 Deployed install name "@executable_path/../Frameworks/QtSql.framework/Versions/4/QtSql" 
 Source file Path "/Library/Frameworks/QtSql.framework/Versions/4/QtSql" 
 Deployed Directory (relative to bundle) "Contents/Frameworks/QtSql.framework/Versions/4" 
 
Log: Adding framework: 
Log: Framework name "QtGui.framework" 
 Framework directory "/Library/Frameworks/" 
 Framework path "/Library/Frameworks/QtGui.framework" 
 Binary directory "Versions/4" 
 Binary name "QtGui" 
 Binary path "/Versions/4/QtGui" 
 Version "4" 
 Install name "QtGui.framework/Versions/4/QtGui" 
 Deployed install name "@executable_path/../Frameworks/QtGui.framework/Versions/4/QtGui" 
 Source file Path "/Library/Frameworks/QtGui.framework/Versions/4/QtGui" 
 Deployed Directory (relative to bundle) "Contents/Frameworks/QtGui.framework/Versions/4" 
 
Log: Adding framework: 
Log: Framework name "QtNetwork.framework" 
 Framework directory "/Library/Frameworks/" 
 Framework path "/Library/Frameworks/QtNetwork.framework" 
 Binary directory "Versions/4" 
 Binary name "QtNetwork" 
 Binary path "/Versions/4/QtNetwork" 
 Version "4" 
 Install name "QtNetwork.framework/Versions/4/QtNetwork" 
 Deployed install name "@executable_path/../Frameworks/QtNetwork.framework/Versions/4/QtNetwork" 
 Source file Path "/Library/Frameworks/QtNetwork.framework/Versions/4/QtNetwork" 
 Deployed Directory (relative to bundle) "Contents/Frameworks/QtNetwork.framework/Versions/4" 
 
 
Log: Adding framework: 
Log: Framework name "QtCore.framework" 
 Framework directory "/Library/Frameworks/" 
 Framework path "/Library/Frameworks/QtCore.framework" 
 Binary directory "Versions/4" 
 Binary name "QtCore" 
 Binary path "/Versions/4/QtCore" 
 Version "4" 
 Install name "QtCore.framework/Versions/4/QtCore" 
 Deployed install name "@executable_path/../Frameworks/QtCore.framework/Versions/4/QtCore" 
 Source file Path "/Library/Frameworks/QtCore.framework/Versions/4/QtCore" 
 Deployed Directory (relative to bundle) "Contents/Frameworks/QtCore.framework/Versions/4" 
 
Log: 
Log: Deploying Qt frameworks found inside: "bin/nullfxp.app/Contents/PlugIns/sqldrivers/libqsqlpsql.dylib" 
Log: Using install_name_tool: 
Log:  in "bin/nullfxp.app/Contents/PlugIns/sqldrivers/libqsqlpsql.dylib" 
Log:  change reference "QtSql.framework/Versions/4/QtSql" 
Log:  to "@executable_path/../Frameworks/QtSql.framework/Versions/4/QtSql" 
Log: Using install_name_tool: 
Log:  in "bin/nullfxp.app/Contents/PlugIns/sqldrivers/libqsqlpsql.dylib" 
Log:  change reference "QtCore.framework/Versions/4/QtCore" 
Log:  to "@executable_path/../Frameworks/QtCore.framework/Versions/4/QtCore" 
Log: Created configuration file: "bin/nullfxp.app/Contents/Resources/qt.conf" 
Log: This file sets the plugin search path to "bin/nullfxp.app/Contents/PlugIns" 
Log: 
Log: Creating disk image (.dmg) for "bin/nullfxp.app" 
localhost:nullfxp-svn gzleo$ ls
AUTHORS			NEWS			nullfxp.pro
CMakeLists.txt		README			nullfxp.xcodeproj
COPYING			TODO			packages
ChangeLog		bin			src
Doxyfile		docs			tools
INSTALL			install.pri
Makefile		nullfxp.kdevelop
localhost:nullfxp-svn gzleo$ ls bin/
nullfxp.app	nullfxp.dmg	touch.exe	unitest.app
localhost:nullfxp-svn gzleo$ ls bin/ -lh
ls: -lh: No such file or directory
bin/:
nullfxp.app	nullfxp.dmg	touch.exe	unitest.app
localhost:nullfxp-svn gzleo$ ls -lh bin/
total 33832
drwxr-xr-x  3 gzleo  staff   102B  3 30 11:29 nullfxp.app
-rw-r--r--@ 1 gzleo  staff    16M  3 30 11:49 nullfxp.dmg
-rw-r--r--  1 gzleo  staff    44K  3 27 22:44 touch.exe
drwxr-xr-x  3 gzleo  staff   102B  3 30 11:43 unitest.app
localhost:nullfxp-svn gzleo$ 

nullfxp 2.0.1 released

in

这是自nullfxp 2.0.0发布以来的第一个bug修正版本,更新日志如下:

* ftp添加默认编译支持,默认为UTF-8.

* ftp修正连接某些服务器出错的问题.

* 添加简单的版本检测功能.

* 修正SFTP/FTP升级到2.0后出现的拖拽问题.

* 修正SFTP/FTP上传覆盖文件后不能及时更新文件属性记录的问题.

* 核心代码重构,使用新的连接类,清理代码,改进windows平台工程文件.

下载: http://www.qtchina.net/?q=taxonomy/term/3

Syndicate content