:移植tslib-1.4

來源:互聯網
上載者:User
昨天移植了tslib-1.3和QT4-embedded-4.4.3,非常順利,連個錯誤都沒有。
可惜運行QT4後非常失望:1,運行QT4程式非常卡,跟死機一樣。2,單擊變成了雙擊。
網上查了下資料,可能是tslib-1.3和QT4.4.3相容性不好。
於是決定移植tslib-1.4。
參考的文章是:

http://blog.chinaunix.net/u1/34474/showart.php?id=1882664

首先下載tslib-1.4.tar.gz,:

http://blog.chinaunix.net/u2/75270/showart_1793535.html裡面自己找

tar xzvf tslib-1.4.tar.gz
cd tslib/
export CC=/usr/local/arm/3.4.1/bin/arm-linux-gcc
export CXX=/usr/local/arm/3.4.1/bin/arm-linux-g++
#./autogen.sh
我的系統是redhat 9.0 運行 ./autogen.sh出錯
於是馬上安裝ubuntu 9.04
然後再
sudo apt-get install autoconf
sudo apt-get install automake
sudo apt-get install libtool
搞定
export PATH=/usr/local/arm/3.4.1/bin:$PATH
echo "ac_cv_func_malloc_0_nonnull=yes" >arm-linux.cache

在這裡加這一句:
autoreconf -f -i -Wall,no-obsolete
./configure --host=arm-linux --cache-file=arm-linux.cache --enable-inputapi=no PLUGIN_DIR=/home/tslib/plugins -prefix=/home/tslib/build -host=arm-linux --cache-file=arm-linux.cache 2>&1 | tee conf_log
make 2>&1 | tee make_log
make install
#cd build/etc
#gedit ts.conf
去掉module_raw input前面的#號和空格
把build 檔案夾拷貝到開發板相應的地方。我的就是拷貝到/home/tslib下
環境變數
export T_ROOT=/home/tslib/build
export LD_LIBRARY_PATH=$T_ROOT/lib
export TSLIB_CONSOLEDEVICE=none
export TSLIB_FBDEVICE=/dev/fb0
export TSLIB_TSDEVICE=/dev/event0
export TSLIB_PLUGINDIR=$T_ROOT/lib/ts
export TSLIB_CONFFILE=$T_ROOT/etc/ts.conf
export TSLIB_CALIBFILE=/home/tslib/build/etc/pointercal
移植QT4後的我的環境變數:
export QTDIR=/home/qt44arm
export TS_ROOT=/home/tslib/build
export PATH=$QTDIR/bin:$PATH
export QWS_DISPLAY=LinuxFb:mmWidth100:mmHeight130:0
export QWS_SIZE=640x480
export QT_QWS_FONTDIR=/home/qt44arm/lib/fonts
export PONTERCAL_FILE=$TS_ROOT/etc/pointercal
export TSLIB_TSEVENTTYPE=H3600
export TSLIB_CONSOLEDEVICE=none
export TSLIB_FBDEVICE=/dev/fb0
export TSLIB_TSDEVICE=/dev/event0
export TSLIB_CONFFILE=$TS_ROOT/etc/ts.conf
export TSLIB_PLUGINDIR=$TS_ROOT/lib/ts
export TSLIB_CALIBFILE=$TS_ROOT/etc/pointercal
export QWS_MOUSE_PROTO="Tslib:/dev/event0"
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$TS_ROOT/lib
export LD_LIBRARY_PATH=$QTDIR/lib:/lib:/usr/lib:$LD_LIBRARY_PATH

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.